edit_contact.php giving 500 internal server error

Occasional Participant

edit_contact.php giving 500 internal server error

I downloaded the files from your site and uploaded them to my server and I am getting a 500 internal server error when trying to access the edit_contact.php file.

 

I can get rid of this if I comment out the following line:

      header('Content-Type: text/html; charset=UTF-8');

 

This will then display the form, but nothing will be populated as it should be.

 

When I look in my error logs I see the following errors:

 

      PHP Fatal error: Call to undefined function phpheader() - this is when I header line is not commented out

 

      PHP Warning: Invalid argument supplied for foreach() in /*/*/*/cc/edit_contact.php on line 1 - this is when the header line is commented out.

 

 

The other forms seem to be working just fine. What can I do to fix this problem?

4 REPLIES 4
Occasional Participant

Also, this works on my local install of MAMP, but not when I upload it to my bluehost account.

Hi,

 

I'd recommend checking a few things.  First, make sure when you upload to bluehost you are uploading in binary, NOT ASCII mode.

 

Second, make sure bluehost has at least PHP version 5 or higher.

 

Thirdly, go into the file and line that is generating the "Call to undefined function phpheader()" error, and make sure nothing looks wrong.  In some cases, a server won't recognize a line break, so I would go into that file and put an extra line break around the line that seems to be causing problems.

 

Best Regards,

Shannon W.

API Support Specialist

Occasional Participant

Thanks for the steps. I got this working yesterday by recreating the file (by copy and pasting into a brand new file).

Thanks for the update on this!

Elijah G.
API Support Engineer
Developer Portal

View API documentation, code samples, get your API key.

Visit Page