|
|
#1 (permalink) |
|
Registered User
Fresh Surpasser
Joined in Jan 2004
13 posts
Gave thanks: 0
Thanked 0 times
|
Hello,
I am using a guestbook from Matt's Script Archive. Everything works well, except the date does not show up for user entries. I want to make sure I have set the Unix Date command location correctly. Does anyone know how to do that? Matt's help page says: "Another possible problem is that you are using the default cgi-bin on an NCSA server or another web server that comes with a pre-made cgi script called 'date'. This can cause problems if you do not set your script to point to the unix date command. To find out where that is, type this at your unix prompt: which date That should give you a path to the date command." And the actual code that's not working currently looks like this: Code:
$date_command = "/usr/bin/date"; ... $date = `$date_command +"%A, %B %d, %Y at %T (%Z)"`; chop($date); $shortdate = `$date_command +"%D %T %Z"`; chop($shortdate); ... print GUEST " - $date<hr>\n\n"; Thanks! |
|
|
|
|
|
#2 (permalink) |
|
01101100
Super #1
Joined in Jan 2006
Lives in West Michigan
Hosted on SH92
1,602 posts
Gave thanks: 49
Thanked 112 times
|
Re: Unix Date Command?
This should help, from the server I am on here:
xxxx xxxx [~]# type datedate is /bin/date Your path should be: /bin/date |
|
|
|