Help with javascript and user control -
i have user comtrol image button dynamically entered page. want id in jquery or javascript enlarge image, enlarge last image, code, in advance!
function moveover() { document.getelementbyid('<% = imagebutton1.clientid %>').height = "360"; document.getelementbyid('<% = imagebutton1.clientid %>').width = "200"; } function moveback() { document.getelementbyid('<% = imagebutton1.clientid %>').height = "130"; document.getelementbyid('<% = imagebutton1.clientid %>').width = "100"; }
this page
foreach (datarow p in ds.tables["products"].rows) { asp.product_control_ascx prod = new asp.product_control_ascx(); panel1.controls.add(prod); prod.old_price = p["regular_price"].tostring(); prod.new_price = p["your_price"].tostring(); prod.watch_pic = p["product_imag"].tostring(); prod.rr = "~/productpage.aspx?select_prod=" + p["product_id"].tostring(); ; }
even if has code increases picture nicely?
the best solution problem pass client id of image button function shown below.
function moveover(imagebuttonid) { document.getelementbyid(imagebuttonid).height = "360"; document.getelementbyid(imagebuttonid).width = "200"; }
Comments
Post a Comment