Forum Replies Created

Viewing 4 replies - 16 through 19 (of 19 total)
  • mcbuzz

    (@mcbuzz)

    First of all, whooami, you really rock. Thank you for all your help on this site.

    Second, I had the same problem cited above. Exactly the same warning. Just different line numbers, so I could not get to the WP login page.

    Here is what the first four lines of functions.php looked like:

    <?php
    
    function mysql2date($dateformatstring, $mysqlstring, $translate = true) {
    	global $wp_locale;

    I removed the one blank line at line two, so now it looks like:

    <?php
    function mysql2date($dateformatstring, $mysqlstring, $translate = true) {
    	global $wp_locale;

    Uploaded the modified functions.php and the problem was fixed!

    But my question is, Why?

    Because the original functions.php that came with this WordPress 2.3 installation has that blank line in it.

    Thanks again!
    Mark M.

    Minor point, but looks like it is not possible to change the permalink for the page you designate as your static home / front page.

    Forum: Fixing WordPress
    In reply to: Multiple Sidebars

    Just an update:

    It’s not necessary to edit the general-template.php file.

    Just replace

    <?php get_header(); ?>

    with

    <?php include(TEMPLATEPATH."/whatever-header-file-you-want.php"); ?>

    and be sure to save the whatever-header-file-you-want.php file in the theme folder with all the other theme files, including the original header.php file.

    You can do the same with sidebar files.

    Just replace

    <?php get_sidebar(); ?>

    with

    <?php include(TEMPLATEPATH."/whatever-sidebar-file-you-want.php"); ?>

    and be sure to save the whatever-sidebar-file-you-want.php file in the theme folder with all the other theme files, including the original sidebar.php file.

    Forum: Fixing WordPress
    In reply to: Multiple Sidebars

    Editing the general-template.php file (in the wp-includes folder) — replacing get_sidebar with the code offered by jabecker — worked great for me. Thanks jabecker!!

    I noticed that the line
    do_action( 'get_sidebar' );
    is missing from what they offer. Not sure if this matters but I put it in and the function works as described.

    So you should have

    function get_sidebar($sidebar="sidebar") {
    	do_action( 'get_sidebar' );
    	if ( file_exists( TEMPLATEPATH . '/' . $sidebar . '.php') )
    		load_template( TEMPLATEPATH . '/'. $sidebar . '.php');
    	else
    		load_template( ABSPATH . 'wp-content/themes/default/sidebar.php');
    }

    This modification can do a lot of good work (I think) because you can do the same for get_header().

Viewing 4 replies - 16 through 19 (of 19 total)