Respond to this message
Original Message
  • Re: D'oh! I just did it myself...
    • (Login blackkats4)
      Posted Feb 8, 2005 10:55 AM

      I use a bit different code for that and have had no problems. some of my posters are overseas and they tell me that the greeting is in their time zone.

      here is the code i have been using for about 2 years.

      you can change the color and font about half way down.

      You will notice that mine is set fot the cookies function in the first part..
      Instead of the greplace function

      <!--
      function ReadCookie(cookieName){
      var theCookie=""+document.cookie;
      var ind=theCookie.indexOf(cookieName);
      if (ind==-1 || cookieName=="") return "";
      var ind1=theCookie.indexOf(';',ind);
      if (ind1==-1) ind1=theCookie.length;
      return unescape(theCookie.substring(ind+cookieName.length+1,ind1));
      }
      var today = new Date();
      expiry = new Date(today.getTime() + 6*60*24*60*60*1000);
      function SetCookie (name, value){
      document.cookie=name + "=" + escape (value) + "; expires=" + expiry.toGMTString();
      }
      // -->
      </script></div>

      <center><font face="Helvetica,Arial" size="2" color="#FF00ff"><b>
      <script>
      <!--
      datetoday = new Date();
      timenow=datetoday.getTime();
      datetoday.setTime(timenow);
      thehour = datetoday.getHours();
      if (thehour > 18) displayEvent = "Evening";
      else if (thehour >12) displayEvent = "Afternoon";
      else displayEvent = "Morning";
      var yourname=ReadCookie("nbabauth")
      if ((yourname=="") || (yourname=="Anonymous")){yourname="Guest"}
      var greeting = ("Good " + displayEvent + " " + yourname + "")
      document.write("<b>"+greeting+"</b>");
      // -->
      </script>


      Kitty, KD, Blackkats4, Cindy
      East Texas, 50 miles north of Houston
      Ducks and Geese
    Login Status
  • You are not logged in
    • Login
      Password
       

      Optional
      Provides additional benefits such as notifications, signatures, and user authentication.


      Create Account
    Your Name
    Your Email
    (Optional)
    Message Title
    Message Text
    Image Services Photobucket.com
    Options Enable formatted text (Huh?)
    Also send responses to my email address
          


    Find more forums on Personal Web PagesCreate your own forum at Network54
     Copyright © 1999-2010 Network54. All rights reserved.   Terms of Use   Privacy Statement