Kristabs Posted November 24, 2006 Report Share Posted November 24, 2006 Sveiki! Situācija: <table> <tr> <td onClick="do_this();"><input type="checkbox" name="cheks" /></td> </tr> </table> Kā panākt, lai do_this() neizpildās, kad lietotājs čeko checkbox? Link to comment Share on other sites More sharing options...
andrisp Posted November 24, 2006 Report Share Posted November 24, 2006 Domāju, ka neizmantojot kaut kādus čerežopa risinājums, to nevar izdarīt. Varbūt ne pa tēmu, bet - http://www.quirksmode.org/js/events_order.html. Link to comment Share on other sites More sharing options...
Kristabs Posted November 24, 2006 Author Report Share Posted November 24, 2006 Atradu atbildi dr.lv js function checkb(v){ check = v; } function do_this(){ if(check == '1'){ //dariit } } html <table> <tr> <td onClick="do_this();"><input type="checkbox" name="cheks" onClick="checkb('0')" onMouseOut="checkb('1');" /></td> </tr> </table> Link to comment Share on other sites More sharing options...
Recommended Posts