Day 15 — The Fiddle

I started some hard coding some jQuery code for the timeclock. From what I’ve gathered from JS is that the specific information needed usually requires its own variable. So I wrote out all my variables before setting up the exact function.

Picture of JS Fiddle coding tool

$(document).ready(function(){ — All jQuery code must start with this to work properly


var date = new date(); — Date variable which specifies to date object that today must start a “new date”

var Hours = new gethours(); — Giving the specific hour timeframe

var Mintues = new getmintues(); — Giving the specific minutes timeframe

var Seconds = new getseconds(); — Giving the specific second timeframe

if (Hours > 12) {

Hours = Hours — 12
}); }); — My Hours variable will automatically bring back military time which I don’t like. This code tells it to return the hourly timeframe in cilivan time

I will need to use the setInterval function in some way but I can’t quite figure it out. I’ll go back at tomorrow.

Also, click the ❤ below to help me inspire more people in break into tech.

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.