I have a jsp page which lists several links on it. When the user clicks a link it fires an event which should set some bean variables based on which link the user selected. However I am new to java and unsure how it will know what link was selected. I tried to pass variables in the onClick event but it just gave me an error (jsp render error). So basically this is what I have:
I set the following values:
String sCategory = Category[iCount];
String sSubCategory = SubCategory[iCount]<i>;
Display the SubCategory as a link (there is an = after onClick but won't let me post with it)
<hbj:link id= "<%=id%>" text = "<%=sSubCategory%>" onClick "ShowArticle"/>
function ShowArticle(Event event)
{
folderBean.setCurrentFolder(sCategory)
folderBean.setCurrentSubFolder(sSubCategory)
mode = 2;
}
So I need to send the sCategory and sSubCategory to the ShowArticle Function in order to set the folders but have no idea how to do this so any help is greatly appreciated.