Reputation: 38190
I have an asp button with no onclick event but only onclientclick. This call a javascript function in a iframe in which a video is playing;
each time I click the javascript function is called but also the video restart which means the page is reloaded.
How to prevent this ?
Upvotes: 1
Views: 3572
Reputation: 16505
return false from your onclientclick.
OnClientClick="LoadVideo();return false;"
Upvotes: 7