gkazhus Posted November 25, 2013 Report Posted November 25, 2013 if ( !in_array($GLOBALS['pagenow'], array('wp-login.php', 'wp-register.php' )) && !is_admin() && !is_user_logged_in() ) { wp_redirect('/wp-login.php', 301); exit; } Vai kaads luudzu var pateikt kur sheit man ir kluuda, jo atverot wp-register.php lapu ta tiek automatiski parmesta uz wp-login.php lapu lai gan esmu tacu pielicis, ka taa netiek redirektota. Ka es varu to izlabot? Quote
marrtins Posted November 26, 2013 Report Posted November 26, 2013 Neizpildās kāds no nosacījumiem. print (int)!in_array($GLOBALS['pagenow'], array('wp-login.php', 'wp-register.php' )); print (int)!is_admin(); print (int)!is_user_logged_in(); Quote
edw Posted November 26, 2013 Report Posted November 26, 2013 (edited) $GLOBALS['pagenow'] vietā es lietotu wp funkciju get_current_screen(); http://codex.wordpress.org/Function_Reference/get_current_screen Un vēl, man šķiet, ka tevi redirecto htaccess fails. Edited November 26, 2013 by edw Quote
martins256 Posted November 26, 2013 Report Posted November 26, 2013 Nesaprotu kā autors to pats nevarēja saprast. Quote
aaxc Posted November 26, 2013 Report Posted November 26, 2013 Gadās, ka pats uz kautkādu stulbu sīkumu uzķeries, jo meklē problēmu pavisam kur citur. Quote
daGrevis Posted November 26, 2013 Report Posted November 26, 2013 Pirmo postē jautājumu kkur, ir vērts padomāt, vai izklāstīt to nebūs ilgāk kā tomēr pašam pacensties un atrisināt. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.