The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
![]()
Hey all,
Okay I will cut straight to the point, I have purchased a tipping competition script (from http://perlwebsite.com/tipslite.htm) the script requires users to register to take part in the tipping competition however what I am trying to do is allow members of my vBulletin Publishing Suite 4.0 to login with their forum details. I am a complete newbie to perl so don't know that much about it however that is the code this tipping competition is scripted in but mainly wish to make it where only those registered on my site can login to place tips. Any help you can provide would be greatly appreciated, anything you require from me just let me know. |
#2
|
|||
|
|||
![]()
Is it encrypted?
|
#3
|
|||
|
|||
![]()
You will need to get the perl script to auth via the database (mysql in most cases), and this will require you to use perl modules like DBI and CGI.
If you don't have these modules, you can use CPAN to get them (www.cpan.org). Here's a "start" for you to wet your whistle: Code:
#!/usr/bin/perl -w use strict; use CGI qw(:standard); use CGI::Carp qw(fatalsToBrowser); # Invoke fatal error messages at compile time. use DBI; sub dbConnect() { my ($dsn) = "DBI:mysql:dbname:localhost"; my ($user_name) = ""; my ($password) = ""; my ($dbh); $dbConnect = DBI->connect ($dsn, $user_name, $password, { RaiseError => 1 }); return $dbConnect; } my $query = CGI->new(); my( $username ) = $query->param("username"); my( $password ) = $query->param("password"); # connect to database my $dbh = dbConnect(); my $sql = qq{ SELECT userid FROM user WHERE username=? AND password=MD5(?) }; my $sth = $dbh->prepare( $sql ); $sth->execute( $username, $password ); my( $userid ) = $sth->fetchrow; if($userid){ #logged in }else{ #not logged in } exit 0; ![]() |
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|