OnClick function for tablerow excluding other links

I have a big list of items in a table... if you click the row... it will proceed to the next page... which is what i want... but i also have a icon called "stereo.jpg" which opens a popup... when you click that icon it will open the popup along with proceed to the next page.. i need it just top open the popup.


<tr id="tr3" class="cls" onClick="window.location = '/details.php?file_id=9480293027'" onMouseOver="this.className='clsover'" onMouseOut="this.className='cls'" valign="middle">
<td width="40">
      <a href="/details.php?file_id=9480293027"><img src="/images/download.jpg" border="0"></a>
      <a href="javascript:Start('http://somesite.com/preview.php?file_id=9111480258');"><img src="/images/stereo.jpg" border="0"></a>
</td>
<td><a href="/details.php?file_id=9480293027" class="link1"><b>Crazy B*tch - Buckcherry</b></a></td>
<td width="160">
blahblahb test blahblah
</td>
</tr>
remlabAsked:
Who is Participating?
 
kodiakbearConnect With a Mentor Commented:
Closed, 500 points refunded.
kb
Experts Exchange Moderator
0
 
b0lsc0ttIT ManagerCommented:
remlab,

I'm not 100% sure this will work in your case but the easiest way to would be to add a return false at the end of the event in the anchor tag.  You would need to change the tag some to do it.  Try the code below ...

<tr id="tr3" class="cls" onClick="window.location = '/details.php?file_id=9480293027'" onMouseOver="this.className='clsover'" onMouseOut="this.className='cls'" valign="middle">
<td width="40">
     <a href="/details.php?file_id=9480293027"><img src="/images/download.jpg" border="0"></a>
     <a href="#" onclick="Start('http://somesite.com/preview.php?file_id=9111480258'); return false;"><img src="/images/stereo.jpg" border="0"></a>
</td>
<td><a href="/details.php?file_id=9480293027" class="link1"><b>Crazy B*tch - Buckcherry</b></a></td>
<td width="160">
blahblahb test blahblah
</td>
</tr>

Let me know if that doesn't work.  Let me know if you have any questions or need more information.

b0lsc0tt
0
 
remlabAuthor Commented:
nope didnt work b0lsc0tt. same result popup and next page :(
0
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

 
remlabAuthor Commented:
figureed it out on my own... i moved the mouse onclick to the <td> tags instead of using the table. please close question.
0
 
b0lsc0ttIT ManagerCommented:
I'm glad to hear it.  You can post a message (no points required) in the Community Support topic area to have the moderators take care of this.  Make sure you include the URL of this question and let them know what you want.  I don't object and you should be able to get the points refunded.  Let me know if you have any questions.

bol
0
 
b0lsc0ttIT ManagerCommented:
By the way, your other open question (http:Q_22086354.html) isn't allowed.  Sorry!  I understand what you are trying to do but us experts can even get in trouble for replying.  Please delete it on your own.  You should be able to as long as noone responds.

If you want to change it you can ask for recommendation on how to find a CSS coder for pay.  You will need to leave your email address out of the message though.  That isn't allowed either.

One note, if there is an expert you have found very helpful you can click on the their name to view their profile and look to see if they have contact info there.  Some will even have info on hiring them.

Let me know if you have any questions.

bol
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.