Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

"Dynamenu" for osCommerce


Recommended Posts

Just wanted to say that all the examples I've seen are really wonderful looking. Thanks to fellow forum posters for pitching in and helping, as for whatever reason I can't get this dang forum to send me subscription notifications :(

Just a quick tip - if your submenus aren't working or look funny, 9 times out of ten it is because you are not outputting your Dynamenu "footer" in your template(s), or you forgot to include the DM stylesheet in your osCommerce styles...

 

I've pretty much given up on the hope that someone here would be able to help with the problem of dysfunctional flyouts with second vertical menu on same page (no flyout or flying out in wrong place), as described in my posts above. If perchance you're checking back, Nate, and you have any advice, I'd be very interested, as I'm still working with a second menu with no submenus, since my previous efforts to figure out and solve the problem have gone nowhere. I don't see how the stylesheet code would be relevant, and the dmfooter is obviously being outputted, since the menus do work to some extent - categories menu totally functional under current set-up, second menu as 1-level series of links.

 

I still hope to sit down with the problem again some day and figure something out. For me it's lots of trial and error hacking of code I don't fully understand or in some cases hardly understand at all. Could you (or anyone) possibly point to a more likely starting point?

 

If you're not receiving notifications from here, it may be a result of gray-listing or some other problem with your ISP. If you have a second e-mail address at a different ISP or web host, you might try using it instead. I have a friend on sbcglobal.net who can't receive e-mails through my web host server - not even a bounce back, they just disappear in the void. I instead e-mail him through my ISP. I've seen similar problems with different aspects of different e-mailers - different kinds of e-mail breakdowns with Yahoo, Hotmail, AOL, and so on.

Link to comment
Share on other sites

I've pretty much given up on the hope that someone here would be able to help with the problem of dysfunctional flyouts with second vertical menu on same page (no flyout or flying out in wrong place), as described in my posts above.

A live address is more helpful in diagnosing but a misaligned submenu is often the result of the DM footer not being output *just before* the closing body tag. However, you say that you are attempting to do two menus on a page, which is possible as the original Dynamenu (for Postnuke) allows for *multiple* menus on the page without them interfering with each other. It may be you are not including the libraries correctly or something like that.

 

While I designed the osC DM specifically for categories, it should still be possible... see post #65 of this thread for more info... Make sure the menus are "named" differently, etc... Perhaps look at the original Dm for Postnuke for some ideas?

 

If you're not receiving notifications from here, it may be a result of gray-listing or some other problem with your ISP. If you have a second e-mail address at a different ISP or web host, you might try using it instead. I have a friend on sbcglobal.net who can't receive e-mails through my web host server - not even a bounce back, they just disappear in the void. I instead e-mail him through my ISP. I've seen similar problems with different aspects of different e-mailers - different kinds of e-mail breakdowns with Yahoo, Hotmail, AOL, and so on.

Thanks, I have tried my own server which I have intimate knowledge of, and my ISP mail @ comcast.net with no luck (and I have the subscribe option on)... Might look at it again on this rainy afternoon.

 

As for *your* server... you want to make sure it has a proper PTR (reverse DNS) record and the the server is identifying itself correctly (via HELO) with a fully qualified domain name as servers which don't do either will get bounced (or ignored)

** Please do not PM with personal support requests (even if offering "payment"). Thank you.

Link to comment
Share on other sites

A live address is more helpful in diagnosing but a misaligned submenu is often the result of the DM footer not being output *just before* the closing body tag. However, you say that you are attempting to do two menus on a page, which is possible as the original Dynamenu (for Postnuke) allows for *multiple* menus on the page without them interfering with each other. It may be you are not including the libraries correctly or something like that.

 

While I designed the osC DM specifically for categories, it should still be possible... see post #65 of this thread for more info... Make sure the menus are "named" differently, etc... Perhaps look at the original Dm for Postnuke for some ideas?

 

Thanks for the reply - if you page back a bit, you'll see my discussions of what I've tried - beginning with my first effort at a stripped-down install, continuing with various other experiments, including illustrative screen captures.

 

Though the method I'm working with right now is only one of various that succeeded within the limitations I describe (no flyout on second vertical menu), and not necessarily the cleanest, I've left it as is pending a serious effort to fix the problem. I have looked athrough the PostNuke stuff and also at the developer documentation, which it least got me as far as putting up the second menu and using a text file to provide links, but which nowhere provided a precise example I could work from.

 

I have re-named the second menu, and have tried various experiments involving the libraries and alternate naming conventions.

 

You can view what I've done at CK MacLeod Collectibles at ckmac.com. Moved from the prior "catalog" directory to "root" in preparation for our opening any minute now. Home page has the menus centrally located, subsequent pages (still being last-min designed) will have the second menu in right or left column.

 

Thanks in advance - and thanks again for the original contribution: if I didn't like this menu A LOT, I wouldn't be working with it at 75% effectiveness.

 

Colin

 

(By the way, on the off-chance you're interested in this kind of thing I'm selling, I'm very favorable to giving discounts to developers whose contributions I've used. I hope it's not improper to making the offer here. And feel free to e-mail me directly.)

Link to comment
Share on other sites

I can't see any secondary submenus on that page... Essentially in the Postnuke version of DM, when multiple menus are being output on the same page, the initial call to output the JS function headers (after the includes, etc...), has to have the information for *all* flyout/dropdown menus that are going to be output on that page so it can build the show/hide submenu functions to include all the named submenus. Duplicating the script would not work as there would be conflicts with function names, etc... And of course the "footers" for those menus should be dumped to the same GLOBAL var so they can all be output at once (again, just *before* the closing BODY tag)... This version of DM was not specifically designed for that use, but having a look at the Postnuke version of DM may help you adapt it.

 

Well, I hope that gets you on your way, at any rate.... Good luck!

 

...And yes, it's somewhat inappropriate to solicit goods on this site (though it is intriguing merchandise) - one of the forum mods didn't even want me putting my homepage URL inc posts, even though all I have is open source stuff there and don't actually solicit any services - or maybe I just caught one of the more "power-hungry" mods on a bad day ;))

 

P.S. Clever use of the "manufacturers" feature to filter by genre!

** Please do not PM with personal support requests (even if offering "payment"). Thank you.

Link to comment
Share on other sites

I can't see any secondary submenus on that page... Essentially in the Postnuke version of DM, when multiple menus are being output on the same page, the initial call to output the JS function headers (after the includes, etc...), has to have the information for *all* flyout/dropdown menus that are going to be output on that page so it can build the show/hide submenu functions to include all the named submenus. Duplicating the script would not work as there would be conflicts with function names, etc... And of course the "footers" for those menus should be dumped to the same GLOBAL var so they can all be output at once (again, just *before* the closing BODY tag)... This version of DM was not specifically designed for that use, but having a look at the Postnuke version of DM may help you adapt it.

 

Hmmmm... I guess I'll look again for examples that I might be able to adapt. I take it though that it SHOULD be quite within the capabilities of the code with RELATIVELY minor adjustments.

 

I'm not sure what you're seeing or not seeing or expecting to see when you go to the home page. I use a mostly unmodified version of dm_categories to create the regular categories menu, then just enough code to put up the second menu (lower right quadrant) for the "links menu." Yes, it has no submenus at present, as I've intentionally set it up without submenus, since the various attempts to combine the two vertical menus on the same page was either preventing flyouts or more typically causing the submenus to fly out in the wrong place. If it's a clue to you at all, the links menu's flyouts were appearing where they would have appeared if they had been part of the initial menu - as shown in the post at

 

http://www.oscommerce.com/forums/index.php?s=&...mp;p=931181

 

Anyway, I'll see if I can dig something more up - obviously I was hoping that you could say "Oh, just re-name x as y, and paste z here and it'll work just fine," but it looks like something I'll have to leave to future days, weeks, or months.

Link to comment
Share on other sites

Hello!

 

I've implemented Dynamenu into my osC store without issue and it works great!

 

I have been working hard to figure out how to make a unique change though, without luck.

 

I'd like to implement some unique links, i.e. we'll say that I have 3 root categories called "Flowers", "Beans", "Seeds". "Flowers" has sub-categories called "red", "purple", "yellow".

 

Beans and Seeds also have some sub-categories.

 

Currently the Dynamenu would properly link to each appropriate path with HTML generated by osC. What I would like to do is have a few unique links such that, for example,

 

the main root Category "Beans" points to a pre-defined URL such as "http://www.beans.com" instead of the category page.

 

I would also like to be able to have some sub-categories such as "red" point to a pre-defined URL such as "http://www.redflowers.com" instead of the sub-category page.

 

The easiest way I can see doing this is implementing an "if" statement within dm_categories.php for each cPath such that if cPatch 29 is detected, make the URL http://www.beans.com and if cPath 30_33 is deteched, make the URL http://www.redflowers.com.

 

Thanks a ton in advance if you can help me out, let me know!

Link to comment
Share on other sites

This is a great contrib, thank you!

 

I had a small issue though. It works fine with my force cookies enable set to false (admin->configuration->forced cookies use->false), but when I set it to True (turning on force cookies) it looks as though it disables the DM Menu altogether and it defaults back to the standard osCommerce menu style. Any solution to this problem?

Link to comment
Share on other sites

I would also like to be able to have some sub-categories such as "red" point to a pre-defined URL such as "http://www.redflowers.com" instead of the sub-category page. The easiest way I can see doing this is implementing an "if" statement within dm_categories.php for each cPath such that if cPatch 29 is detected, make the URL http://www.beans.com and if cPath 30_33 is deteched, make the URL http://www.redflowers.com.

That's the idea! You want something in the while loop, where it will reassign the URL of a given category. If you had a "lot" of them to do, you could get fancy and make an array with the keys being the category paths and the values being the URL you want to send them to ($myarray). Then, the if conditional could be something like:

if (array_key_exists($cPath_new, $myarray) {
// reset URL to $myarray[$cPath_new]
}

If you wanted to be *really* fancy, you can target external links to new windows, or open in a frame :)

 

This is a great contrib, thank you!

 

I had a small issue though. It works fine with my force cookies enable set to false (admin->configuration->forced cookies use->false), but when I set it to True (turning on force cookies) it looks as though it disables the DM Menu altogether and it defaults back to the standard osCommerce menu style. Any solution to this problem?

You're welcome... I'm sorry, I don't what that could be.. I tried the same thing myself and did not have that effect(?) DM does not use cookies AFAIA... I don't know that you'd want to force cookies, ideally, if that helps ;)

** Please do not PM with personal support requests (even if offering "payment"). Thank you.

Link to comment
Share on other sites

Well, nothing worth doing is easy :) Check out my response to jimmygreaves back on post #65 of this thread...

 

Well, since all I needed was one drop down I was able to utilize the SuckerFish code - looked much easier than trying to revamp this entire project for one dropdown in a separate menu :thumbsup:

 

I LOVE it for the category menu though - Great Job!!!! :thumbsup:

 

Tracy

~Tracy
 

Link to comment
Share on other sites

Is there any way to keep the style of horizitem while hovering the horizsubmenu?

Yes, you should be able to make those types of style adjustments by the stylesheet..

 

It tried my best but can't make it...

 

Please an example ;)

?,???`???,?? God must love stupid people, he made so many ??,???`???,?

Link to comment
Share on other sites

Yes, you should be able to make those types of style adjustments by the stylesheet..

 

It tried my best but can't make it...

 

Please an example ;)

 

Make sure you only have the styles listed for the horizontal menu on your stylesheet. If you still have problems, paste your stylesheet here for us to see and we might be able to help you better :)

 

Tracy

~Tracy
 

Link to comment
Share on other sites

Make sure you only have the styles listed for the horizontal menu on your stylesheet. If you still have problems, paste your stylesheet here for us to see and we might be able to help you better :)

 

Tracy

 

 

Hi

 

I have only styles for hors. menu in my stylesheet

 

Here is a screenshot of what I mean ;)

dynamenu.jpg

 

Adam

?,???`???,?? God must love stupid people, he made so many ??,???`???,?

Link to comment
Share on other sites

I hate to sound like an idiot, but could you be a bit more specific as to what to add and where?

The where would be where the menu is built (build_branch function where $output is being assigned), the what I would leave up to you, but you should be able to get the idea from looking at the code, assuming you know some remedial PHP...

 

Here is a screenshot of what I mean ;)

After thinking about it, I did come to figure out what you meant... I don't think you could do that type of thing exclusively with stylesheets but would rather have to devise something using Javascript (maybe changing the style of the "root" menu using JS)...

** Please do not PM with personal support requests (even if offering "payment"). Thank you.

Link to comment
Share on other sites

Thanks a ton, here's a pretty IF statement to do it...

 

$output .= str_repeat(".", $level+$lvl_adjust).'|'.$divide_subcats_text.'||'.$this_title.'|'.$menu_icon_file.'|'.$this_selected.'|'.$this_expanded."\n";

 

$this_subcat_count = 1;

$lvl_adjust ++;

}

if($cPath_new == "cPath=29") {

$this_title .= ".php";

$output .= str_repeat(".", $level+$lvl_adjust).'|'.$val.'|'.tep_href_link($this_title).'|'.$this_title.'|'.$menu_icon_file.'|'.$this_selected.'|'.$this_expanded."\n";

} else {

$output .= str_repeat(".", $level+$lvl_adjust).'|'.$val.'|'.tep_href_link(FILENAME_DEFAULT, $cPath_new).'|'.$this_title.'|'.$menu_icon_file.'|'.$this_selected.'|'.$this_expanded."\n";

}

Link to comment
Share on other sites

Thanks a ton, here's a pretty IF statement to do it...

Not bad... I would have gone a slighly different way, creating a $linkvar and assigning the link portion of the $output to "blah" if a match or to the usual tep-link... if not, and then stick that var in output... A good programming practice is DRY - "Don't Repeat Yourself" ;-)

 

Hi i am trying to create a fly out menu however it doesn't seems to be working I have followed all the instructions, it seems to be showing all the subcategories down the bottom for some reason.

There does not seem to be a DM on that site, but to help you, I'll repeat myself from before...

Just a quick tip - if your submenus aren't working or look funny, 9 times out of ten it is because you are not outputting your Dynamenu "footer" in your template(s), or you forgot to include the DM stylesheet in your osCommerce styles...

** Please do not PM with personal support requests (even if offering "payment"). Thank you.

Link to comment
Share on other sites

After thinking about it, I did come to figure out what you meant... I don't think you could do that type of thing exclusively with stylesheets but would rather have to devise something using Javascript (maybe changing the style of the "root" menu using JS)...

 

A little light/example please :)

?,???`???,?? God must love stupid people, he made so many ??,???`???,?

Link to comment
Share on other sites

A little light/example please :)

Umm.. that is the example... use JS to maniupulate the DOM somehow... you'll have to use your own skills to figure out the rest...

** Please do not PM with personal support requests (even if offering "payment"). Thank you.

Link to comment
Share on other sites

Umm.. that is the example... use JS to maniupulate the DOM somehow... you'll have to use your own skills to figure out the rest...

 

Thanks alot for your help nate, I tried, but my skills with js is not that high yet :sweating:

Is anyone in the house who can solve this, please B)

Edited by shaytaan

?,???`???,?? God must love stupid people, he made so many ??,???`???,?

Link to comment
Share on other sites

Hi

 

I have only styles for hors. menu in my stylesheet

 

Here is a screenshot of what I mean ;)

dynamenu.jpg

 

Adam

 

Hmmmm - I think that you would have to use JavaScript to achieve this. I can't think of any stylesheet commands that would do what you need as you are needing the activity on one layer to control the appearance of another layer.

 

Tracy

~Tracy
 

Link to comment
Share on other sites

Hmmmm - I think that you would have to use JavaScript to achieve this. I can't think of any stylesheet commands that would do what you need as you are needing the activity on one layer to control the appearance of another layer.

 

Tracy

 

Oops - didn't read down to the replies before writing this reply - sorry guys :blush:

 

Shaytaan - you might check htmlgoodies.com to see if they have any javascript tutorials for what you are looking for. Maybe do a search for JavaScript +tutorial +drop down menu effects

 

Tracy

~Tracy
 

Link to comment
Share on other sites

Thanks alot for your help nate, I tried, but my skills with js is not that high yet :sweating:

Is anyone in the house who can solve this, please B)

Tracy's right about this (though they're not "layers" strictly speaking)... It's probably something I could figure out *eventually*, but I'll let you take that journey... The key would be in manipulating the DOM (specifically the class assignment of the "parent" menu item) in the JS when hovering over the submenu to assign it a different style... 'Fraid that's all I've got...

** Please do not PM with personal support requests (even if offering "payment"). Thank you.

Link to comment
Share on other sites

P.S. shaytaan - the opening JS of DM generates a couple variables which might be helpful - father_keys, father_vals which might be helpful... (they match the submenus with the parent)

** Please do not PM with personal support requests (even if offering "payment"). Thank you.

Link to comment
Share on other sites

  • 2 weeks later...

Quick question for you guys - have any of you found a fix for the way the menu loads in IE 6 ? When it first loads it seems to have the text for the menu moved up and left of where the menu actually is. When you place your mouse on or near where the menu actually is the text then corrects itself and goes where it is supposed to be.

 

Every time you go to a new page - the text always starts out above and to the left of where it should be??

 

I have only tested in FireFox 1.5 and IE 6 so far - but having the prob. be in IE is a fairly big issue since most visitors are using that stinkin' browser <_<

 

If any of you have any ideas, or have figured out how to correct this, I'd be very thankful! :D

~Tracy
 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...