Hi all

I've been looking around for a script which would allow me to show text on a page next to a title when the title is clicked. I've happened upon this code which places text below each title.

The problem is that the text appears below each individual title and I am looking to create an effect where each link makes a paragraph of text appear in the same space by the text (so that only one paragraph of text is visable at one time, depending on which link is clicked)

I'd be gratefull for any suggestions anyone has!

my current code is below but I'm not sure if this is a dead end and I'll need to take another approach

<script language="javascript">
function toggleDiv(id)
   var div = document.getElementById(id);
   var current = div.style.display;
   if (current == 'none')
      div.style.display = 'block';
      div.style.display = 'none';
if (current == 'none')
      div.style.display = 'block1';
      div.style.display = 'none';

<a href="javascript:toggleDiv('block');">Toggle Block</a>
        <a href="javascript:toggleDiv('block1');">Toggle Block</a>
                <div id="block" style="display: none">This is my Block</div>
                <div id="block1" style="display: none">This is my Block</div>
thanks in advance