Php code start flag type php7php environment build php from entry to proficient

Source: Internet
Author: User
Php: php code start flag type: today, when I look at other people's php code, I found that the results still really output 'test'. so I changed the code to the following: there is no structure, so I am more curious. Start searching for materials... Online Materials: short tags, long tags, terminal tags are rarely used, instructions & lt ;?, It and & lt ;? Echo is equivalent, but before using it, you need to open short. today, when reading other people's php code, we find that


  
  

The result also outputs 'test'

So I changed the code to the following:


  
  

No structure, so I'm more curious. Start searching for materials...
Online materials:
Is short label, Is a long label, terminal labels are rarely used, instructions , It and It is equivalent, but short_open_tag must be enabled before use.
What is short_open_tag?
Determine whether to allow the abbreviated form of the code start sign ( ).
You can configure php. ini.
Problem: I checked my php. ini configuration file and found that the short_open_tag was not opened. For example:

But why is it still usable? Is there multiple php. ini, I don't know, so I can view it through phpinfo ();

Short_open_tag = Off is found.
So Why can it be used?
So I will start short_open_tag, that is, set short_open_tag = On, and then restart the server. Found


     

You can output the result.
Summary: What short_open_tag originally controls is Label. Instead Tag, Labels are used to output variables. When short_open_tag is enabled, Functions and Same.

If asp_tags = ON is set, we can play it like this.

<%$a='hello';echo$a;%>

The php Version used in the remarks is: PHP Version 5.5.12
Now let's sum up several PHP start and end tags.

  • <%%>
  • <%= %>

'). AddClass ('pre-numbering '). hide (); $ (this ). addClass ('Has-numbering '). parent (). append ($ numbering); for (I = 1; I <= lines; I ++) {$ numbering. append ($ ('
  • '). Text (I) ;}; $ numbering. fadeIn (1700) ;}) ;}; script

    The above describes the code start flag type in php, including the php content, and hope to be helpful to friends who are interested in PHP tutorials.

    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.