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 3 of 3
  1. #1
    Regular Coder sonny's Avatar
    Join Date
    Apr 2008
    Location
    United States
    Posts
    567
    Thanks
    88
    Thanked 0 Times in 0 Posts

    dynamic time from $variable

    Hi I am trying to take static time from a variable "$uct" and make
    it live, with counting of minutes seconds etc,

    PHP Code:
    $uct date("h:ia"time()-GetUserOffset());// displays user logged in current time 
    I found a lot of javascript, one in particular, but it offsets itself by
    manually entering the minutes, I would like to insert my variable containing
    the user offset shown above, and I guess I could leave that js setting at 0,

    But instead of using the default server time I'd like to use my $variable
    anyone know how I can do this by editing localtime in the code below I get
    syntax errors trying,

    this is what I would like to use:
    Code:
    <script type="text/javascript">
    new showLocalTime("timecontainer", "server-php", 0, "short")
    </script>
    the javascript itself is located below
    http://www.dynamicdrive.com/dynamicindex6/localtime.htm
    I don't know if I should post that whole code here

    Thanks
    Sonny
    Last edited by sonny; 08-24-2010 at 01:21 AM.

  • #2
    Regular Coder
    Join Date
    Aug 2010
    Posts
    974
    Thanks
    19
    Thanked 212 Times in 210 Posts
    sorry
    Last edited by DaveyErwin; 08-29-2010 at 06:09 PM.

  • #3
    Regular Coder
    Join Date
    Aug 2010
    Posts
    974
    Thanks
    19
    Thanked 212 Times in 210 Posts
    sorry


  •  

    Posting Permissions

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