473,372 Members | 1,049 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,372 software developers and data experts.

Why are my PHP files are not being executed (PHP keywords/syntax being ignored)

I have been hosting a website on the same server for roughly 2 years.
The entire site is based on a group of PHP scripts. Today, without
changing a thing, the server stopped recognizing all PHP keywords and
syntax. When I use firefox, the page simply displays a text/plain
version of my source code. When I use IE, the page loads as text/html,
however, all lines of PHP code (between "<?" and "?>") are displayed as
text.

My assumption is that my host has stopped providing PHP extensions.
Can anybody confirm this or give me another explanation?

All help is greatly appreciated!

-JR

Sep 13 '05 #1
2 1747
>I have been hosting a website on the same server for roughly 2 years.
The entire site is based on a group of PHP scripts. Today, without
changing a thing, the server stopped recognizing all PHP keywords and
syntax. When I use firefox, the page simply displays a text/plain
version of my source code. When I use IE, the page loads as text/html,
however, all lines of PHP code (between "<?" and "?>") are displayed as
text.

My assumption is that my host has stopped providing PHP extensions.
Can anybody confirm this or give me another explanation?

All help is greatly appreciated!


Your files are not being treated as PHP, but as text. It is possible
that the Apache directive to treat .php files as PHP got lost.
(It's possible this was in one of YOUR .htaccess files, rather than
the Apache config file, but if the host is offering PHP, there's
not a lot of point in making it difficult to use.)

Or PHP is broken (I've managed to do this to myself upgrading some
of the libraries PHP uses.) Or your host upgraded Apache and didn't
configure in PHP. Ask your host what's going on.

Incidentally, it's just this sort of thing that makes it worthwhile
to keep stuff like DB passwords *OUTSIDE* the document tree. If PHP
breaks, as it has apparently in your case, it still won't serve
the passwords. If it's not broken, PHP can get to it, but it will
use it, not display it, assuming the code is written to do that.

Gordon L. Burditt
Sep 13 '05 #2
ja*************@gmail.com wrote:
I have been hosting a website on the same server for roughly 2 years.
The entire site is based on a group of PHP scripts. Today, without
changing a thing, the server stopped recognizing all PHP keywords and
syntax. When I use firefox, the page simply displays a text/plain
version of my source code. When I use IE, the page loads as text/html,
however, all lines of PHP code (between "<?" and "?>") are displayed as
text.

My assumption is that my host has stopped providing PHP extensions.
Can anybody confirm this or give me another explanation?

All help is greatly appreciated!


Don't you use '<?php' to start your code blocks? Maybe the provider has
switched short_open_tag off.

C.
Sep 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: John Chiurato | last post by:
Yes, I am a newbie to PHP. Worried that using PHP may affect my search engine ranking. Would a script like the one below be adequate? <?php class Page { var $Title; var $Keywords; var...
0
by: R. Rajesh Jeba Anbiah | last post by:
Q: Is PHP search engine friendly? Q: Will search engine spiders crawl my PHP pages? A: Spiders should crawl anything provided they're accessible. Since, nowadays most of the websites are been...
31
by: Brian Sabbey | last post by:
Here is a pre-PEP for what I call "suite-based keyword arguments". The mechanism described here is intended to act as a complement to thunks. Please let me know what you think. Suite-Based...
0
by: Tom Lee | last post by:
Hi, I'm new to .NET 2003 compiler. When I tried to compile my program using DEBUG mode, I got the following errors in the C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7 \include\xdebug...
47
by: rawCoder | last post by:
Hi, Just wanted to know if there is any speed difference between VB conversion Keywords like CInt, Clng, CStr, CDbl, CBool etc. ..NETs Convert.To<...> methods. And which is better to be...
21
by: Nicholas Sherlock | last post by:
Hey all, People on my website register to be allowed access to certain downloads. I store these files above the document root so that they can't be accessed by Apache (Only from PHP). I wrote a...
7
by: Don NJ | last post by:
First my site name is Sinfullblisslingerie.com. I'm starting this little business to try and make some money on the side. My kids will be going to college in a few years... Anyway, in the past...
1
by: Kesavan | last post by:
I install apache2 in /usr/local/apache2 and install php5 by ./configure --with-apxs2=/usr/local/apache2/bin/ apxs PHP is successfully installed in my system. But now my .php files inside...
12
by: duzhidian | last post by:
failed to open stream: No such file or directory I have the programs like this structure: a.php is locate at . b.php is located at ./lib c.php is located at ./lib/sublib a.php uses a...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.