Current local time in Sound - custom clock for your own web site

Vil du have et eksakt ur på din egen hjemmeside? Eller datoen for i dag, solopgangstid, solnedgangstid eller dagslængde? Bare vælg fra indstillingerne herunder og kopier koden! Det er gratis!

Indstillinger

Placering
Sound, England, Storbritannien
For andre placeringer, brug da søgefeltet i toppen til højre.
Hvad skal vises




Tidsformat



Datoformat




 
Dag:
daynamelørdag
dnamelør
daynum01-31
dnum1-31
day_in_ydag 1-366
Uge:
weekuge 52
Måned:
monthnamedecember
monthnum01-12
mnum1-12
År:
year2024
yy24
Farve og størrelse
px
Sådan vil den se ud
Nuværende lokal tid i Sound:
Det endelig resultat kan være anderledes, afhængig af style sheets på din hjemmeside.
You can style the widget any way you want with CSS.

Dette er koden til din egen ur-widget:

Betingelser for brug

Avanceret brug

There are two widget scripts: A simplified version, t.js, which displays only time, and the main widget script, da.js, which can display time, date, sunrise time, sunset time and day length. The main widget script is available in several languages. For other languages, replace da in the script name with the code for the desired language. (For instance pl.js for Polish, or tr.js for Turkish.)

Parametre til init-funktionen:

ParameterGyldige nøgleordStandardværdi
templateTIME, DATE, SUNTIME
time_formathours, minutes, seconds, 12hours, AMPMhours:minutes:seconds
date_formatdayname, dname, daynum, dnum, day_in_y, week, monthname, monthnum, mnum, yy, yearyear-monthnum-daynum
sun_formatsrhour, srminute, sr12hour, srAMPM, sshour, ssminute, ss12hour, ssAMPM, dlhours, dlminutessrhour:srminute-sshour:ssminute
coordsBreddegrad og længdegrad for placeringen. Nødvendigt for at vise soltider og dagslængde.
idFor identifying the location and the time zone on the server side. Required if the location name contains non-ascii letters, and if you change the HTML element id.
callbackThe name of a function that will be called every second, with rendered template as parameter (optional).

Parameter names and keywords are case sensitive. You can add html and other content to the template, time_format, date_format and sun_format parameters.

Flere urer kan oprettes sådan:

UTC time: <span id="UTC_za00"></span><br/>
New York sunrise time: <span id="New_York_z161"></span><br/>
Tokyo sunrise time: <span id="Tokyo_z444"></span><br/>
Find the <a href="https://time.is/" id="time_is_link" rel="nofollow">current time for any location or time zone on Time.is!</a>
<script src="//widget.time.is/da.js"></script>
<script>
time_is_widget.init({
	UTC_za00 : {},
	New_York_z161 : {
		template: "SUN",
		sun_format: "srhour:srminute",
		coords: "40.71427,-74.00597"
		},
	Tokyo_z444 : {
		coords: "59.33258,18.06490"
		}
	});
</script>

Resultat:

UTC time:
New York sunrise time:
Tokyo sunrise time:
Find the current time for any location or time zone on Time.is!

The values of the time_format, date_format, sun_format and template parameters are inherited, so you don't need to repeat them if the value is the same as for the previously defined widget.

 
 
lørdag, 28. december, uge 52, 2024