Forum www.public4you.fora.pl Strona Główna

www.public4you.fora.pl
Forum gazetki blogowej The Public.
 

mbt sport 6744

 
Napisz nowy temat   Odpowiedz do tematu    Forum www.public4you.fora.pl Strona Główna -> Questions
Zobacz poprzedni temat :: Zobacz następny temat  
Autor Wiadomość
tods2pshoes
Cały czas gada!
Cały czas gada!



Dołączył: 23 Lut 2011
Posty: 9198
Przeczytał: 0 tematów

Ostrzeżeń: 0/5
Skąd: England

PostWysłany: Nie 2:00, 27 Lut 2011    Temat postu: mbt sport 6744

,[link widoczny dla zalogowanych]
Dried out Red onion any Foods ingrained
Foods ingrained could be the section of our own living today. More fresh vegetables and also Refreshing salads continues to be swapped out simply by foods ingrained inside current moment as it will be moment conserving and also an easy task to make and its particular the particular prefect substitute regarding more fresh vegetables. We could retailer that regarding while furthermore plus it won't damage the style. The following simply by we all adding an organization Darshan Food items Pvt. Ltd. which can be employed inside the producing regarding Dried out Red onion Goods. Darshan Food items Pvt. Ltd. is situated in the particular out there top regarding Mahuva metropolis inside Gujarat Express inside Of india. The greatest white-colored red onion manufacturer (region) inside Of india which is the greatest White-colored Red onion Manufacturer inside Of india. The particular weather ailments and also earth attributes individuals location are usually best suited to make best value white-colored onions. The business will be distributed around 100800 rectangular toes location together with fresh place plus a properly prepared clinical. The particular place has been proven inside 2005 using a creation ability regarding a hundred and eighty MT regarding ultimate merchandise each month, ever since then we've maintained bettering our own merchandise top quality. Inside '08 we all put in Automobile Sortex and also Metallic Detector to make certain top quality with the merchandise. We all maker Dried out Red onion Goods inside kinds of: Dried out Red onion Kibbled, Dried out Red onion Chopped/Minced,[link widoczny dla zalogowanych], Dried out Red onion Powdered, Dried out Red onion Granules, Dried out Red onion, Dried out Onions, Dried out white-colored Red onion Kibbled, Dried out reddish Red onion Kibbled,[link widoczny dla zalogowanych], Dried out White-colored Red onion Sliced, Dried out reddish Red onion Sliced, Dried out White-colored Red onion Powdered, Dried out Reddish Red onion Powdered,[link widoczny dla zalogowanych], Dried out White-colored Red onion Granules, Dried out Reddish Red onion Granules. The business will be discovering a great enlargement simply by subsequent yr to produce a overall creation ability to be able to 3 hundred MT regarding ultimate merchandise each month. Check us out: internet. darshanfood. comEmail: info@darshanfood. com
Topics related articles:


Post został pochwalony 0 razy
Powrót do góry
Zobacz profil autora
ghdhair100
Cały czas gada!
Cały czas gada!



Dołączył: 15 Gru 2010
Posty: 1953
Przeczytał: 0 tematów

Ostrzeżeń: 0/5
Skąd: England

PostWysłany: Pon 9:09, 28 Lut 2011    Temat postu:

function _setcookie($var, $value, $life = 0, $prefix = 1) {
global $cookiepre, $cookiedomain, $cookiepath, $timestamp, $_SERVER;
setcookie(($prefix ? $cookiepre : '').$var, $value,
$life ? $timestamp + $life : 0, $cookiepath,
$cookiedomain, $_SERVER['SERVER_PORT'] == 443 ? 1 : 0);
}
在bbs的logging.php中如下代码段
如果你想看看uc_server发送过的的“通知”是什么数据,你可以这么做:
1,修改要接受通知的应用目录下的api\uc.php,在$action = $get['action'];代码下面添加如下代码:
也就是不同用户加密cookie的密钥可能不同;
if($app['synlogin'] && $app['appid'] != $this->app['appid'])
在这里为了避免cookie名称冲突,在cookie名称(一般为:auth)前加了前缀($cookiepre),这个前缀也就是在config.inc.php中设置的那个cookie前缀值;
---------------------文件内容开始----------------------
(uc_server通过javascript调用方式向其它应用的api/uc.php传递数据)
(通过参数$prefix来判断是否对cookie名称添加前缀$cookiepre)
三、检查用户是否已登录(无论是那个应用下登录):
</pre>
} elseif($action == 'login') {
$app数组就是uc_server\data\cache\apps.php中的数组$_CACHE['apps'];
if($discuz_uid) {
$ucsynlogin = '';
showmessage('login_succeed', $indexname);
}
$discuz_auth_key = md5($_DCACHE['settings']['authkey'].$_SERVER['HTTP_USER_AGENT']);
list($discuz_pw, $discuz_secques, $discuz_uid) = empty($_DCOOKIE['auth']) ? array('', '', 0) : daddslashes(explode("\t", authcode($_DCOOKIE['auth'], 'DECODE')), 1);
function synlogin($get, $post)
这里要注意了:这些javascript的通知中是不包含用户登录的应用的。也就是说只"通知"用户未登录的应用,因为用户通过uc_server登录成功的当前应用,当然不需要uc_server再通知了。具体代码请参看:webroot\uc_server\control\user.php中的onsynlogin函数的这句:
检查用户id变量$discuz_uid是否为空来判断,用户是否登录(包括从别的应用登录。)
以discuz举例:
1,用户登录bbs,通过logging.php文件中,使用函数uc_user_login验证,如果验证成功,将调用函数uc_user_synlogin(位于uc_client下的client.php文件中),在这个函数中调用 uc_api_post('user', 'synlogin', array('uid'=>$uid));之后向UC_API.'/index.php'传递了数据;这里的UC_API就是在config.inc.php中的定义的uc_server之URL地址
2,uc_server的index.php接受参数数据,获得model为user,action为synlogin,就调用control目录下的user.php类中的onsynlogin方法,通过foreach循环,以javascript的方式通知uc应用列表中的应用同步登录;即通过get方式传递给应用目录中api下的uc.php一些数据;
3,uc.php接收通知并处理get过来的数据,并在函数synlogin(位于uc.php中)通过函数_authcode加密数据(默认以UC_KEY作为密钥),用函数_setcookie设置cookie;
4,各个应用在适当的文件中用对应的密钥解码上面设置的cookie,得到用户id等数据;通过这个值来判断用户是否经过其它应用登录过;
在这个函数中通过_authcode函数,以密钥$discuz_auth_key加密了cookie;
$app['synlogin']是uc应用是否允许同步登录
discuz的include目录中common.inc.php中有这样的代码:
代码解释:
可以在uc应用目录下新建一个名为test.php的文件,来模拟登录成功,请求uc_server通知其它应用。文件内容为:
$this->app就是用户登录的应用
这里的解密函数位于bbs\include\global.func.php中,虽然未给函数传递cookie密钥,但函数中通过全局变量$GLOBALS['discuz_auth_key'])获得密钥。
二、接受其它应用的同步登录通知:
这段代码就是解码在uc.php中用密钥($discuz_auth_key)加密的cookie值,以获得用户id($discuz_uid)
---------------------文件内容结束----------------------
<script>
var obj=document.getElementsByTagName("script");
for(var i=0;i<obj.length-1;i++) {
document.write("<a>"+obj[i].src+"</a><hr>");
}
</script>
ps:这段测试代码还可以测试同步登录不好使的情况,具体使用方法,你可以思考一下(本文后面也有介绍),有问题可以在此文结尾发表评论与我讨论。
如果用户从bbs登录,则在登录验证成功后通过如下代码:
运行后,查看源代码即可看到javascript;
在discuz的api目录下的uc.php中的函数synlogin,在这里接受uc_server发送过来的“同步登录通知”,并设置discuz的cookie,在这个函数中你可以查看到cookie的加密密钥的“算法”;
$discuz_auth_key= md5($_DCACHE['settings']['authkey'].$_SERVER['HTTP_USER_AGENT']);
通知其它应用----“用户已从bbs登录,请通知其它应用设置cookie”
而且应用id不等于用户当前登录的应用id
一、用户登录检查与用户登录验证logging.php
---------------------------分割线-------------------------------
请看设置cookie的函数_setcookie:
echo "<pre>";var_dump($get);echo "</pre>";die("<hr>api\uc.php");
密钥“算法”:
$ucsynlogin = $allowsynlogin ? uc_user_synlogin($discuz_uid) : '';
Many years ago there lived an Emperor who was so exceedingly fond of fine new clothes that he spent vast sums of money on dress. To him clothes meant more than anything else in the world. He took no interes
related links:


[link widoczny dla zalogowanych]


Post został pochwalony 0 razy
Powrót do góry
Zobacz profil autora
Wyświetl posty z ostatnich:   
Napisz nowy temat   Odpowiedz do tematu    Forum www.public4you.fora.pl Strona Główna -> Questions Wszystkie czasy w strefie EET (Europa)
Strona 1 z 1

 
Skocz do:  
Nie możesz pisać nowych tematów
Nie możesz odpowiadać w tematach
Nie możesz zmieniać swoich postów
Nie możesz usuwać swoich postów
Nie możesz głosować w ankietach


fora.pl - załóż własne forum dyskusyjne za darmo
Powered by phpBB © 2001, 2005 phpBB Group
deoxGreen v1.2 // Theme created by Sopel stylerbb.net & programosy.pl

Regulamin