Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8967323
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T17:13:02+00:00 2026-06-15T17:13:02+00:00

http://www.juriseodesign.com/clock/Sydney.php My clock count javascript shows errors. I have my background changes working, but

  • 0

http://www.juriseodesign.com/clock/Sydney.php

My clock count javascript shows errors. I have my background changes working, but after adding the count clock javascript, the clock doesn’t work. I guess it is caused by “collisions” with Mootools and regular jQuery, but I don’t have any idea how to fix it. Could anybody can help this for me? Also, how to connect to other paged when I click the one of the city in the dropdown menu?

Thank you so much!

// JavaScript Document

//initial time
var h_current = -1;
var m1_current = -1;
var m2_current = -1;
var s1_current = -1;
var s2_current= -1;


function flip (upperId, lowerId, changeNumber, pathUpper, pathLower){
    var upperBackId = upperId+"Back";
    $(upperId).src = $(upperBackId).src;
    $(upperId).setStyle("height", "64px");

Uncaught TypeError: Object # has no method ‘setStyle’ (repeated 315 times)
$(upperId).setStyle(“visibility”, “visible”);
$(upperBackId).src = pathUpper+parseInt(changeNumber)+”.png”;

    $(lowerId).src = pathLower+parseInt(changeNumber)+".png";
    $(lowerId).setStyle("height", "0px");
    $(lowerId).setStyle("visibility", "visible");

    var flipUpper = new Fx.Tween(upperId, {duration: 200, transition: Fx.Transitions.Sine.easeInOut});
    flipUpper.addEvents({
        'complete': function(){
            var flipLower = new Fx.Tween(lowerId, {duration: 200, transition: Fx.Transitions.Sine.easeInOut});
                flipLower.addEvents({
                    'complete': function(){ 
                        lowerBackId = lowerId+"Back";
                        $(lowerBackId).src = $(lowerId).src;
                        $(lowerId).setStyle("visibility", "hidden");
                        $(upperId).setStyle("visibility", "hidden");
                    }               });                 
                flipLower.start('height', 64);

        }
                        });
    flipUpper.start('height', 0);


}//flip


function retroClock(){

    // get new time
     now = new Date();
     h = now.getHours();
     m1 = now.getMinutes() / 10;
     m2 = now.getMinutes() % 10;
     s1 = now.getSeconds() / 10;
     s2 = now.getSeconds() % 10;
     if(h < 12)
        ap = "AM";
     else{ 
        if( h == 12 )
            ap = "PM";
        else{
            ap = "PM";
            h -= 12; }
     }

     //change pads

     if( h != h_current){
        flip('hoursUp', 'hoursDown', h, 'Single/Up/'+ap+'/', 'Single/Down/'+ap+'/');
        h_current = h;
    }

    if( m2 != m2_current){
        flip('minutesUpRight', 'minutesDownRight', m2, 'Double/Up/Right/', 'Double/Down/Right/');
        m2_current = m2;

        flip('minutesUpLeft', 'minutesDownLeft', m1, 'Double/Up/Left/', 'Double/Down/Left/');
        m1_current = m1;
    }

     if (s2 != s2_current){
        flip('secondsUpRight', 'secondsDownRight', s2, 'Double/Up/Right/', 'Double/Down/Right/');
        s2_current = s2;

        flip('secondsUpLeft', 'secondsDownLeft', s1, 'Double/Up/Left/', 'Double/Down/Left/');
        s1_current = s1;
    }





}

setInterval('retroClock()', 1000);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T17:13:03+00:00Added an answer on June 15, 2026 at 5:13 pm

    I just looked at jQuery reference, setStyle method does not exist.
    You should use css method instead :

    $(upperId).css('height','64px;');
    

    Looking at this code, there are many things, that don’t match with jQuery methods.

    For example: if you want change src attribute to upperId element, in jQuery you should use attr method:

    // $(upperId).src = $(upperBackId).src;  // WRONG
    $(upperId).attr('src', $(upperBackId).attr('src'));   // CORRECT
    

    If you want reference an element with its id you must prepend # before the element id:

    var upperBackId = "#" + upperId + "Back";
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

http://www.koolfree.com/ImageUpload/uploads/1340729929.jpg (Table Image) Hello, I have linked to an Image (because stackoverflow was not
http://www.example.com/http://www.test.com I have tried many different methods using .htaccess with no luck. I need
http://www.keironlowe.host56.com/Website%20Testing/index.html At the bottom below the paragraph of text I have two images with
http://www.plus2net.com/php_tutorial/array_checkbox.php the link is my reference in PHP i want to ask how can
http://www.escapingaspinningroom.com/photos/photo/193 is a web page where I have the comment iFrame on. Litteraly, the
http://www.facebook.com/sharer/sharer.php?u=http%3A%2F%2Fwww.google.com How can I customize the text and image. It looks like Facebook pulled
http://www.stellarwebsolutions.com/en/articles.php I just got the .pem to work with paypal but I cannot find
http://www.myserver.com/mypage.php?param1=abc&param2=123 I need to open this URL from a windows service either by IExplorer
http://www.malsup.com/jquery/form/#html I have multiple forms on a single page. They all use the same
http://www.vidyasocks.com/forums.php?id=1&id=1 as you can see at the bottom I am using hash as a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.