PHP to HTML

Discussing Html . Code , Software , other

Moderators: egami, macek, gesf

Post Reply
User avatar
engrmudasirmalik
New php-forum User
New php-forum User
Posts: 14
Joined: Wed Jan 11, 2012 11:39 am
Location: Bahawalpur Pakistan
Contact:

Thu Feb 02, 2012 4:29 am


xeniar
New php-forum User
New php-forum User
Posts: 67
Joined: Tue Jan 24, 2012 1:54 pm

Sat Feb 04, 2012 2:15 pm

PHP cannot and will not work in a .HTML or .HTM file. PHP only works in .php files.

However, HTML works fine in .php files so anything you can do in a .HTML you can do in a .PHP, plus all the added benefit of being able to use PHP... 8)

Alberta

Thu Mar 29, 2012 12:11 am

PHP and HTML interact a lot: PHP can generate HTML, and HTML can pass information to PHP. Before reading these faqs, it's important you learn how to retrieve variables from external sources. The manual page on this topic includes many examples as well. Pay close attention to what register_globals means to you too.
____________________________

grbrains
New php-forum User
New php-forum User
Posts: 12
Joined: Sat Mar 03, 2012 11:31 pm
Location: Ahmedabad, India
Contact:

Sun Apr 08, 2012 10:29 pm

as per your code, please try on .PHP file instead of .HTML file. may be it will be help.

Thanks
-------------

User avatar
freshnet
php-forum Active User
php-forum Active User
Posts: 359
Joined: Tue Feb 22, 2011 8:19 am
Location: Canada

Mon Apr 09, 2012 2:21 am

xeniar wrote:PHP cannot and will not work in a .HTML or .HTM file. PHP only works in .php files.

However, HTML works fine in .php files so anything you can do in a .HTML you can do in a .PHP, plus all the added benefit of being able to use PHP... 8)
fyi that's actually not correct. You can get PHP to work in an html file by modifying your .htaccess file.

Post Reply
  • Information
  • Who is online

    Users browsing this forum: No registered users and 0 guests