Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Incorporating two languages 1

Status
Not open for further replies.

BdaMick

Programmer
Sep 11, 2007
5
US
How can I put this

Code:
<input name="fAH" type="checkbox" value="" onclick="ToggleFilter(this.checked, ffAH);" />

into this
Code:
...while ( $row_rs_rep = mysql_fetch_array($rs_rep) ) {
	  $repList = $repList.'<li>'.$row_rs_rep['stb_lastname'].'</li>';
}

and make it work?

I'm trying to have a list of rep names that would each have a check box next to their names and on click would run a function. I can't seem to incorporate the two and have it work.
 
You want each list object to contain the checkbox above, and run the JS function when clicked?

----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.
 
Correct. Also, what I didn't show, I want the name="fAH" to be the rep name, so that I can pass that variable to the fucntion.

make sense?

Seems simple, but every version I have tried, the page failed to load at all.
 
Something like this should work:


Code:
$repList = $repList.'<li><input name="'.$row_rs_rep['stb_lastname'].'" type="checkbox" value="" onclick="ToggleFilter(this.checked,'.$row_rs_rep['stb_lastname'].');" /></li>';

----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.
 
Perfect. Thanks so much. I think I must have mixed up my single and double quotes, b/c that was what I was trying to do.
 
Glad I could help.

----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top