Why does a newline appear after PHP parsing?

Source: Internet
Author: User
Why is there a newline after PHP parsing?
PHP Code
  
   Public function JavaScript ()     {          ?>                         
  
   


This code after parsing, as long as the PHP part of the change line
HTML Code
  var cr = new Array ();                         Name = "2001";                         Cr[name] = new Array ();                                        cr[name]["code"] = ' 2001 ';                         Name = "2002";                         Cr[name] = new Array ();                                        cr[name]["code"] = ' 2002 ';                         Name = "2003";                         Cr[name] = new Array ();                                        cr[name]["code"] = ' 2003 ';                         Name = "2004";                         Cr[name] = new Array ();                                        cr[name]["code"] = ' 2004 ';                         Name = "2005";                         Cr[name] = new Array ();                                        cr[name]["code"] = ' 2005 ';                         Name = "2006";                         Cr[name] = new Array (); Cr[name]["code"] = ' 2006 ';                         Name = "2007";                         Cr[name] = new Array ();                                        cr[name]["code"] = ' 2007 ';                         Name = "2008";                         Cr[name] = new Array ();                              cr[name]["code"] = ' 2008 '; return CR;

What is the situation, I on the local machine is not so, in the virtual machine on the present so, which is a big doubt!!!

------Solution--------------------
Give it a try
------Solution--------------------
That's because you have line breaks in your original data.
  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.