Need javascript!!!

Started on the old forum in January 2010 · view the original in the archive · old links redirect here

#javascript

6 replies · 551 views · started 16 years ago · 1 min read

5 participants
riderz Lead · 975 posts #2

its not java its normal php that u can use if u going to use java and im sure its for lava u going to have some ppl not be able to view ur site


Jacques jacques@gw-designs.co.za http://coding.biz.tm Come join and lets make it a place to learn all the noobies how to code


NEVER FORGET TO CLICK THE TANX BUTTON IF U LIKE WHAT IM SHARING OR HELPING WITH

kei_ki7 Senior · 431 posts #3

yeah i think its js, but you can do that with out js but the page loads again, unlike js but not all phones are supported

Did I help you? You can help me too Your donations will help me finance my studies.

GumSlone Administrator Principal · 1,690 posts #6

rap-4ever wrote: pls give me javascript...it looks like this in online list:

rap-4ever+ user+ user+

.when i click on rap-4ever+ i will see

rap-4ever - Where: Forum Home Online Msg: Hello to all

user+

user+

try jquery or mootools, jquery is more popular and has many tutorials with examples on their site.

or just use simple show/hide js code

      <script language="JavaScript">

       function doHideShow(divName){

    	var objDiv = document.getElementById(divName);

    		if(objDiv.style.display == ''){

        		objDiv.style.display = 'none';

    		}

   			else

   			{

        	objDiv.style.display = '';

    		}

		}

		</script>
<a href="javascript:void(0);" onclick="doHideShow('mydiv');">Show/Hide</a>
<div id="mydiv">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</div>

Advertise your mobile site for FREE with AdTwirl

External image (may be gone)

djlee Developer · 224 posts #7
Username <a href="#" onclick="expand(this, 'somediv');">+</a>

<div style="display: none;" id="somediv">
 Some data<br />
 More data <br />
</div>

<script type="text/javascript">
 function expand(hand, cont) {
  var ch = document.getElementById(cont);
  if(ch.style.display='none') {
   ch.style.display='block';
   hand.innerHTML='-';
   }
  else {
   ch.style.display='none';
   hand.innerHTML='+';
   }
  }
</script>

Completely untested, coded it inside the add reply box

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close