Jump to content
php.lv forumi

onclick


anonīms

Recommended Posts

function showFriends(p1,p2){
 $('#'+p1).show();
 $('#'+p2).hide();
}

 

<div class="tab2"><a href="java script:void(0);" onclick="showFriends('visitors','friends');" class="current">Visitors</a></div>
<div class="tab2"><a href="java script:void(0);" onclick="showFriends('friends','visitors');">Friends</a></div>

 

<div style='text-align:left; padding-left: 3px;' id="friends">friends</div>
<div style='text-align:left; padding-left: 3px;display: none;' id="visitors">visitors</div>

 

Kapēc nekas nenotiek?

Spiežot uz linka nekas nemainas.

Link to comment
Share on other sites

×
×
  • Create New...