Changeset 1947 for trunk/wp-includes/functions.php
- Timestamp:
- 12/14/2004 03:00:55 AM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/functions.php
r1940 r1947 1955 1955 } 1956 1956 1957 if ( !function_exists('wp_login') ) : 1957 1958 function wp_login($username, $password, $already_md5 = false) { 1958 1959 global $wpdb, $error; … … 1983 1984 } 1984 1985 } 1986 endif; 1987 1988 if ( !function_exists('auth_redirect') ) : 1989 function auth_redirect() { 1990 // Checks if a user is logged in, if not redirects them to the login page 1991 if ( (!empty($_COOKIE['wordpressuser_' . COOKIEHASH]) && 1992 !wp_login($_COOKIE['wordpressuser_' . COOKIEHASH], $_COOKIE['wordpresspass_' . COOKIEHASH], true)) || 1993 (empty($_COOKIE['wordpressuser_' . COOKIEHASH])) ) { 1994 header('Expires: Wed, 5 Jun 1979 23:41:00 GMT'); // Michel's birthday 1995 header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); 1996 header('Cache-Control: no-cache, must-revalidate'); 1997 header('Pragma: no-cache'); 1998 1999 header('Location: ' . get_settings('siteurl') . '/wp-login.php?redirect_to=' . urlencode($_SERVER['REQUEST_URI'])); 2000 exit(); 2001 } 2002 } 2003 endif; 1985 2004 1986 2005 function is_plugin_page() {
Note: See TracChangeset
for help on using the changeset viewer.