Arindam Das Arindam Das - 9 months ago 68
Javascript Question

Why <td> onclick event not firing in

I have a

, clicking on that I want display a

here's my code:

<td id="tdmord" style="padding-left: 15px; color: #86A7C5; padding-right: 15px; font family: Arial;
font-size: small;" onclick="return showdiv1()">
My Orders

and here's the JavaScript:

function showdiv1 {
return false;

the problem is the
is not clickable and I can't click on it.

Answer Source

your showdiv1 is missing this ()

define showdiv1() like this:

<script type="text/javascript">
   function showdiv1()   {
       return false; 

also Id that your function showdiv1 is using is wrong. correct that!!!