WordPress.org

Ready to get started?Download WordPress

Forums

Site title missing (11 posts)

  1. ohpinkybrain
    Member
    Posted 4 years ago #

    i was recoding twenty ten theme and i accidentally deleted the site title codes! now i don't know which code i deleted because instead of appearing my site title's name...it appears as mozilla firefox eventhough i typed the name in the dashboard general settings..still doesn't appear..

    does anyone know what are the codes for site title so i can just paste it back!

    thanks!

  2. Christopher Spires
    Member
    Posted 4 years ago #

    This is the default <title> code for Twenty Ten:

    <title><?php
    	/*
    	 * Print the <title> tag based on what is being viewed.
    	 */
    	global $page, $paged;
    
    	wp_title( '|', true, 'right' );
    
    	// Add the blog name.
    	bloginfo( 'name' );
    
    	// Add the blog description for the home/front page.
    	$site_description = get_bloginfo( 'description', 'display' );
    	if ( $site_description && ( is_home() || is_front_page() ) )
    		echo " | $site_description";
    
    	// Add a page number if necessary:
    	if ( $paged >= 2 || $page >= 2 )
    		echo ' | ' . sprintf( __( 'Page %s', 'twentyten' ), max( $paged, $page ) );
    
    	?></title>
  3. ohpinkybrain
    Member
    Posted 4 years ago #

    hi again boda..

    those codes are still visible in my header.php

    unfortunately, the site title doesnt appear either. if you visit http://www.blog.shoppilicious.com/ you will notice the site title is mozilla firefox..

    thanks again..

  4. Christopher Spires
    Member
    Posted 4 years ago #

    Throw your header up on Pastebin, and link it.

  5. chinmoy29
    Member
    Posted 4 years ago #

    @ohpinkybrain

    GOTO SETTINGS->GENERAL in ADMIN and set the all settings. there site title is blank.

  6. ohpinkybrain
    Member
    Posted 4 years ago #

    hi boda82..

    header.php>> http://pastebin.com/hFYJvVKh

    theres nothing missing..

    style.css>> http://pastebin.com/XQUsrWBN

    i think i might have deleted something in style.css!
    i didnt touch the functions or index...

    thanks.

  7. chinmoy29
    Member
    Posted 4 years ago #

    remove this

    <title><?php
    	/*
    	 * Print the <title> tag based on what is being viewed.
    	 */
    	global $page, $paged;
    
    	wp_title( '|', true, 'right' );
    
    	// Add the blog name.
    	bloginfo( 'name' );
    
    	// Add the blog description for the home/front page.
    	$site_description = get_bloginfo( 'description', 'display' );
    	if ( $site_description && ( is_home() || is_front_page() ) )
    		echo " | $site_description";
    
    	// Add a page number if necessary:
    	if ( $paged >= 2 || $page >= 2 )
    		echo ' | ' . sprintf( __( 'Page %s', 'twentyten' ), max( $paged, $page ) );
    
    	?></title>

    Once.

    And try this <title><?php wp_title( '|', true, 'right' );?></title>

  8. Christopher Spires
    Member
    Posted 4 years ago #

    First glance looks correct. Are you running any caching plugins? If so, clear out the cache (or disable it completely for testing).

  9. ohpinkybrain
    Member
    Posted 4 years ago #

    hi boda.. tested it. still doesnt work :(

  10. Christopher Spires
    Member
    Posted 4 years ago #

    Backup your header.php, remove all the code between the title tags, and simply put "Shoppilicious". Does it still not display the title?

    (FYI: I suggest you disable that caching mod, as well as clear your browsers cache while you're testing this stuff. Once everything's working you can turn it back on.)

  11. jamo649
    Member
    Posted 3 years ago #

    I had the same problem and found the solution.
    Under Appearance>Editor select the theme to edit: I had two similar themes listed in the drop-down menu: mysite & Mysite>mysite
    I selected Mysite>mysite from the dropdown and edited the header.php file replacing the title with this:

    <title><?php
    	/*
    	 * Print the <title> tag based on what is being viewed.
    	 */
    	global $page, $paged;
    
    	wp_title( '|', true, 'right' );
    
    	// Add the blog name.
    	bloginfo( 'name' );
    
    	// Add the blog description for the home/front page.
    	$site_description = get_bloginfo( 'description', 'display' );
    	if ( $site_description && ( is_home() || is_front_page() ) )
    		echo " | $site_description";
    
    	// Add a page number if necessary:
    	if ( $paged >= 2 || $page >= 2 )
    		echo ' | ' . sprintf( __( 'Page %s' ), max( $paged, $page ) );
    
    	?></title>

    It worked a treat. Hope this helps.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.