Php from server cannot be displayed

Issues related to previewing and publishing your web site.
Post Reply
mindentezzel
 
 
Posts: 45
Joined: Sun Feb 09, 2014 12:58 pm

Php from server cannot be displayed

Post by mindentezzel » Mon Mar 25, 2019 7:08 pm

Dear Pablo,

I am sorry my left-handedness, but I am not able to understand the following:

I create forms

my php file can be displayed from my computer (it appears as html) but it cannot be displayed from the server. I get an 500 Internal Server Error. What do I make wrong?

I have old php files made by me with an earlier version of wysiwyg. They have been working on my server for years. If I re-edit and save them by wysiwyg and put them into a new server directory I get the same 500 error. Shall I change something in my web builder (that I really love)

T.

User avatar
Pablo
 
Posts: 15932
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: Php from server cannot be displayed

Post by Pablo » Mon Mar 25, 2019 7:27 pm

Usually this indicates an error in the syntax. For example, there may be quote or other invalid character in your settings.

To be able to help you I need to see the PHP code.

User avatar
BaconFries
 
 
Posts: 4469
Joined: Thu Aug 16, 2007 7:32 pm

Re: Php from server cannot be displayed

Post by BaconFries » Mon Mar 25, 2019 7:35 pm

my php file can be displayed from my computer (it appears as html)
PHP cannot be viewed/previewed locally on your PC it is required ti be uploaded to your server. Please also ensure that the page extension is named correctly eg .php and not .html
but it cannot be displayed from the server. I get an 500 Internal Server Error.

As the message says it is a internal server error which means something has went wrong on the server. Please contact you hosting provider for help. It may just be a temporary issue amd will resolve itself in a couple of hours.

mindentezzel
 
 
Posts: 45
Joined: Sun Feb 09, 2014 12:58 pm

Re: Php from server cannot be displayed

Post by mindentezzel » Mon Mar 25, 2019 7:53 pm

Dear Pablo,

pls give a look at these pics

php appears as html on my computer in chrome, I find it cool:

https://www.mediafire.com/view/av793av0 ... 1.jpg/file

https://www.mediafire.com/view/821t1141 ... l.jpg/file

I will ask my hosting provider about 500 internal server error
T.

User avatar
Pablo
 
Posts: 15932
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: Php from server cannot be displayed

Post by Pablo » Mon Mar 25, 2019 9:08 pm

To be able to help you I need to see the PHP code.
Menu -> Page -> Page HTML

It works locally because then the PHP code is filtered out.

mindentezzel
 
 
Posts: 45
Joined: Sun Feb 09, 2014 12:58 pm

Re: Php from server cannot be displayed

Post by mindentezzel » Mon Mar 25, 2019 10:20 pm

I was happy at a sad part :(

pls see the wbs file, it is a standalone file
https://www.mediafire.com/file/wea2o6g4 ... s.wbs/file

Thank you for your kind help
T.

User avatar
Pablo
 
Posts: 15932
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: Php from server cannot be displayed

Post by Pablo » Mon Mar 25, 2019 10:26 pm

I have found the following issues:
- the specified email address is not valid
- the form does not have an success and error page.
- the CSV points to ./public_html/kerdoivproba/keerdodo.csv, this is most likely not correct.
If the CSV file is in the same folder then it should be set to
./keerdodo.csv
Also, make sure the file exists on the server and is writable.

mindentezzel
 
 
Posts: 45
Joined: Sun Feb 09, 2014 12:58 pm

Re: Php from server cannot be displayed

Post by mindentezzel » Mon Mar 25, 2019 10:53 pm

on the server and is writable
There was an error, too many options were allowed
Thank you !!!

I do not know the precise terms, so I put a pic here for armatures like me.
It shows the right permissions: octal 0644 in both cases (csv and php).

https://www.mediafire.com/view/19u3bo7o ... e.jpg/file

Thank you for you fast and kind help
T.

User avatar
Pablo
 
Posts: 15932
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: Php from server cannot be displayed

Post by Pablo » Mon Mar 25, 2019 10:57 pm

Maybe it needs to be 666 or 777?
Does it work when you disable CSV?

mindentezzel
 
 
Posts: 45
Joined: Sun Feb 09, 2014 12:58 pm

Re: Php from server cannot be displayed

Post by mindentezzel » Mon Mar 25, 2019 11:18 pm

I have tried both options.
No, it works only with 0644

Yes, it works without csv, but of course it does not write :)

Post Reply