PDA


View Full Version : add a variable to adv_portal_welcomeback


keymistress
11-14-2005, 03:52 AM
hello all
i'd like to get a variable from my database e.g.

$query = $vbulletin->db->query_read("SELECT smsCredits FROM " . mob . " WHERE memberID LIKE " . $vbulletin->userinfo['userid']);


$result = $vbulletin->db->fetch_array($query);

$smsCredits = $result['smsCredits'];
$vbulletin->db->free_result($query);


i tried to put this code inside cmps_index.php and call the variable $smsCredits in my adv_portal_welcomeback template but it doesn't show up. any idea how i can do it? many thanks in advance!

Brian
11-15-2005, 02:12 PM
Add the code to your modules/welcomeblock.php file instead.

keymistress
11-16-2005, 11:37 PM
oops :X yup i should...
thanks!