看见好几个人问tiandi要这个源码结构,索性帖一下吧,注明,不是tiandi写的,有需要的直接拿走。
<?php 
//    第三方登录插件调用,如有BUG请联系作者!! 
/*===========================================================
**/
if(!function_exists('json_encode'))
{
	include_once('../cls_json.php');
	function json_encode($value)
	{
		$json = new JSON;
		return $json->encode($value);
	}
}
if(!function_exists('json_decode'))
{
	include_once('../cls_json.php');
	function json_decode($json , $um = false)
	{
		$json = new JSON;
		return $json->decode($json , $um);
	}
}
function & website($type)
{
	$path = dirname(__FILE__);
	if(!file_exists($path.'/config/'.$type.'_config.php') || !file_exists($path.'/'.$type.'.php') || !file_exists($path.'/cls_http.php'))
	{
		return false;
	}
	
	include_once($path.'/config/'.$type.'_config.php');  //  装载第三方申请的东西
	if(!defined('RANK_ID'))  //  尚未安装
	{
		return false;
	}
	include_once($path.'/'.$type.'.php');
	
	return new website();
}
?>
文章评分3次,平均分5.0:★★★★★
    
	
	
include_once($path.’/config/’.$type.’_config.php’); // 装载第三方申请的东西
这句坏的意思是不是还得用第三方插件
不是,是指你向第三方申请登录时,给你的key和密钥等一系列验证的东西
好,太棒了