0477 function BS_set_cookie($name,$value,$lifetime = COOKIE_LIFETIME)
0478 {
0479 global $CFG,$INPUT;
0480 $INPUT->set_var(COOKIE_PREFIX.$name,'cookie',$value);
0481 setcookie(COOKIE_PREFIX.$name,$value,time() + $lifetime,
0482 $CFG['cookie_path'],$CFG['cookie_domain']);
0483 }
0484
0485 /**
0486 * deletes the cookie with given name
0487 *
0488 * @param string $name the name of the cookie (without COOKIE_PREFIX)