FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » why php echo does not show up in HTML?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: why php echo does not show up in HTML? [message #181637 is a reply to message #181632] Fri, 24 May 2013 14:19 Go to previous messageGo to previous message
steve nospam is currently offline  steve nospam
Messages: 11
Registered: May 2013
Karma:
Junior Member
>
> You get your:
>
> AddType application/x-httpd-php .htm
>
> added to the apache config file on the server.
>

What I did is add the above line to my .htaccess file on my home page.
And it worked for apache server on my PC. But when I did the same for
my hosting company, then what happens when I clicked on the file, the
browser was asking me to download the .htm file ! instead of opening
it
as a web page.

Do you think I need to add the above line to apache config file? But
my hosting company is public company, I have no control over what web
server they are using and I can't ask them to edit the web server
config files for me. This is a shared server.

> However, you should note if if you do that, any .htm file will be sent
> to PHP by apache, even if there is no PHP in it. That adds an extra step
> to getting your files served up. That is why people have been suggesting
> to change the files which use PHP to have a .php extension.
>

It is not the delay isssue. It simply did not work as I said above.

> Personally I add:
>
> AddType application/x-httpd-php .phtml
>
> to the apache config file, and use that for files containing any PHP.
> That way the PHP interpreter is only involved when a file actually has
> PHP in it.
>

I can't edit the web server config files on the my hosting ISP
computer !
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: PHP Contact Form, mt-rand(), problem Validating 1 input
Next Topic: Parsing mbox files with Windows Php
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Nov 24 12:09:25 GMT 2024

Total time taken to generate the page: 0.04669 seconds