Author Topic: Question on "Steal Credits"  (Read 9106 times)

Offline Daniel15

Re: Question on "Steal Credits"
« Reply #15 on: May 26, 2006, 10:19:43 pm »
That's not an exclamation, it's an apostrophe ;)

Anyway,
Code: [Select]
WHERE memberName = '{$_POST['stealfrom']}'}'", __FILE__, __LINE__);
That definately looks wrong. I believe it should be
Code: [Select]
WHERE memberName = '{$_POST['stealfrom']}'", __FILE__, __LINE__);

Offline Basil Beard

Re: Question on "Steal Credits"
« Reply #16 on: May 27, 2006, 06:42:36 am »
Woah yeah. Those things are so small they have a habbit of winding up in the wrong place and messing up your code =P
Arrrrr!

Offline tazpot

Re: Question on "Steal Credits"
« Reply #17 on: May 27, 2006, 08:18:30 pm »
 :-[
Quote
That's not an exclamation, it's an apostrophe
  :-[  oops!

Thanks guy's i will give it a shot. O0

Offline ibexy

Re: Question on "Steal Credits"
« Reply #18 on: July 04, 2007, 07:54:36 pm »
Insert this code at the top of all your items, right below the <?php line.
Code: [Select]
global $sourcedir;
require_once($sourcedir . '/Subs-Post.php');

And insert this code at the end of the code for the actual item before the return line.
Code: [Select]

&nbsp; &nbsp; $result = db_query("SELECT memberName
FROM {$db_prefix}members
&nbsp; &nbsp; &nbsp; &nbsp; WHERE ID_MEMBER = {$ID_MEMBER}'", __FILE__, __LINE__);&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
$row = mysql_fetch_array($result, MYSQL_ASSOC);
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $theif = $row['memberName'];
&nbsp; &nbsp; $result = db_query("SELECT ID_MEMBER
FROM {$db_prefix}members
&nbsp; &nbsp; &nbsp; &nbsp; WHERE memberName = '{$_POST['stealfrom']}'}'", __FILE__, __LINE__);&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
$row = mysql_fetch_array($result, MYSQL_ASSOC);
$pmfrom = array(
'id' => 1,
'name' => 'Your name',
'username' => 'Your name'
);
$pmto = array(
'to' => array($row['ID_MEMBER']),
'bcc' => array()
);
sendpm($pmto, 'PM Subject', "Pm body. Use {$theif} for the name of the guy who stole, and {$steal_amount} for the amount of points stolen", 0, $pmfrom);


I have implemented the above but am getting error messages. Any help please