Hey guys, wondering if any of you boffins can make sense of this.
basically its a watch rotating and im having trouble getting it to start without pressing a link.
The original JS code is here
https://github.com/fofr/paulrhayes.com-experiments/blob/master/clock/js/experiment.js
One of the suggestions somebody else mentioned in another forum is the code below im not sure where to to put the 'true' value.
Any help is appreciated,
Thanks!
R
basically its a watch rotating and im having trouble getting it to start without pressing a link.
The original JS code is here
https://github.com/fofr/paulrhayes.com-experiments/blob/master/clock/js/experiment.js
One of the suggestions somebody else mentioned in another forum is the code below im not sure where to to put the 'true' value.
Code:
// *******************************************************************
// here it starts based on if the url has #clock in its end
// a simple way is to change `window.location.hash === "#clock"` to `true`
// and it will start without a hash
// *******************************************************************
if(window.location.hash = true;) {
startClock();
$('p.start').remove();
} else {
$('#start').click(function() {
startClock();
$('p.start').remove();
});
}
Any help is appreciated,
Thanks!
R