adding javascript nav bar adding javascript nav bar
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

adding javascript nav bar

Started by Walkinman, February 02, 2006, 08:28:19 AM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Walkinman

Hello Folks,

I've recently added a new navigation bar to my site, with pop up menus, but I don't know how to incorporate that into the template for Coppermine. You cansee an example of what I have here:

http://www.skolaiimages.com/portfolio/index.html

if you look at the "stock" pages, you'll see the older nav bar, which doesn't include all the pop up menus.

http://www.skolaiimages.com/stock/index.php

That's the start of my Coppermine driven dynamic pages. Can anyone offer how any idea on how I can add that nav bar to the Coppermine template, and if it's possible? Ideally, I'd like to be able to copy it over, and not have to redo construct the whole thing in the Template, largely to make updates easier in the future. If this is possible, I'd really appreciate any help.

Thank you.

Cheers

Carl

Joachim Müller

What do you have issues with? Why can't you add this menu to your coppermine template? I can't see what should be wrong with it. You will of course have to change the relative paths, as coppermine is nested one level deeper in your folder structure.
Not sure if it will work out of the box, but it should be something along the lines as the template file I attached.

Walkinman

Hey GauGau,

Thank you for your help. I'm sorry, I should have articulated more carefully the problem I'm having. I created a Template in Dreamweaver for the site, and then just inserted what I need for each page. It worked fine for each static page. And if I want to add to the popup menus, I can just do so on the Template, and it automatically adjusts the apges for the rest of the site. But when I tried to do that with the Coppermine Template, I ran into problems. An error pops up saying:

While executing inspect Behavior in Show Pop-Ip Menu.htm, the following Javascript error(s) occurred:

At line 492 of file "MacintoshHD:Applications:macromedia Dreamweaver 8: Configuration:Behaviors:Actions:Show Pop-up Menu.js":
TypeError: T.update is not a function"


I tried building the nav bar again from scratch, and it works fine on my HD, but the uploaded version doesn't display the drop downs. I have no idea what the different is. It worked when I used a trial template name (template_trial.html), but when I resaved it as template.html, the uploaded version wouldn't work. As I said, it works fine on my HD, in Firefox, Safari, Netscape, even IE.


I'll attach the template as a text file if you could offer some more help, it'd be great.

As I was writing this, another though occurred tome, and I tried it .. I uploaded the js menu into the "coppermine" directory, instead of the water-_drop theme, which is where DW wrote it. All seems to be working fine just now. You can mark this thread "solved" if you'd like.

Thank you.

Joachim Müller

you mustn't use a WYSIWYG editor to edit coppermine files. Paste the code that has been generated by Dreamweaver into your coppermine template.

Walkinman

hey GauGau,

Thank you. Is there a conflict, or is it an issue of copyright stuff with altering Coppermine code? So far, everything seems to be working OK, but if it's a copyright thing, I'll be glad to go back and redo the changes in a text editor. Either way, I'll be sure to make future changes in a text editor.

Thank you.

Cheers

Carl

Joachim Müller

not a copyright issue, from a legal point of view you can use whatever editor you like (from our point of view), but WYSIWYG editors are notorious to "fix" relative paths they're not suppossed to fix for the template. Many of them (excluding Dreamweaver, but including MS Frontpage) can't cope with embedded php, and nearly all of them try to "beautify" the code unnecessarily. Well, after all you can use Dreamweaver if you know your way around in configuring the editor in the first place - it's a good editor after all (MS Frontpage definitely isn't though imo). Dreamweaver has a plain text mode as well afaik.
Another option is to edit the template using Dreamweaver and then (after successfully adding your dynamic menu) making sure (using a plain text editor) that all mandatory coppermine stuff (especially the tokens in curly brackets) are in place.

Joachim Müller

looking at your page once more I realized that you accomplished having the dynamic menu on your coppermine pages. It's considered as a nice gesture to resolve the threads you started, please do so in the future ::).

Marking thread as "solved"

Walkinman

hey GauGau,

Thanks for the input on using DW, etc. that's helpful. I didn't know if DW changed somethings in the top of the code or anything that would repalce some Coppermine notice or anything.

Regarding marking the thread as solved, how do I do that? I thought only moderators could do that? I did post 2 posts above that the problem was solved and could be marked as such -- I just didn't know that was something I could do. Is that the case?

Thanks again.

Cheers

Carl

Joachim Müller

You're right, marking threads is something only moderators are capable of. I must have overlooked that you posted your issue was solved, sorry. Please ignore my previous complaint.

Walkinman

Hey GauGau,

No problem. Do I get my Karma back? :)

Thank you.

Cheers

Carl

Paver

Heh.  This thread made me smile.  Thanks to both of you for that.