X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (https://forum.x-cart.com/forumdisplay.php?f=20)
-   -   amazon-style tabbed menu for 4.0.x (https://forum.x-cart.com/showthread.php?t=11567)

aaron 01-28-2005 10:45 AM

Very nice.
Thanks alot

Danielle 01-28-2005 11:04 AM

I checked out your site last night and it looked great...

steveparks 01-28-2005 11:09 AM

thanks
 
Hi Danielle

Thanks!

In that case, its worth checking the code, and the CSS have copied across ok into your installation...it doesn't sound like a browser issue.

If you check against my first post in this forum, and make sure that nothings been missed out.

cheers
steve

mpj 02-14-2005 11:22 AM

Steve,

i'm having a slight issue on versoin 4.0.11

tab function work great and it displays the subcategory menu.

however, when i click on a link from the subcategory, the subcategory menu disappears.

also, i'm not sure how to do step # 5

5. Create a new language label through the admin interface.

'lbl_welcome_msg' is for a short welcome message about your store, to be displayed when the user is not within a category. You can have this as an empty string.

i want to do something like this, which i believe is from your code?

http://www.b4umovie.com/films/customer/home.php?cat=381


thanks again for such great work! excellent and clear code.

=D> =D> =D> !

steveparks 02-14-2005 02:28 PM

Updated code
 
Hi mpj

I'm afraid I can't claim any credit for the menu on the site you gave the link to - i think thats all their own work, as it funcctions differently to mine.

I've updated the code on my site, so I'll go and dig it out and update it in my first post above. That keeps the sub menu open when you go down below it - but at the moment only one more level - i'm trying to work out how to make it work however many levels you go down.

To do the step five, log into your admin interface. On the right hand side menu you'll see an option for Languages. click that, then select to edit the language you want.
Then scroll down the screen and you'll see a blank entry near the bottom. In the first box of this blank entry on the left enter 'lbl_welcome_msg', in the second box type some kind of note to rremind you what it is such as 'menu welcome message', and then in the third box enter the text you want to be displayed.
Then click add/submit/save (can't remember what the button says) and you've done it!

watch out for updated code in my first post soon. I'll put a note at the bottom of it when i've updated it.

mpj 02-14-2005 02:34 PM

hi Steve!

I'm trying to implement this code with your script. This would keep the current subcategory listed.

It's not my code, I got it from someone on this forum. Sorry I dont remember the original thread.

HTH.

Thanks for your kind reply.


Code:

{section name=cat_num loop=$categories}
{* Added by Fernando. Show first level of subcategories *}
{if $current_category ne "" }
  {section name=subcat loop=$allcategories}
{assign var=topmostcat value=$allcategories[subcat].categoryid_path|regex_replace:"/\/.*/":""}
{assign var=current_category_top value=$current_category.categoryid_path|regex_replace:"/\/.*/":""}
    {if $current_category_top eq $topmostcat and $categories[cat_num].categoryid eq $topmostcat and $allcategories[subcat].parentid eq $topmostcat and $allcategories[subcat].categoryid ne $current_category_top}
      {$allcategories[subcat].category|truncate:20:"...":true}

    {/if}
  {/section}
 {/if}
{* End added by Fernando *}


{/section}


steveparks 02-14-2005 02:46 PM

update done
 
Hi Mpj

I've now updated the code in my first post.

Thanks for posting that bit of code. I'll have a play with it.

Steve

mpj 02-14-2005 03:01 PM

code works like a charm on 4.0.11

many many thanks for a great code and programmer!

=D> =D> =D>

mpj 02-15-2005 11:15 AM

one last thing, css related, code works fine ! :)


Here is my CSS. It works fine in Firefox but IE doesn't seem to understand the "height: 20px" atrribute, under "A href " conditions.

My CSS
Code:

.submenuitem, .submenuitem a, .submenuitem a:link, .submenuitem a:visited
{
  font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
  font-size: 0.9em;
  text-transform: lowercase;
  color: #000000;
  height: 20px;



My HTML
Code:

Small Dog


<class="submenuitem">
Big Bird
</class>
-->


While using IE, the CSS woks for "Small Dog" and "Big Bird" but the CSS atribute " height: 20px; " would not show up for "Small Dog".

only " height: 20px;" doesn't show for "Small Dog", other attributes like hover, link, etc. are fine.

Please help.

Thanks

mpj 02-16-2005 10:52 AM

to answer my own question:

" <a>, is an inline element and does not take height or width dimensions. Probably what you want is {line-height: 20px;} "

:D

thanks gary!


All times are GMT -8. The time now is 02:27 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.