Hi all,
I hope you can help, I tested this on XAMPP and it worked a treat, really can’t see why it’s broken when putting it online (famous last words!).
At one stage when I tried searching for a number (that I know is in the database), it went to a blank page, HTTP error - something to do with couldn’t find the page or there was a programming error.
That’s not happening now, but no matter what I enter in the search input, it always (and only) outputs the following $format and $messages.
It seems to ignore if (strlen($search_term) <= 3) and/or automatically assumes all entered values meets this criteria.
if (strlen($search_term) <= 3) {
$format = ‘class=“error”’;
$messages = “Enter at least four numbers.”;
}
I am also unsure if it’s actually connecting to the database as well but haven’t seen an error message.
I have attached the full code if you’d be OK to check it out briefly? I’m almost convinced it’s a syntax issue, why would it work in XAMPP and not online?
My host’s details are (if relevant):
Software
PHP: Installed (Version 5.4.29)
Python: Installed (Version 2.6.6)
Perl: Installed (Version 5.10.1)
Apache: Installed (Version 2.2.15)
MySQL: Installed (Version 14.14)
search.txt (1.99 KB)