Aliixer LoginShare Module

This is where you share YOUR scripts with others

Moderators: egami, macek, gesf

Post Reply
New php-forum User
New php-forum User
Posts: 6
Joined: Mon Aug 04, 2008 12:55 pm

Mon Aug 04, 2008 1:10 pm

Aliixer is a new search engine, not a lot of people are using it yet but I expect that to change. I personally have replace my google usage with Aliixer I like it so much. But others may have a different opinion of it.

Anyway, one cool thing this search engine has is called LoginShare. It lets webmasters (you and me) allow users on our websites to login with their Aliixer login.

I use it on my 30+ forums and blog service websites to allow users to skip the sign up process and just use their login. The code is simple as can get, they have a very nice and secure way of doing this without information at risk of being stolen.

I've simply pasted the example PHP code from their website, the full documentation is at:

Code: Select all

//Get the access code from Aliixer and store as $accesscode variable
$accesscode = $_REQUEST['accesscode'];

//Use the $accesscode variable to post to the API
$api_url = " share/?accesscode=$accesscode";
$data = file_get_contents($api_url);;

$xml = new SimpleXmlElement($data);

$authentication = $xml->loginverification->authentication; // <authentication> Note: returns 1 for success 0 for failure
$username = $xml->loginverification->username; // <username>
$firstname = $xml->loginverification->first_name; // <first_name>
$lastname = $xml->loginverification->last_name; // <last_name>
$email = $xml->loginverification->email; // <email>
$birthmonth = $xml->loginverification->birth_month; // <birth_month>
$birthday = $xml->loginverification->birth_day; // <birth_day>
$birthyear = $xml->loginverification->birth_year; // <birth_year>

if ($authentication == "0"){
##If <authentication> </authentication> equals 0 then the request failed. Print a message to the user.
print "A invalid access code was provided or your accessing this page without permission.";
} else {
##Run whatever your login process is here. (example: create a session)


//Uncomment for debugging
//echo $authentication;
//echo $username;
//echo $firstname;
//echo $lastname;
//echo $email;
//echo $birthmonth;
//echo $birthday;
//echo $birthyear;
Anyone need help making LoginShare work let me know by the way, I've done it 1000 times with about every forum script there is.


Post Reply