• Resolved Sasan

    (@sasy360)


    Hi guys. i just developed a simple theme for my blog. when using my theme i stuck logged in and cannot logout. i know there is an issue with my functions.php cause i get warnings form this file in apache log. if i delete my cookies then i cannot login.
    here is my functions.php: (took it from Twenty Ten!)

    <?php add_action( 'after_setup_theme', 'myown_setup');
    
    function myown_setup() {
    	register_nav_menu('primary', 'Navigation Under the header' );
    }
    
    // Register widgetized areas
    function myowntheme_widgets() {
    	// Area 1, located at the top of the sidebar.
    	register_sidebar( array (
    		'name' => 'Primary Widget Area',
    		'id' => 'primary_widget_area',
    		'before_widget' => '<li id="%1$s" class="widget-container %2$s">',
    		'after_widget' => "</li>",
    		'before_title' => '<h3 class="widget-title">',
    		'after_title' => '</h3>',
    	) );
    
    	// Area 2, located below the Primary Widget Area in the sidebar. Empty by default.
    	register_sidebar( array (
    		'name' => 'Secondary Widget Area',
    		'id' => 'secondary_widget_area',
    		'before_widget' => '<li id="%1$s" class="widget-container %2$s">',
    		'after_widget' => "</li>",
    		'before_title' => '<h3 class="widget-title">',
    		'after_title' => '</h3>',
    	) );
    } // end myowntheme_widgets_init
    add_action( 'widgets_init', 'myowntheme_widgets' ); ?>

    cheers and happy holidays!

Viewing 1 replies (of 1 total)
  • Thread Starter Sasan

    (@sasy360)

    yeah, find the solution. it was because of closing functions.php with ?> and a whitespace after it!

Viewing 1 replies (of 1 total)

The topic ‘functions.php thing problem. cannot logout’ is closed to new replies.