Back to vBulletin 3.5 Template Modifications

Today's Date: Anywhere you want!
Mod Version: 1.0.0, by King Kovifor

This modification is in the archives.
vB Version: 3.5.8 Rating: (0 vote - 0 average) Installs: 4
Released: 04 Jan 2006 Last Update: Never Downloads: 17
Not Supported  

Plugin today's date anywhere in the system. Just place the following JAVASCRIPT in the HTML Code.

HTML Code:
<script language="JavaScript">
<!--
function makeArray() {
for (i = 0; i<makeArray.arguments.length; i++)
this[i + 1] = makeArray.arguments[i];
}
function makeArray0() {
for (i = 0; i<makeArray0.arguments.length; i++)
this[i] = makeArray0.arguments[i];
}
function y2k(number) {
return (number < 1000) ? number + 1900 : number;
}
var months = new makeArray('January','February','March','April','May','June','July','August','September','October','November','December');
var days = new makeArray0('Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday');
var today = new Date();
var day   = days[today.getDay()];
var date  = today.getDate();
var month = today.getMonth() + 1;
var year  = y2k(today.getYear());
//-->
</script>
Different Version:

Spoiler (click to open)


Wouldn't a plugin using php's

Code:
date();
function work just as well....

then set that to a variable and insert it wherever you want.

EDIT: this is for jilly - as requested in PM: (don't mean to be rude and steal your thread, so please let me know if you want me to move this post.)

Install this plugin and insert
Code:
$today
wherever you want to display the date and time.

You can change the display of the date and time by editing the plugin:

Code:
$today = date("F j, Y, g:i a");                // March 10, 2001, 5:16 pm
$today = date("m.d.y");                        // 03.10.01
$today = date("j, n, Y");                      // 10, 3, 2001
$today = date("Ymd");                          // 20010310
$today = date('\i\t \i\s \t\h\e jS \d\a\y.');  // It is the 10th day.
$today = date("D M j G:i:s T Y");              // Sat Mar 10 15:16:08 MST 2001
$today = date("H:i:s");                        // 17:16:17
Attached Files
File Type: xml dateanywhere.xml (294 Bytes, 40 views)

Close


Note:

Java taken from freeservers site. I take NO Credit once so ever, it's just instructions.

Download

No files for download.

Similar Mods

Add Today's Date vBulletin 2.x Full Releases

vblts.ru supports vBulletin®, 2022-2024