I am writing a guestbook script using MySQL, the part of the script below
is a loop which executes to read from the database all the input data to
print it out to screen.
1)
In the $gbDate line, the $T argument displays as $T instead of the actual
time in Windows. Is this a fault in Windows, or have I done something
wrong? Webpage will eventually be in Unix server online.
2)
If I uncomment the setlocale line, the output date string still stays in
English rather than whatever language I want it to output - how can I get
that to work? Does it work on localhost?
I am using PHP4.3.2, Apache2, MySQL 4 - all on Windows98SE machine running
as localhost.
Thanks
Dariusz
// setlocale (LC_TIME, 'nl,NL');
while ($row = mysql_fetch_array($result))
{
$gbID = $row['gbID'];
$gbDate = gmstrftime('%A %d %B %Y at $T',strtotime($row['gbDate']));
$gbURL = $row['gbURL'];
$gbName = $row['gbName'];
$gbComment = $row['gbComment'];
$display_entry .= "$gbID:<BR><B>Posted: </B>$gbDate <B>IP:
</B>Logged<BR><B>Name: </B>$gbName<BR><B>Personal website:
</B>$gbURL<BR><B>Comment: </B>$gbComment<BR><BR>";
}