Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    May 2005
    Posts
    63
    Thanks
    1
    Thanked 0 Times in 0 Posts

    dynamic content code

    does anyone have code for dynamic content that will work in conjunction with my exisiting scripts? i had a script that worked but for some reason it stopped working when i tried to pair it on a link with another one.

    Code:
    <script type="text/javascript">
    //<![CDATA[
    function doStuff(el) {
    
    var links=document.getElementsByTagName("a");
    for(i=0;i<links.length;i++) {
    if(links[i].className=="white") {
       links[i].style.color="#888";
     }
    }
         el.style.color="#BC8F8F";
     }
    //]]>
    </script>
    that was to change the color of the links on each page
    Code:
    <script type="text/javascript">
    <!--
    
    function show_me(id){
    
    document.getElementById("box2").innerHTML=document.getElementById(id).innerHTML
    
    }
    
    //-->
    </script>
    thats my code for dynamic content

    Code:
    <a class="white" href="recommendations.html" target="theframe" onclick="doStuff(this);show_me(quote1)" onfocus="this.blur()">RECOMMENDATIONS&nbsp&nbsp&nbsp&nbsp</a>
    theres the function calls, only the first one works

  • #2
    Senior Coder
    Join Date
    Apr 2003
    Location
    San Francisco, CA
    Posts
    2,469
    Thanks
    0
    Thanked 0 Times in 0 Posts
    This is more suited to the javascript forum, and my javascript is too weak to help out. I'll ask a moderator to move it for you!!
    // Art is what you can get away with. <-- Andy Warhol
    ...:.:::: bradyjfrey.com : htmldog : ::::.:...


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •