Want help in this code

Started on the old forum in May 2011 · view the original in the archive · old links redirect here

7 replies · 628 views · started 15 years ago · 1 min read

5 participants
Hammad Developer · 89 posts #1

I m using THis mOdule for my johncms site Module is working fine But giving error in this code please Help me if you can

mysql_query("insert into privat values(0,'" . $nikus['name'] . "','User " . $login . " Gave you a gift [(To Prevent Bbcode here)url=".$home."/users/priz.php?act=in]Click to view gift.','" . $realtime . "','" . $login . "','in','no','You have received a gift!','0','','','','');"); mysql_query("UPDATE usersSET monetki=monetki-1 WHERE id = '$user_id'"); echo ' Gift successfully sent, '.$nikus['name'].' will be notified of your gift! Attention: We're writing off 1-on coin for the gift! Profile '.$nikus['name'].' '; break;

HEre is The i m getting

Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/mobhellc/public_html/users/podarok.php on line 56 In http://mobhell.com/users/podarok.php?user=85

i know its because of Wrong ' " or ; But Point me If You can THanks

WapdeviL.iN Most Updated Services Portal.. Want To increase Site Users ???

kei_ki7 Senior · 431 posts #2

Hammad wrote: I m using THis mOdule for my johncms site Module is working fine But giving error in this code please Help me if you can

mysql_query("insert into privat values(0,'" . $nikus['name'] . "','User " . $login . " Gave you a gift [(To Prevent Bbcode here)url=".$home."/users/priz.php?act=in]Click to view gift.','" . $realtime . "','" . $login . "','in','no','You have received a gift!','0','','','','');"); mysql_query("UPDATE usersSET monetki=monetki-1 WHERE id = '$user_id'"); echo ' Gift successfully sent, '.$nikus['name'].' will be notified of your gift! Attention: We're writing off 1-on coin for the gift! Profile '.$nikus['name'].' '; break;

HEre is The i m getting

Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/mobhellc/public_html/users/podarok.php on line 56 In http//mobhell.com/users/podarok.php?user=85

i know its because of Wrong ' " or ; But Point me If You can THanks

🙂 Btw what is the line 56 there? Also use php bbcode

mysql_query("insert into `privat` values(0,'" . $nikus['name'] . "','User " . $login . " Gave you a gift [(To Prevent Bbcode here)url=".$home."/users/priz.php?act=in]Click to view gift[/url].','" . $realtime . "','" . $login . "','in','no','You have received a gift!','0','','','','')");

try use this

Did I help you? You can help me too Your donations will help me finance my studies.

CuteAmit Junior · 35 posts #4

I fixed the bug. Try it out !

mysql_query("insert into `privat` values(0,'" . $nikus['name'] . "','User " . $login . " Gave you a gift [(To Prevent Bbcode here)url=".$home."/users/priz.php?act=in]Click to view gift[/url].','" . $realtime . "','" . $login . "','in','no','You have received a gift!','0','','','','');");
mysql_query("UPDATE `users` SET `monetki`= 'monetki-1' WHERE `id` = '$user_id'");
echo "<p>Gift successfully sent, $nikus['name'] will be notified of your gift!<br/>Attention: We're writing off 1-on coin for the gift!<br/>Profile <a href=\"profile.php?user=$nikus['id']\">$nikus['name']</a></p>";
break;

For Latest Technology Tips & Tricks Click Here

Hammad Developer · 89 posts #5

Amit Thanks FOr reply But Problem Still Not Fixed Btw Thanks For Your time now m getting error

Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/mobhellc/public_html/users/podarok.php on line 56

WapdeviL.iN Most Updated Services Portal.. Want To increase Site Users ???

Ponick Developer · 216 posts #6

Hammad wrote: I m using THis mOdule for my johncms site Module is working fine But giving error in this code please Help me if you can

mysql_query("insert into privat values(0,'" . $nikus['name'] . "','User " . $login . " Gave you a gift [(To Prevent Bbcode here)url=".$home."/users/priz.php?act=in]Click to view gift.','" . $realtime . "','" . $login . "','in','no','You have received a gift!','0','','','','');"); mysql_query("UPDATE usersSET monetki=monetki-1 WHERE id = '$user_id'"); echo ' Gift successfully sent, '.$nikus['name'].' will be notified of your gift! Attention: We're writing off 1-on coin for the gift! Profile '.$nikus['name'].' '; break;

HEre is The i m getting

Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/mobhellc/public_html/users/podarok.php on line 56 In http//mobhell.com/users/podarok.php?user=85

i know its because of Wrong ' " or ; But Point me If You can THanks

i saw a syntex error here its

We're writing off

lol, i dont sure about yor script if it isnt in unicode then thats the problem.

just use replace this with

We´re writing off 

or

 we are writing off
/* I don't know everything hehe */

Find me on facebook

nimeshka Developer · 180 posts #7

Open podarok.php in a text editor ( notepad ) Press ctrl + G and enter 56 to go to that line with error....Then check if you have missed any of (' " 😉 these characters at the end of lines......

External image (may be gone)

I'm Proud to be a Sri Lankan!

Hammad Developer · 89 posts #8

Ponick wrote: i saw a syntex error here its

We're writing off

lol, i dont sure about yor script if it isnt in unicode then thats the problem.

just use replace this with

We´re writing off 

or

 we are writing off

actually i translated that with google translator thats why i was getting that error Thanks for help

WapdeviL.iN Most Updated Services Portal.. Want To increase Site Users ???

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close