0

my php code working fine in localhost ...but i have uploaded on server my php administratr login page only validated but not redirect to admin page system browser says error occured ...but other users login page is working fine ...wat can i do >>> wats actually problem ??

Edited by pritaeas: moved

4
Contributors
11
Replies
41
Views
2 Years
Discussion Span
Last Post by jkon
0

browser it shows only "an error occured "

Edited by infoitmanoj

0

Maybe you're ending up in an infinite redirect loop? Have you tried disabling all redirects and see if anything happens?

0

my problem was server admin login validated but cant redirect into admin page ... other login pages are working fine ...but in my localhost admin and all login pages working perfectly ...

0

My PHP Page JS login validation code ..it can be valid "success" and page is redirected in localhost at the sametime it can be valid wrong in server hosting ...

setTimeout(function()
                {
                    var random_pct = 25 + Math.round(Math.random() * 30);

                    // The form data are subbmitted, we can forward the progress to 70%
                    neonLogin.setPercentage(40 + random_pct);

                    // Send data to the server
                    $.ajax({
                        url: baseurl + 'index.php?login/ajax_login',
                        method: 'POST',
                        dataType: 'json',
                        data: {
                            email: $("input#email").val(),
                            password: $("input#password").val(),
                        },
                        error: function()
                        {
                            alert("An error occoured!");
                        },
                        success: function(response)
                        {
                            // Login status [success|invalid]
                            var login_status = response.login_status;

                            // Form is fully completed, we update the percentage
                            neonLogin.setPercentage(100);


                            // We will give some time for the animation to finish, then execute the following procedures    
                            setTimeout(function()
                            {
                                // If login is invalid, we store the 
                                if(login_status == 'invalid')
                                {
                                    $(".login-page").removeClass('logging-in');
                                    neonLogin.resetProgressBar(true);
                                }
                                else
                                if(login_status == 'success')
                                {
                                    // Redirect to login page
                                    setTimeout(function()
                                    {
                                        var redirect_url = baseurl;

                                        if(response.redirect_url && response.redirect_url.length)
                                        {
                                            redirect_url = response.redirect_url;
                                        }

                                        window.location.href = redirect_url;
                                    }, 400);
                                }

                            }, 1000);
                        }
                    });

Edited by infoitmanoj

0

try:
1. logout or logout with http://www.yourdomain.com/wp-login.php?action=logout
2. disable all plugins
3. clear cookies/cache
4. exit browser

just for troubleshooting purposes try:
- switching to the default theme by renaming your current theme's folder in wp-content/themes using FTP or whatever file management application your host provides.

  • resetting the plugins folder by using FTP or whatever file management application your host provides. Sometimes, an apparently inactive plugin can still cause problems.

  • renaming or deleting the .htaccess file after making a backup of this file

0

I also try out disabling all plugins , deleting cookies and restart my browser still wont change anything ...

0

You said -browser it shows only "an error occured " . Of course this is an extremely ambiguous message for everything. Do you mean that the browser alerted that message ?. In your Js you have the same message alerted in Ajax error. Did you tried to output (alert or log) the error itself and not a message that there has been an error ? .

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.