SitePoint Sponsor

User Tag List

Results 1 to 8 of 8
  1. #1
    SitePoint Enthusiast
    Join Date
    Mar 2011
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Where did my admin login page go??

    I've been working on a wordpress site, and the last thing I was working on was adding a custom post type. Everything was working yesterday before I left it, and now when I go to my site, there is no admin login page. The rest of the site is still there in the same shape it was(albeit not good), but when i type in the url for the admin page(www.mcquistonator.com/cbc/wp-admin, it returns just a blank page.

    Some other notes that may or may not be helpful.

    I had added the custom post type and was successful in that it showed up in my Admin section under Posts, with All Posts and Add New as sub-menu items. As far as the admin side went, all seemed to work just fine, but when I clicked on view page, i would get a 404 page.

    Here is the code i added to my functions.php to add the post type below. I had messed around with a couple times adding the last 'rewrite' => array('slug' => 'products') parameter to try to solve the 404 problem as it seemed that whatever the problem was somehow had to do with a mismatch between actual location of the post and the url my admin was generating. Admittedly i was shooting in the dark trying to solve this problem, but now I am REALLY shooting in the dark as i have no admin panel and all i have is my FTP application.

    <?php

    add_action( 'init', 'create_post_type' );

    function create_post_type() {

    register_post_type( 'CBC_Examples',

    array(

    'labels' => array(

    'name' => __( 'Examples' ),

    'singular_name' => __( 'Example' )

    ),

    'supports' => array('title', 'editor', 'custom-fields'),



    'public' => true,

    'has_archive' => true,

    'rewrite' => array('slug' => 'products'),

    )

    );

    }

    ?>

  2. #2
    Gre aus'm Pott gold trophysilver trophybronze trophy
    Pullo's Avatar
    Join Date
    Jun 2007
    Location
    Germany
    Posts
    5,858
    Mentioned
    206 Post(s)
    Tagged
    12 Thread(s)
    Hi,
    This might or might not help, but I had exactly the same thing happen to me lately (albeit on a local install).
    My problem turned out to be a missing .htaccess file in my site's root folder (no idea what happened to it).
    Can you verify yours is there and it hasn't been corrupted in any way?

    Let me know how you get on, as there are a couple of obvious things you can check if this doesn't work.

  3. #3
    Gre aus'm Pott gold trophysilver trophybronze trophy
    Pullo's Avatar
    Join Date
    Jun 2007
    Location
    Germany
    Posts
    5,858
    Mentioned
    206 Post(s)
    Tagged
    12 Thread(s)
    Oh yeah, in the code you provide, you're missing a bracket and you have one comma two many.
    Maybe this is causing an error and PHP is failing silently before it ever gets to display your admin panel.
    Do you have error logging turned on?
    If not, this will tell you how: http://digwp.com/2009/07/monitor-php-errors-wordpress/

  4. #4
    SitePoint Enthusiast
    Join Date
    Mar 2011
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for the reply Pullo. I don't see where I'm missing a bracked, but i did remove the last comma. I went to my error_log file, and this is what is said each time I typed in the URL and it tried to render the page:
    [03-Nov-2012 07:48:03] PHP Warning: Cannot modify header information - headers already sent by (output started at /home7/mcquist1/public_html/cbc/wp-content/themes/notes-blog-core-theme/functions.php:50) in /home7/mcquist1/public_html/cbc/wp-content/plugins/wordpress-seo/inc/class-sitemaps.php on line 512

    I'm not totally sure what this means.. Any advice?

    Quote Originally Posted by Pullo View Post
    Oh yeah, in the code you provide, you're missing a bracket and you have one comma two many.
    Maybe this is causing an error and PHP is failing silently before it ever gets to display your admin panel.
    Do you have error logging turned on?
    If not, this will tell you how: http://digwp.com/2009/07/monitor-php-errors-wordpress/

  5. #5
    Gre aus'm Pott gold trophysilver trophybronze trophy
    Pullo's Avatar
    Join Date
    Jun 2007
    Location
    Germany
    Posts
    5,858
    Mentioned
    206 Post(s)
    Tagged
    12 Thread(s)
    Hi,

    Let's try disabling the wordpress-seo plugin then, as that seems to be causing the trouble.
    To do this, FTP into your site, find your plugin folder and rename the folder containing the wordpress-seo plugin.
    Then head back to www.mcquistonator.com/cbc/wp-admin and refresh the page.
    Does that help?

    Off Topic:

    Quote Originally Posted by Pullo View Post
    Oh yeah, in the code you provide, you're missing a bracket and you have one comma two many.
    That should be: one comma too many.

  6. #6
    SitePoint Enthusiast
    Join Date
    Mar 2011
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Pullo,

    I appreciate your advice. However, I did change the name of the plugin folder as you suggested. It stopped the error that is showing up in the log, however, it did not solve the larger issue. I did notice that in the error log, this particular error did not start showing up until the same day as my other problem, so whatever it is I did triggered both issues. I had that SEO plugin for quite some time, and I did not make any changes that I know of pertaining specifically to the plugin. I did not change any settings of options with respect to the SEO plugin. All i can think of is that something i put into the functions file(all there is is the code at the start of this thread) has triggered this. It's a little bit frustrating.

  7. #7
    SitePoint Enthusiast
    Join Date
    Mar 2011
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Can I change the selected theme from my child theme to my parent theme by editing the files manually? I am not sure if the problem is within my theme or something that would affect the site as a whole, but if it isn't too hard, i would give it a try.

  8. #8
    Gre aus'm Pott gold trophysilver trophybronze trophy
    Pullo's Avatar
    Join Date
    Jun 2007
    Location
    Germany
    Posts
    5,858
    Mentioned
    206 Post(s)
    Tagged
    12 Thread(s)
    Quote Originally Posted by josh mcq View Post
    Can I change the selected theme from my child theme to my parent theme by editing the files manually?
    Yeah, of course, a theme is nothing more than a collection of PHP files.
    Just remove the child theme folder from /wp-content/themes/ and WP should (hopefully) default to the parent theme.
    BTW, when I say remove, don't delete anything, just pull it off your server, but keep a copy locally.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •