Page 1 of 2 12 LastLast
Results 1 to 10 of 14
  1. #1
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default A list question...

    I've noticed that the navMain links (or account links) contained in the header of Zen Cart are coded in a basic un-ordered list.

    At the moment I've modified the list, to contain a few more items. However, I would like to place one line of text below on of the list items (while keeping it inline), but don't know how!

    Please see the image below. I'm looking for a way to add the text 'example text'.



    Any help would be great! :)

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: A list question...

    you could try this for a linked entry you would have to add the link and this can be the placement of an image/button or?
    I have also made it a div for css styling directly if needed and aligned right with forward
    Code:
    <div id="headerWrapper">
    <!--bof-navigation display-->
    <div id="navMainWrapper">
    <div id="navMain">
        <ul class="back">
        <li><?php echo '<a href="' . HTTP_SERVER . DIR_WS_CATALOG . '">'; ?><?php echo HEADER_TITLE_CATALOG; ?></a></li>
    <?php if ($_SESSION['customer_id']) { ?>
        <li><a href="<?php echo zen_href_link(FILENAME_LOGOFF, '', 'SSL'); ?>"><?php echo HEADER_TITLE_LOGOFF; ?></a></li>
        <li><a href="<?php echo zen_href_link(FILENAME_ACCOUNT, '', 'SSL'); ?>"><?php echo HEADER_TITLE_MY_ACCOUNT; ?></a></li>
    <?php
          } else {
            if (STORE_STATUS == '0') {
    ?>
        <li><a href="<?php echo zen_href_link(FILENAME_LOGIN, '', 'SSL'); ?>"><?php echo HEADER_TITLE_LOGIN; ?></a></li>
    <?php } } ?>
    
    <?php if ($_SESSION['cart']->count_contents() != 0) { ?>
        <li><a href="<?php echo zen_href_link(FILENAME_SHOPPING_CART, '', 'NONSSL'); ?>"><?php echo HEADER_TITLE_CART_CONTENTS; ?></a></li>
        <li><a href="<?php echo zen_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'); ?>"><?php echo HEADER_TITLE_CHECKOUT; ?></a></li>
    <?php }?>
    </ul>
    </div>
    <div id="navMainSearch"><?php require(DIR_WS_MODULES . 'sideboxes/search_header.php'); ?></div>
    <br class="clearBoth" />
    </div>
    <div id="example">
        <ul class="forward">
        <li><?php echo '<a href="some file location link">Example Text';?></a></li>
    </div>
    <br class="clearBoth" />
    </div>
    <!--eof-navigation display-->
    Try it, as I am not excellect in the php area but it should work and not error
    Zen-Venom Get Bitten

  3. #3
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Re: A list question...

    Thanks for the above. :)

    However, I know how to add links and so on, but I'm a little confused as to how I can get the 'example text' to sit directly below 'View Basket'.

    Wouldn't the second list (that you advised me to add) have to be aligned exactly?

  4. #4
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: A list question...

    Kobra's suggestion would work for the case that you posted, with the example text under the rightmost (and right-aligned) element on the row.
    Other situations would require different solutions.

  5. #5
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Re: A list question...

    Kobra it works! :)

    However, I had to change the first </div> to </ul>. So, the final code looked like...

    Code:
    <div id="example">
        <ul class="forward">
        <li><?php echo '<a href="some file location link">Example Text';?></a></li>
    </ul>
    <br class="clearBoth" />
    </div>
    Thanks for the help.

  6. #6
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Re: A list question...

    Ok, so I've got it working and updated my live site.

    www.beyondeuphoria.co.uk (adult content)

    Everything looks fine in IE(7), but not Firefox(2)!

    If you're using Firefox and add something to the basket you'll notice a great big gap between the 'View Basket' link and the actually items/price text.

    This gap is much smaller (and nicer) in IE.

    I've tried playing around with the CSS, but had no luck. Maybe it's a code issue?

  7. #7
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: A list question...

    Alex,

    I can only see the source but this is what turns up:
    Code:
    <!--bof-navigation display-->
    <div id="navMainWrapper">
    <div id="navMain">
        <ul class="forward">
    <!-- bof header navigation - aclarke - 080107 -->
    	
        <li><a href="https://www.beyondeuphoria.co.uk/login.html">Login / Register</a></li>
    	<li><a href="https://www.beyondeuphoria.co.uk/account.html">Your Account</a></li>
    	<li><a href="http://www.beyondeuphoria.co.uk/shopping_cart.html">View Basket</a></li>
    </ul>
    </div>
    
    <div id="navMainSubText">
    <ul class="forward">
    <li><a href="http://www.beyondeuphoria.co.uk/shopping_cart.html">1 items, £7.66</a></li>
    </ul>
    <br class="clearBoth" />
    </div>
    <!-- eof header navigation - aclarke - 080107 -->
    Can you rearrange the code in your tpl_header.php to get closer to this, bringing the price into the same ul list:
    Code:
    <!--bof-navigation display-->
    <div id="navMainWrapper">
    <div id="navMain">
        <ul class="forward">
    <!-- bof header navigation - aclarke - 080107 -->
    	
        <li><a href="https://www.beyondeuphoria.co.uk/login.html">Login / Register</a></li>
    	<li><a href="https://www.beyondeuphoria.co.uk/account.html">Your Account</a></li>
    	<li><a href="http://www.beyondeuphoria.co.uk/shopping_cart.html">View Basket</a></li>
    <li><a href="http://www.beyondeuphoria.co.uk/shopping_cart.html">1 items, £7.66</a></li>
    </ul>
    <br class="clearBoth" />
    </div>
    <!-- eof header navigation - aclarke - 080107 -->
    Zen-Venom Get Bitten

  8. #8
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Re: A list question...

    I'll give it a go. If it doesn't work will it help if I post my source code?

  9. #9
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: A list question...

    Yes, or zip it and provide a DL Link and it can be worked on in full
    Zen-Venom Get Bitten

  10. #10
    Join Date
    Mar 2006
    Posts
    919
    Plugin Contributions
    2

    Default Re: A list question...

    Ok, I've tried the previous code alteration and it hasn't worked.

    I am trying to close the vertical gap/space between the 'View Basket' link and the '1 items, £29.95' text.

    The solution you mentioned just added the '1 items, £29.95' text into the same UL, which displayed it after the 'View Basket' text and not below.

    Hope that makes sense! :S

    Any further ideas?

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. v151 Removing the product list heading. A why question
    By Annie_zaz in forum Customization from the Admin
    Replies: 3
    Last Post: 24 Nov 2013, 11:42 AM
  2. Login Activity list question
    By isolveja in forum General Questions
    Replies: 1
    Last Post: 11 Sep 2013, 02:32 AM
  3. Expanded Category List by Anant Bhatia - question
    By comicart in forum Addon Templates
    Replies: 11
    Last Post: 17 Oct 2012, 02:06 AM
  4. Printable Price List Module Question
    By hudda in forum General Questions
    Replies: 0
    Last Post: 20 Jun 2008, 10:40 AM
  5. Simple question - how do I list...
    By richx in forum General Questions
    Replies: 2
    Last Post: 17 Sep 2006, 03:45 AM

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