Changeset 1073921
- Timestamp:
- 01/23/2015 07:36:44 AM (11 years ago)
- File:
-
- 1 edited
-
mqtranslate/trunk/mqtranslate_core.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
mqtranslate/trunk/mqtranslate_core.php
r1073919 r1073921 117 117 function qtrans_set_language_cookie($lang, $cookie_path) 118 118 { 119 global $q_config; 120 119 121 if (defined('WP_ADMIN')) { 120 122 $cookie_name = QT_COOKIE_NAME_ADMIN; 121 123 $cookie_path = trailingslashit($cookie_path).'wp-admin'; 124 $cookie_secure = false; 122 125 } 123 126 else { 127 if (!empty($q_config['disable_client_cookies'])) 128 return; 129 124 130 $cookie_name = QT_COOKIE_NAME_FRONT; 125 131 if (strlen($cookie_path) > 1) 126 132 $cookie_path = untrailingslashit($cookie_path); 127 } 128 setcookie(QT_COOKIE_NAME, $lang, time()+86400*365, $cookie_path); 133 $cookie_secure = !empty($q_config['use_secure_cookie']); 134 } 135 setcookie($cookie_name, $lang, time()+86400*365, $cookie_path, NULL, $cookie_secure); 129 136 } 130 137
Note: See TracChangeset
for help on using the changeset viewer.