Error Message: XML cannot be the whole program

Error message "XML cannot be the whole program" appears when load a javascript file which was generated by PHP file. It actually has nothing to do with its appearance. There are two possible causes:

1. The file contains <script> and </script>. These two scripts indeed are unnecessary because in your html file, it had been already included: <script language='Javascript' src='filename.js.php' type='text/javascript'></script>.

2. Your php code is not clean. It contains some form of invisiable editorial codes inserted by your editor, such as Notepad, etc.

4 comments:

  1. thanks for the information ;)

    ReplyDelete
  2. You are welcome. If you find otherwise, please let me know.

    ReplyDelete
  3. Excellent info. I solved an error caused by Glossary component for Joomla, without having anz programming skils. Thank you very much.

    ReplyDelete
  4. You are welcome. I am glad my blog helped someone.

    ReplyDelete

Labels