### Eclipse Workspace Patch 1.0
#P glotpress
|
|
|
|
| 226 | 226 | // So, make all local variables, global |
| 227 | 227 | gp_set_globals( get_defined_vars() ); |
| 228 | 228 | |
| | 229 | /** |
| | 230 | * It is possible to define this in wp-config.php and it will be used as the domain for all cookies. |
| | 231 | * Set it carefully for sharing cookies amonst subdomains |
| | 232 | * |
| | 233 | * @link http://curl.haxx.se/rfc/cookie_spec.html |
| | 234 | */ |
| | 235 | if ( !defined('GP_COOKIE_DOMAIN') ) |
| | 236 | define('GP_COOKIE_DOMAIN', false); |
| | 237 | |
| 229 | 238 | if ( !class_exists( 'WP_Auth' ) ) { |
| 230 | 239 | require_once( BACKPRESS_PATH . 'class.wp-auth.php' ); |
| 231 | 240 | $cookies = array(); |
| 232 | 241 | $cookies['auth'][] = array( |
| 233 | | 'domain' => isset($_SERVER['HTTP_HOST'])? $_SERVER['HTTP_HOST'] : '' , |
| | 242 | 'domain' => GP_COOKIE_DOMAIN, |
| 234 | 243 | 'path' => gp_url_path(), |
| 235 | 244 | 'name' => gp_const_get( 'GP_AUTH_COOKIE', 'glotpress_auth' ), |
| 236 | 245 | ); |
| 237 | 246 | $cookies['secure_auth'][] = array( |
| 238 | | 'domain' => isset($_SERVER['HTTP_HOST'])? $_SERVER['HTTP_HOST'] : '' , |
| | 247 | 'domain' => GP_COOKIE_DOMAIN, |
| 239 | 248 | 'path' => gp_url_path(), |
| 240 | 249 | 'name' => gp_const_get( 'GP_SECURE_AUTH_COOKIE', 'glotpress_sec_auth' ), |
| 241 | 250 | 'secure' => 'true', |
| 242 | 251 | ); |
| 243 | 252 | |
| 244 | 253 | $cookies['logged_in'][] = array( |
| 245 | | 'domain' => isset($_SERVER['HTTP_HOST'])? $_SERVER['HTTP_HOST'] : '' , |
| | 254 | 'domain' => GP_COOKIE_DOMAIN, |
| 246 | 255 | 'path' => gp_url_path(), |
| 247 | 256 | 'name' => gp_const_get( 'GP_LOGGED_IN_COOKIE', 'glotpress_logged_in' ), |
| 248 | 257 | ); |