Results 1 to 8 of 8
  1. #1
    Join Date
    Jun 2009
    Posts
    85
    Plugin Contributions
    0

    help question How do I write alt="" text for my site Logo Image?

    Hi.

    I am trying to I write alt="" text for my site Logo Image.
    As I understand I should be going it in /includes/languages/english/MyTemplate/header.php

    in this section:
    // added defines for header alt and text
    define('HEADER_ALT_TEXT', 'Powered by Zen Cart :: The Art of E-Commerce');
    define('HEADER_SALES_TEXT', 'TagLine Here');
    define('HEADER_LOGO_WIDTH', '');
    define('HEADER_LOGO_HEIGHT', '');
    define('HEADER_LOGO_IMAGE', 'logo.gif');

    I changed it there uploaded the file and nothing happened...
    Does anyone know what I am doing wrong??

  2. #2
    Join Date
    Oct 2009
    Location
    Netherlands - NB
    Posts
    146
    Plugin Contributions
    0

    Default Re: How do I write alt="" text for my site Logo Image?

    Hi,

    You can change this text in the templates section:

    templates/YOUR_TEMPLATE/

    Here you can change the ALT text of the images html inside the main page and header. (wherever the pic is called)

    I changed this for my main page image in the main page (html includes folder)

    It is not in your language folder

  3. #3
    Join Date
    Jun 2009
    Posts
    85
    Plugin Contributions
    0

    help question Re: How do I write alt="" text for my site Logo Image?

    Hi, thanks for your reply.

    Are you saying I can change it in includes/templates/MyTemplate/common/tpl_header.php??

    I tried to do it in this section
    <!--bof-header logo and navigation display-->

    <div class="indent"><a href="<?php echo zen_href_link(FILENAME_DEFAULT);?>"><?php echo zen_image(DIR_WS_TEMPLATE.'images/
    logo.gif
    '); ?></a><br />
    </div>

    I managed to change image (logo) name, but don't see anywhere where I can input alt="" tag... for the logo

    Or did I not understand you correctly??

    Thanks again.

  4. #4
    Join Date
    Oct 2009
    Location
    Netherlands - NB
    Posts
    146
    Plugin Contributions
    0

    Default Re: How do I write alt="" text for my site Logo Image?

    I made a mistake, the header logo differs from the main page image (which is in the template file).

    The logo alt text is indeed in the language files, like this thread explains:

    http://www.zen-cart.com/forum/showthread.php?t=120619

    This tutorial provides the same information:

    https://www.zen-cart.com/tutorials/i...hp?article=125

  5. #5
    Join Date
    Jun 2009
    Posts
    85
    Plugin Contributions
    0

    help question Re: How do I write alt="" text for my site Logo Image?

    Thanks.

    So it looks like I am back to where I started...
    with the same results...

    I changed it where I supposed to... in /includes/languages/english/MyTemplate/header.php

    in this section:
    // added defines for header alt and text
    define('HEADER_ALT_TEXT', 'Powered by Zen Cart :: The Art of E-Commerce');
    define('HEADER_SALES_TEXT', 'TagLine Here');
    define('HEADER_LOGO_WIDTH', '');
    define('HEADER_LOGO_HEIGHT', '');
    define('HEADER_LOGO_IMAGE', 'logo.gif');

    I uploaded the file and nothing happened...

    I only managed to change image (logo) name in includes/templates/MyTemplate/common/tpl_header.php??

    I did it in this section
    <!--bof-header logo and navigation display-->

    <div class="indent"><a href="<?php echo zen_href_link(FILENAME_DEFAULT);?>"><?php echo zen_image(DIR_WS_TEMPLATE.'images/
    logo.gif'); ?></a><br />
    </div>

    but it did not solve my other problem with alt="" tag...

    Does anyone know what else could be done??

  6. #6
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: How do I write alt="" text for my site Logo Image?

    Your custom template has changed the original code in tpl_header.php, and in so doing they removed the functionality that normally would work if you simply edited the header.php language file as you had mentioned earlier.

    The original code for displaying the logo in tpl_header.php is this:
    Code:
        zen_image($template->get_template_dir(HEADER_LOGO_IMAGE, DIR_WS_TEMPLATE, $current_page_base,'images'). '/' . HEADER_LOGO_IMAGE, HEADER_ALT_TEXT)
    Replace yours with that, and then your changes to the header.php language file will take effect normally.

    Remember: every addon you install may or may not have had original features removed by whoever packaged the addon ... this could be because they didn't want the feature and didn't choose to turn it off via a built-in method, or they wanted to make it work another way. Some addons are built short-sighted simply to meet an immediate need, and others are built for optimal benefit to all who might choose to use them. Your mileage may vary with each. It's a chance you take.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  7. #7
    Join Date
    Jun 2009
    Posts
    85
    Plugin Contributions
    0

    Default Re: How do I write alt="" text for my site Logo Image?

    DrByte, you are my HERO!
    It worked. Thanks :)

  8. #8
    Join Date
    Mar 2010
    Posts
    30
    Plugin Contributions
    0

    Default Re: How do I write alt="" text for my site Logo Image?

    Hi,
    Just wondering what might be wrong when the Alt text for my (non-product) images doesn't show at all, even though the text is defined?
    Thanks.

 

 

Similar Threads

  1. Replies: 3
    Last Post: 12 Mar 2015, 03:13 PM
  2. v151 Unable to Change Alt Text for Site Logo
    By dilbert_freak_420 in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 9 Apr 2014, 07:39 PM
  3. How to turn off " Tell a Friend " and " Write a Review"?
    By awk_grep in forum General Questions
    Replies: 1
    Last Post: 15 Dec 2009, 11:31 PM
  4. how do I remove "x Units in Stock" and "Write a Review"?
    By n_kip in forum General Questions
    Replies: 1
    Last Post: 11 Jun 2008, 05:47 PM
  5. Replace "Call for price" text links with image button, how?
    By torgil in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 7 Sep 2006, 07:37 PM

Posting Permissions

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