views:

26

answers:

1

Can someone try this and see if it works for you. I can't figure out the problem.. Maybe I have a conflict somewhere. Using jquery.

Thank you so much for the help.

  <script type="text/javascript">
  $(document).ready(function(){
  $('a').mouseover(function() {
  switch ($(this).attr('class')) {
  case 'nc1':
    new_content = 'Twitter';
    break;

  case 'nc2':
    new_content = 'Facebook';
    break;

  case 'nc3':
    new_content = 'Linked In';
    break;

  case 'nc4':
    new_content = 'Flickr';
    break;
  case 'nc5':
    new_content = 'RSS Feed';
    break;

  case 'cs1':
    new_content = 'Email';
    break;
  case 'cs2':
    new_content = 'Telephone';
    break;

  case 'cs3':
    new_content = 'Live Chat';
    break;

  case 'cs4':
    new_content = 'Skype';
    break;

  case 'cs5':
    new_content = 'Google Voice';
    break;

  default:
    new_content = 'The crusade to feed every orphan in the world';
    break;
  }

  $('#ms').html(new_content)
  }).mouseout(function() {
  $('#ms').text('The crusade to feed every orphan in the world');
  });});
  </script>




  <div id="ms">The crusade to feed every orphan in the world.</div>

  <div id="nc_wrap2">
  <a class="nc1" href="#"></a>
  <a class="nc2" href="#"></a>
  <a class="nc3" href="#"></a>
  <a class="nc4" href="#"></a>
  <a class="nc5" href="#"></a>
  </div>
+1  A: 

Works just fine if you put some content in your links ...

example at http://www.jsfiddle.net/x4Lm4/

Gaby
I discovered a conflict with: $(document).ready(function(){ $.preloadCssImages();});
Erik
@Erik, the code in your comment does not appear in the code in the question.. I assume your styles were sized in css and had image backgrounds ?
Gaby