Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 02/27/2017 in all areas

  1. display_errors = On for all versions of php on Tommy now. Here is an example file where the line is missing a semicolon http://krydos.heliohost.org/error.php How does that look? I opened the file with vim, and it says the encoding type along the bottom of the screen. It caught my eye because when a file has standard linux encoding it doesn't show anything there. This is actually a really common reason for cgi executables to cause 500 errors, but it rarely makes a difference with php scripts. As you could see the php still executed, but threw header already sent errors. To fix the encoding I just copied the code from the broken file, deleted the broken file, created a new file with the same name in vim and pasted the code back in. I think your real question isn't how did I do it, but rather how can you do it though so it doesn't happen again in the future right? I would recommend creating the file through cpanel file manager and then copy/pasting the code in if you think you might be having encoding issues. root@tommy [/home/hypo/public_html]# file -i * cgi-bin: inode/directory; charset=binary count: application/octet-stream css: inode/directory; charset=binary cus.txt: text/plain; charset=us-ascii error_log: text/plain; charset=us-ascii images: inode/directory; charset=binary indexgood.php: text/x-php; charset=us-ascii index.php: text/x-php; charset=us-ascii js: inode/directory; charset=binary listenerold.php: text/x-php; charset=us-ascii listener.php: text/x-php; charset=us-ascii paypal_success.php: text/html; charset=us-ascii resp.txt: text/plain; charset=us-ascii I'm not sure because I already deleted the broken file, but I believe it was octet-stream just like your count file.
    1 point
×
×
  • Create New...