Weller0123
asked on
Client side button....
When I changed the attributes for an input button from:
<input id="btnLOV" onclick="showLOV();" type="button" value="Lookup" name="btnLOV">
To: (to show an image instead of a button)
<input id="btnLOV" onclick="showLOV();" type="image" src="images/Look.gif" name="btnLOV">
The page is now posting back.
Is there anyway to use an image as a clientside button (that will not cause a postback)?
Thanks,
<input id="btnLOV" onclick="showLOV();" type="button" value="Lookup" name="btnLOV">
To: (to show an image instead of a button)
<input id="btnLOV" onclick="showLOV();" type="image" src="images/Look.gif" name="btnLOV">
The page is now posting back.
Is there anyway to use an image as a clientside button (that will not cause a postback)?
Thanks,
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
This gets the onclick event to fire but still posts back...
I think I can do an html image onclick...
I think I can do an html image onclick...
ASKER
This works in IE...
I don't think it will work in other browsers. I only need it for IE though...
<img src="images/Look.gif" id="btnLOV" onclick="showLOV();">
I don't think it will work in other browsers. I only need it for IE though...
<img src="images/Look.gif" id="btnLOV" onclick="showLOV();">
btnLOV.Attributes.Add("onc
where you use the button:
<asp:imagebutton runat="server" ImageUrl="..images/Look.gi
The server will generate the JavaScript dynamically when it sends the aspx page to the client.