Recommended red error box analysis
-
Hi, I was able to track down a red box error on my wordpress page by myself and wanted to share the way I did.
( Please delete if this is common knowledge ?? )1. In wordpress go to Plugins, Editor. And there select Contact Form 7.
2. Choose the file contact-form-7/includes/contact-form.php for editing.
3. Find the function form_response_output() and go to the end of the function ( where the surrounding brackets close, right after the return $output; statement.
4. We want to get as many informations as possible, so insert the following statement just before the return part:
$output .= "<ul><li>" . implode("</li><li>", error_get_last() ) . "</li></ul>";
Save afterwards, of course.
5. Now, the next time you try out contact form you will recieve an unordered list after your red output box with the last error php encountered. The structure of the array is:
Array
(
[type] => Errorcode
[message] => Text
[file] => Location
[line] => Number
)Armed with these informations, your next error-search with the community will probably be much easier.
Good luck hunting your errors!
- The topic ‘Recommended red error box analysis’ is closed to new replies.