close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Dynamic Drop Downs & Templates

Thread began 3/12/2013 2:16 am by Codesnap | Last modified 3/13/2013 9:46 pm by Jason Byrnes | 668 views | 5 replies |

Codesnap

Dynamic Drop Downs & Templates

Trying to load up a dynamic drop down on page load. Works fine if I put it into the body tag of a test page, but doesn't when adding it as JS before closing the body. Avoiding using it as onLoad in the body because I know I'm converting this to a template.

For example ...

<body onLoad="WA_setSelectionsInChildList(MM_findObj('parent'),'J6A84a3XrVK1'); WA_FilterAndPopulateSubList(childList_WAJA,MM_findObj('parent'),MM_findObj('child'),1,0,false,': '); WA_setSelectionsInChildList(MM_findObj('child'),'t0fGN8wbKvx4');">

... works a treat, but ...

<script language="text/javascript">
WA_setSelectionsInChildList(MM_findObj('parent'),'J6A84a3XrVK1');
WA_FilterAndPopulateSubList(childList_WAJA,MM_findObj('parent'),MM_findObj('child'),1,0,false,': ');
WA_setSelectionsInChildList(MM_findObj('child'),'t0fGN8wbKvx4');
</script>

... just before </body> doesn't want to do the same thing.

What have I done wrong?

Sign in to reply to this post

Jason ByrnesWebAssist

that should work, please send a link where i can see the problem to troubleshoot the cause.

Sign in to reply to this post

Codesnap

Attached. Not sure what else you'd need. I've put in a basic switch to turn the body onLoad on and off. Change it to 1 == 1 and it works as expected. It's the JS version that doesn't want to work.

Sign in to reply to this post

Jason ByrnesWebAssist

please provide a link to the page so i can see it in the browser.

i need to see the problem in the browser in order to troubleshoot. As i don't have your database, i cant recreate it on my system.

Sign in to reply to this post

Codesnap

Here it is working ... test_onload_a.php

And here it is, not working ... test_onload_b.php

Sign in to reply to this post

Jason ByrnesWebAssist

in the script tag, use the type attribute instead of the language attribute.


change:
<script language="text/javascript">


to:
<script type="text/javascript">

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...