Thanx, that helped. I adapted ist to my needs. Dieter
-----Urspr�ngliche Nachricht----- Von: David Worms [mailto:david@;simpledesign.com] Gesendet: Samstag, 9. November 2002 23:06 An: Turbine Users List Betreff: Re: Trigger action from Listbox That should help. When the user select an item from the select box, he will be redirect to the url present as a value in the select > option tag. David <script> function MM_jumpMenu(targ,selObj,restore){ eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); if (restore) selObj.selectedIndex=0; } <script> <select name="select" onChange="MM_jumpMenu('parent',this,0)"> #set ( $baseLink = $link.setAction('modules.ManageModule').addPathInfo('eventSubmit_doChang ecurrentmodule', '' ) ) <option value="$baseLink.addPathInfo('moduleId', '-1')">select module</option> #foreach ($module in $data.user.modules) #set ( $baseLink = $link.setAction('modules.ManageModule').addPathInfo('eventSubmit_doChang ecurrentmodule', '' ) ) #if ( $module == $data.user.currentModule ) #set ( $selected = "selected" ) #else #set ( $selected = "" ) #end <option value="$baseLink.addPathInfo('moduleId', $!module.ModuleId)" $selected >$module.Name </option> #end #end </select> On Saturday, November 9, 2002, at 01:45 PM, Dieter Engelhardt wrote: > Hi there, > this question might be simple to you guys. > > I have a screen where i provide a listbox to select a certain item > where i > have to rebuild this screen after the item is selected. > My question is, what do i have to do in the onchage section of the > select > tag. > Here is my velecity-macro: > > #macro( Listbox $list $item $actiontemplate) > #formLabel("Description") > <td bgcolor="$ui.formLabelColor"> > <SELECT name="Name" > > onchange="javascript:location.replace($link.setPage($actiontemplate)"> > <option value="">$item</option> > #foreach( $entry in $list ) > <option > value=$entry.getValue("lnd_id")>$entry.getValue("lnd_bezeichnung")</ > option> > #end > </select> > </td> > #end > > Thanks for your help! > > Dieter > > > -- > To unsubscribe, e-mail: > <mailto:turbine-user-unsubscribe@;jakarta.apache.org> > For additional commands, e-mail: > <mailto:turbine-user-help@;jakarta.apache.org> > -- To unsubscribe, e-mail: <mailto:turbine-user-unsubscribe@;jakarta.apache.org> For additional commands, e-mail: <mailto:turbine-user-help@;jakarta.apache.org> -- To unsubscribe, e-mail: <mailto:turbine-user-unsubscribe@;jakarta.apache.org> For additional commands, e-mail: <mailto:turbine-user-help@;jakarta.apache.org>
