as4s1n
New Member
- Messages
- 174
- Reaction score
- 4
- Points
- 0
I have a script set up so that if there is an error on any page a PM is sent directly to me. The only problem is, that whenever there is an error I always get the same error:
Fatal error: Call to a member function prepare() on a non-object in home/sikuneh/public_html/inc/SL_modules.php on line 26
The only problem is, everything checks out and looks perfectly fine.
PHP:
DB structure:
Id, toUser, from, subject, message, date, read
Please help.
Fatal error: Call to a member function prepare() on a non-object in home/sikuneh/public_html/inc/SL_modules.php on line 26
The only problem is, everything checks out and looks perfectly fine.
PHP:
PHP:
$closingString = "Error with script. The webmaster has already been notified.";
echo $closingString;
$sth = $dbh->prepare("INSERT INTO mail VALUES(0,:T,:F,:S,:M,now(),0)");
$sth->bindValue(":T",'10');
$sth->bindValue(":F",'10');
$sth->bindValue(":S",'Error(s)');
$sth->bindValue(":M",$logstring);
$sth->execute();
DB structure:
Id, toUser, from, subject, message, date, read
Please help.