Page 1 of 1

Error when updating a ticket

Posted: Sun Feb 01, 2009 5:35 pm
by Jake Adkins
Hey ya'll, I just learned about Hesk last night and I am playing around with it. I have a Fedora 10 box with the latest PHP/MySQL installed. I created a database named hesk and for right now i am using root/mypassword to access it.

Eveything on the install went well (I had a couple of permission problems with folders in /var/www/html but the script told me what to fix, great job on that guys) and within about 10 minutes I had it up and I was playing with it. I thought I had it licked until I created a ticket and then tried to update it with an "Add Reply" feature and I get this error. It's in a red box and says.

Can't execute SQL

Please notify webmaster at ...my-email

I have tried it from a couple of the different users I created inside the Hesk software but I still get the same message. Any ideas on what I am doing wrong?

-Jake

Posted: Sun Feb 01, 2009 6:27 pm
by Klemen
Go to settings, enable Debug mode then try replying again and see if you get an error message with more info.

Posted: Sun Feb 01, 2009 6:55 pm
by Jake Adkins
Here is the error message. If I weren't such a noob I may understand what it is asking of me. Thanks for looking at it. -Jake


Can't execute SQL: INSERT INTO `hesk_replies` ( `replyto`,`name`,`message`,`dt`,`attachments`,`staffid` ) VALUES ( '1','jake adkins','Thank you for opening a ticket. We will get to you as soon as possible.

jake's signature
',NOW(),'','3' )

MySQL said:
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 's signature
',NOW(),'','3' )' at line 5

Please notify webmaster at ...

Posted: Sun Feb 01, 2009 7:23 pm
by Klemen
Try changing this in admin/admin_reply_ticket.php :

Code: Select all

$message .= "<br><br>$_ SESSION[signature]<br>&nbsp;";
to

Code: Select all

$message .= "<br><br>".addslashes($_ SESSION['signature'])."<br>&nbsp;";
and see if it helps.


NOTE: Remove the space between "$_" and "SESSION", can't post without the sapce, need to tweak my mod_security settings...

Posted: Sun Feb 01, 2009 10:34 pm
by Jake Adkins
That worked! Thanks a bunch. When we get it setup and working we will purchase a license from you.Thank you. -Jake