vizitor
06-11-2007, 07:53 PM
Hi community,
I've succesfully ported my phpNUKE phpBB Forum to vBulletin with all users & content. I also was able to include "Latest forum posts" on my phpNUKE index page.
There're two things where I need help...
1.) I want, that when a new user registers in the forum (vB), that this user is also put into the phpNUKE usertable (mySQL). I found an old code snipplet but unfortunately it's to old... it doesn't fit to my vBulletin Version (3.6.7-PL1).
[Release] phpnuke reg integration hack
--------------------------------------------------------------------------------
Before i post it i have to say 2 things
1) it is not my hack, it was made by those wonderful ppl from www.buffydownunder.com, I would like to give them all the credit and the thanks for hooking me up with this helpful hack
2) and this is the big one, the php-nuke and vbulletin databases have to be combined
I dont know if you want it if you have to combine databases, unless you have not installed one of them yet
hell maybe one of the great coders here could find a way for there to be 2 databases, i dunno
here she is
in the register.php file of vbulletin
-------------------------------------------------------------
FIND:
$DB_site->query("INSERT INTO user
(userid,username,password,email,".$newstylefield." parentemail,coppauser,
homepage,icq,aim,yahoo,signature,adminemail,showem ail,invisible,usertitl
e,joindate,cookieuser,daysprune,lastvisit,lastacti vity,usergroupid,timez
oneoffset,emailnotification,receivepm,emailonpm,op tions,birthday,maxpost
s,startofweek,ipaddress,pmpopup,referrerid,nosessi onhash) VALUES
(NULL,'".addslashes(htmlspecialchars($username))." ','".addslashes($passw
ord)."','".addslashes(htmlspecialchars($email))."' ,".$newstyleval."'".ad
dslashes(htmlspecialchars($parentemail))."','$copp auser','".addslashes(h
tmlspecialchars($homepage))."','".addslashes(htmls pecialchars($icq))."',
'".addslashes(htmlspecialchars($aim))."','".addsla shes(htmlspecialchars(
$yahoo))."','".addslashes($signature)."','$adminem ail','$showemail','$in
visible','".addslashes($usertitle)."','".time()."' ,'$cookieuser','".adds
lashes($prunedays)."','".time()."','".time()."','$ newusergroupid','".add
slashes($timezoneoffset)."','$emailnotification',' $receivepm','$emailonp
m','$options','".addslashes($birthday)."','".addsl ashes($umaxposts)."','
".addslashes($startofweek)."','".addslashes($ipadd ress)."','$pmpopup','"
.addslashes($testreferrerid['userid'])."','$nosessionhash')");
$userid=$DB_site->insert_id();
$user_regdate = date("M d, Y");
--------------------------------------------------------------
AFTER THAT PLACE:
//PHP-Nuke Registration Addition - by Matt Lyons matt@buffydownunder.com
$cryptpass=crypt($password);
mysql_query("insert into nuke_users (uname, email, url, user_regdate,
user_icq, user_aim, user_yim, user_viewemail, pass) values ('$username',
'$email', '$homepage', '$user_regdate', '$icq', '$aim', '$yahoo',
'$showemail', '$cryptpass')");
-------------------------------------------------------
If someone can tell me where to find the part in the vBulletin code (I think register.php is still correct, isn't it?) where the new user is put into the database (the code shown above I can't find in my register.php)... this would help me very much!
2.) Is there any chance to include/show the users which are online (into the forum) on a external page (my phpNUKE index page for example). Is there an option in vBulletin (which I have missed) which exports "Who is online" as a rss/xml/javascript feed? This would be okay/enough for me.
I hope someone can help me... I'm really happy with vBulletin... if I only could fix these last two problems :).
I've succesfully ported my phpNUKE phpBB Forum to vBulletin with all users & content. I also was able to include "Latest forum posts" on my phpNUKE index page.
There're two things where I need help...
1.) I want, that when a new user registers in the forum (vB), that this user is also put into the phpNUKE usertable (mySQL). I found an old code snipplet but unfortunately it's to old... it doesn't fit to my vBulletin Version (3.6.7-PL1).
[Release] phpnuke reg integration hack
--------------------------------------------------------------------------------
Before i post it i have to say 2 things
1) it is not my hack, it was made by those wonderful ppl from www.buffydownunder.com, I would like to give them all the credit and the thanks for hooking me up with this helpful hack
2) and this is the big one, the php-nuke and vbulletin databases have to be combined
I dont know if you want it if you have to combine databases, unless you have not installed one of them yet
hell maybe one of the great coders here could find a way for there to be 2 databases, i dunno
here she is
in the register.php file of vbulletin
-------------------------------------------------------------
FIND:
$DB_site->query("INSERT INTO user
(userid,username,password,email,".$newstylefield." parentemail,coppauser,
homepage,icq,aim,yahoo,signature,adminemail,showem ail,invisible,usertitl
e,joindate,cookieuser,daysprune,lastvisit,lastacti vity,usergroupid,timez
oneoffset,emailnotification,receivepm,emailonpm,op tions,birthday,maxpost
s,startofweek,ipaddress,pmpopup,referrerid,nosessi onhash) VALUES
(NULL,'".addslashes(htmlspecialchars($username))." ','".addslashes($passw
ord)."','".addslashes(htmlspecialchars($email))."' ,".$newstyleval."'".ad
dslashes(htmlspecialchars($parentemail))."','$copp auser','".addslashes(h
tmlspecialchars($homepage))."','".addslashes(htmls pecialchars($icq))."',
'".addslashes(htmlspecialchars($aim))."','".addsla shes(htmlspecialchars(
$yahoo))."','".addslashes($signature)."','$adminem ail','$showemail','$in
visible','".addslashes($usertitle)."','".time()."' ,'$cookieuser','".adds
lashes($prunedays)."','".time()."','".time()."','$ newusergroupid','".add
slashes($timezoneoffset)."','$emailnotification',' $receivepm','$emailonp
m','$options','".addslashes($birthday)."','".addsl ashes($umaxposts)."','
".addslashes($startofweek)."','".addslashes($ipadd ress)."','$pmpopup','"
.addslashes($testreferrerid['userid'])."','$nosessionhash')");
$userid=$DB_site->insert_id();
$user_regdate = date("M d, Y");
--------------------------------------------------------------
AFTER THAT PLACE:
//PHP-Nuke Registration Addition - by Matt Lyons matt@buffydownunder.com
$cryptpass=crypt($password);
mysql_query("insert into nuke_users (uname, email, url, user_regdate,
user_icq, user_aim, user_yim, user_viewemail, pass) values ('$username',
'$email', '$homepage', '$user_regdate', '$icq', '$aim', '$yahoo',
'$showemail', '$cryptpass')");
-------------------------------------------------------
If someone can tell me where to find the part in the vBulletin code (I think register.php is still correct, isn't it?) where the new user is put into the database (the code shown above I can't find in my register.php)... this would help me very much!
2.) Is there any chance to include/show the users which are online (into the forum) on a external page (my phpNUKE index page for example). Is there an option in vBulletin (which I have missed) which exports "Who is online" as a rss/xml/javascript feed? This would be okay/enough for me.
I hope someone can help me... I'm really happy with vBulletin... if I only could fix these last two problems :).