Jump to content

Does php need to be "enabled"?


blowfly123

Recommended Posts

I'm trying to give a friend a facelift on a decade old website. I'm doing some very mild php (just includes to pull in menu items, header, footer, things like that) but every php file is coming up 404. I've emailed their host but they haven't responded. Is it possible that a site that hasn't really been changed in almost 10 years might need to have php turned on or something? There's no php on the current site. Includes are done with code I've never seen:

 


 

I'd rather not use that since it looks like some old-ass code to me.

 

Thoughts?

Link to comment
Share on other sites

That's an ASP include, not PHP. Classic ASP is more convenient term after birth of ASP.NET.

 

Which means their server is not Apache but IIS (Internet Information Services - Microsoft).

 

Which means they don't have PHP installed on the server machine, most probably. But you CAN install PHP to run on IIS. Most modern hosts allow you to purchase a PHP installation on your server machine for a small fee, or most of them for free. Did you have a look at the Host's Control Panel?

Link to comment
Share on other sites

is also code used with shtml. Did the main files have the filename extension .shtml ?

 

You might find that the server processes shtml for simple "includes" where it doesn't process PHP. Just use the code and rename files with .shtml

Edited by Wickham
Link to comment
Share on other sites

SHTML is still a good service for includes, it is just rather basic and not as many nifty thing to do as PHP, if it is mostly includes it is fine... but you cannot mix SHTML with PHP or other languages, it is one or the other.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...