Sorry, I added the list after sending the previous code. (Actually, I don't care if I have a list of the stylenames or not; I just want to get one of the style name values from the query into each of the onClick events.) The format of the list is defaulted to commas.
Here's the code with the CF list.
<cfquery name="q_menu" datasource="mchfaq">
SELECT * from qa_menu
order by menu_sortText
</cfquery>
<cfoutput>
<cfset bmarklinkList = #ValueList(q_menu.menu_bmarkLink)#>
<script language="_javascript_" type="text/_javascript_">
<!--
function targetid(){
return #bmarklinkList#;
}
-->
</script>
</cfoutput>
<ul>
<cfoutput query="q_menu">
<li><A HREF="" q_menu.menu_nonBmarkLink neq "">"#q_menu.menu_nonBmarkLink#"><cfelse>"##Ans"
</a></li>
</cfoutput>
</ul>
Basically, if the href value is an external URL, ignore the rest of the if statement. If the href value is a bookmark link, have the href go to a specific position on the page, (#Ans), and using CSS display the previously hidden content of the style names in the onClick.
I've substituted style name values where the js goes, like so:
<li><A HREF="" q_menu.menu_nonBmarkLink neq""> "#q_menu.menu_nonBmarkLink#"><cfelse>"##Ans"
</a> </li>
<li><A HREF="" q_menu.menu_nonBmarkLink neq"">"#q_menu.menu_nonBmarkLink#"><cfelse>"##Ans"
</a> </li>
<li><A HREF="" q_menu.menu_nonBmarkLink neq"">"#q_menu.menu_nonBmarkLink#">< cfelse>"##Ans"
</li>
Thanks.
Joy
>where do you want to loop thru the style name?
>
>1) when creating the html/js with CF/
>
>2) when the user initiates the js onClick?
>
>if 1) above, where & what format is the list of styles?
>
>Dick
>
>
>
>On Apr 13, 2004, at 9:23 AM, Joy Holman wrote:
>
>>
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

