Php cannot be written in html in dreamweaver.

Source: Internet
Author: User
In dreamweaver, html cannot write php Dreamweaver php HTML

Use The written code will not be executed. open the browser and check that the source code is commented out. why?
As follows,


Reply to discussion (solution)

The PHP file will be compiled and executed by the server.

The php file will only be compiled and executed by the server. my homepage is html, and then I can determine if I have logged on to the session implementation and want to change it to a php page?


The php file will only be compiled and executed by the server. my homepage is html, and then I can determine if I have logged on to the session implementation and want to change it to a php page?

Use the php page
Html can only be static



The php file will only be compiled and executed by the server. my homepage is html, and then I can determine if I have logged on to the session implementation and want to change it to a php page?

Use the php page
Html can only be static. but I think the main pages of other people are index.html, and they also have login judgments?

That is determined by ajax.
Or rewrite the url.

That is determined by ajax.
Or rewrite the url. okay, isn't it true that php can be embedded anywhere?


That is determined by ajax.
Or rewrite the url. okay, isn't it true that php can be embedded anywhere?

Who said that?

PHP ("PHP: Hypertext Preprocessor") is a widely used open-source multi-purpose scripting language that can be embedded into HTML.
... Can I use. php as the homepage?

PHP ("PHP: Hypertext Preprocessor") is a widely used open-source multi-purpose scripting language that can be embedded into HTML.
... Can I use. php as the homepage?
Yes. you can use index. php on the homepage.
If you want to implement the index.html format, you can use URL rewriting.


PHP ("PHP: Hypertext Preprocessor") is a widely used open-source multi-purpose scripting language that can be embedded into HTML.
... Can I use. php as the homepage?
Yes. you can use index. php on the homepage.
If you want to use the index.html format, you can use URL rewriting to implement simplicity.

You can search for pseudo-static estimates to solve your problem.

Thank you! I used ajax to solve the problem.

Your HTML execution of PHP depends on your WEB server. the default configuration is not to execute PHP in HTML.

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.