WordPress.org

Support

Support » How-To and Troubleshooting » [Resolved] Adding a logo

[Resolved] Adding a logo

Viewing 15 replies - 1 through 15 (of 19 total)
  • Now im getting this error
    Parse error: syntax error, unexpected '}' in /home/thecampi/public_html/wp-content/themes/superstore_camping/header.php on line 114

    please help thanks

    Hi, the variables “TEMPLATEPATH” and get_option(‘home’) are already pointing the browser to the wordpress directory and even more to your template directory so you will start from a different directory then “public_html”. So having ‘public_html’ in the address is leading to a broken link. can you share your site address? Check the codex page and fix the link to the image.
    Regards

    About the second error … you have <? } ?> instead of <?php } ?> at line 114 as the error says.

    how do you know what line it is? im sorry im new at this

    you can copy+paste the code in a text editor that shows the line count like gedit, kompozer, word, libreWriter … edit the code in that one and then copy+paste it back in the wordpress editor.

    <a>/">		<?php art_menu_items(); ?>
    
    </div>
    </div>
    <div class="art-Header">
    <div class="art-Header-jpeg"></div>
    <div class="art-Logo">
    <h1 id="name-text" class="art-Logo-name">
    /"><?php if ( file_exists( TEMPLATEPATH . '/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg' ) ) { ?>
    "><img src="<?php bloginfo('template_url'); ?>/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg" alt="<?php bloginfo('name'); ?>" />
    <?php } else { ?>
    <h1>"><img src="<?php echo get_option('home'); ?>/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg" title="TheCampingCampground." alt="IMAGE TEXT." height="125" width="250"/></h1>
    <?php } ?>
    <div id="slogan-text" class="art-Logo-text">
    <?php bloginfo('description'); ?></div>
    </div>
      <?php } else { ?>
      <h1></a><a>"><img src="<?php echo get_option('home'); ?>/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg" title="TheCampingCampground." alt="IMAGE TEXT." height="125" width="250"/></a></h1>
    <?php } ?></h1>
        <div id="slogan-text" class="art-Logo-text">
            <?php bloginfo('description'); ?></div>
    </div>

    im still getting the same error and my site will not work

    ok fixed the error but now my site looks like this http://www.thecampingcampground.com

    and the code looks like this

    <?php art_menu_items(); ?>
    
    </div>
    </div>
    <div class="art-Header">
    <div class="art-Header-jpeg"></div>
    <div class="art-Logo">
    <h1 id="name-text" class="art-Logo-name">
    /"><?php if ( file_exists( TEMPLATEPATH . '/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg' ) ) { ?>
    "><img src="<?php bloginfo('template_url'); ?>/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg" alt="<?php bloginfo('name'); ?>" />
    <?php } else { ?>
    <h1>"><img src="<?php echo get_option('home'); ?>/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg" title="TheCampingCampground." alt="IMAGE TEXT." height="125" width="250"/></h1>
    <? } ?></h1>
    <div id="slogan-text" class="art-Logo-text">
    <?php bloginfo('description'); ?></div>
    </div>

    thanks for your help

    well you have html errors you can’t use a <h1> tag nested in another <h1> tag so try the fallowing code:

    <?php art_menu_items(); ?>
    </div>
    </div>
    <div class="art-Header">
    <div class="art-Header-jpeg"></div>
    <div class="art-Logo">
    <h1 id="name-text" class="art-Logo-name">
    /"><?php if ( file_exists( TEMPLATEPATH . '/images/camping_logo.jpg' ) ) { ?>
    "><img src="<?php bloginfo('template_url'); ?>/images/camping_logo.jpg" alt="<?php bloginfo('name'); ?>" />
    <?php } else { ?>
    <img src="<?php echo get_option('home'); ?>/wp-content/themes/superstore_camping/images/camping_logo.jpg" title="TheCampingCampground." alt="IMAGE TEXT." height="125" width="250"/></h1>
    <?php } ?></h1>
    <div id="slogan-text" class="art-Logo-text">
    <?php bloginfo('description'); ?></div>
    </div>

    and let’s see the results 🙂

    http://www.thecampingcampground.com

    Ok it looks better now but i still have broken link so i need to put the logo in a different folder right???

    <?php art_menu_items(); ?>
    
    </div>
    </div>
    <div class="art-Header">
    <div class="art-Header-jpeg"></div>
    <div class="art-Logo">
    <h1 id="name-text" class="art-Logo-name">
    <?php if ( file_exists( TEMPLATEPATH . '/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg' ) ) { ?><img src="<?php bloginfo('template_url'); ?>/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg" alt="<?php bloginfo('name'); ?>" />
    <?php } else { ?>
    <h1>"><img src="<?php echo get_option('home'); ?>/public_html/wp-content/themes/superstore_camping/images/camping_logo.jpg" title="TheCampingCampground." alt="IMAGE TEXT." height="125" width="250"/></h1>
    <? } ?></h1>
    <div id="slogan-text" class="art-Logo-text">
    <?php bloginfo('description'); ?></div>
    </div>

    Nope, setting the logo in a different folder is not the solution using the right way to link wordpress to your folders is;
    what code are you running now?
    have you tried my code?
    also … do you really need that

    /”>

    in front of the logo?

    ahh you are a guineas the logo is there but i have /”>”> infront of it also and i dont mean to be a pain can i get the logo into the top left of the header image?

    yes you can, the ” /”>”> ” are there because you missplaced them in the source code … check the code and delete them they are right before <?php art_menu_items(); ?>; after that well check the logo also 😉

    Ok this is the code now but its still doing it am i missing something? im sorry for all this its my fist time with this as you cant tell…

    <div class="art-nav">
    	<div class="l"></div>
    	<div class="r"></div>
    	<div class="art-nav-center">
    	<ul class="art-menu">
    <?php art_menu_items(); ?>
    </div>
    </div>
    <div class="art-Header">
    <div class="art-Header-jpeg"></div>
    <div class="art-Logo">
    <h1 id="name-text" class="art-Logo-name">
    /"><?php if ( file_exists( TEMPLATEPATH . '/images/camping_logo.jpg' ) ) { ?>
    "><img src="<?php bloginfo('template_url'); ?>/images/camping_logo.jpg" alt="<?php bloginfo('name'); ?>" />
    <?php } else { ?>
    <img src="<?php echo get_option('home'); ?>/wp-content/themes/superstore_camping/images/camping_logo.jpg" title="TheCampingCampground." alt="IMAGE TEXT." height="125" width="250"/></h1>
    <?php } ?></h1>
    <div id="slogan-text" class="art-Logo-text">
    <?php bloginfo('description'); ?></div>
    </div>

    ok, check the code and delete the characters you have:

    <div class="art-nav">
    <div class="l"></div>
    <div class="r"></div>
    <div class="art-nav-center">
    <ul class="art-menu">
    <?php art_menu_items(); ?>
    </div>
    </div>
    <div class="art-Header">
    <div class="art-Header-jpeg"></div>
    <div class="art-Logo">
    <h1 id="name-text" class="art-Logo-name">
    /"><?php if ( file_exists( TEMPLATEPATH . '/images/camping_logo.jpg' ) ) { ?>
    "><img src="<?php bloginfo('template_url'); ?>/images/camping_logo.jpg" alt="<?php bloginfo('name'); ?>" />
    <?php } else { ?>
    <img src="<?php echo get_option('home'); ?>/wp-content/themes/superstore_camping/images/camping_logo.jpg" title="TheCampingCampground." alt="IMAGE TEXT." height="125" width="250"/></h1>
    <?php } ?></h1>
    <div id="slogan-text" class="art-Logo-text">
    <?php bloginfo('description'); ?></div>
    </div>

    and in a closer look:

    <div class="art-Logo">
    <h1 id="name-text" class="art-Logo-name">
    /"><?php if ( file_exists( TEMPLATEPATH . '/images/camping_logo.jpg' ) ) { ?>
    "><img src="<?php bloginfo('template_url'); ?>/images/camping_logo.jpg" alt="<?php bloginfo('name'); ?>" />

    as you can see the 3rd row starts with /"> that ends nothing so delete it; also the 4th row starts with "> that again ends nothing … so let’s delete this also.

    ok cool thats worked thanks

    so how can i move the logo to top right is this possible or am i just going to mess things up again… Thanks for all of this

Viewing 15 replies - 1 through 15 (of 19 total)
  • The topic ‘[Resolved] Adding a logo’ is closed to new replies.
Skip to toolbar