Got a question? Ask a developer in our Developer's Corner Forum
| Find a PHP Error Using Print and Exit |
|
If you can't get PHP to log an error for you using our PHP logging script, another technique to try is to walk through the PHP code adding print and exit statements until you find the line in the code where the error is occurring.
If you modify the index.php file in your Joomla root directory to add the following print/exit statement, you should see the "We made it here" message when you reload your page in your browser: <?phpprint "We made it here"; exit; /**
This will confirm that your index.php file is being executed properly and that the issue isn't with .htaccess or some other Apache configuration.
The next step is to move the print/exit statements down in your file until you don't see the "We made it here" message: print "We made it here"; exit;
Then move here: // Set flag that this is a parent file print "We made it here"; exit;
And so on. This will help you find the line in index.php that is causing the issue or eliminate index.php as the cause of the problem.
|

