in reply to How to get the elements of gmtime() using Time::gmtime?

Time::gmtime() is a gussied-up version of the builtin gmtime. It returns a blessed hashref with the time struct elements given text labels as keys.

Your usage is suitable for builtin gmtime, so you can fix it by leaving off the use Time::gmtime; line. One good reason to use the builtin is that its returned list is like localtime's, suitable arguments for POSIX::strftime. That is a very useful sprintf-like string formatter specialized for time functions.

use POSIX 'strftime'; print strftime("Standard Time is %r.\n", gmtime);

If all you want is the seconds' part, this will work:

my ($sec) = gmtime; print <<"ETXT"; Content-Type: Text/html\n\n <b><font face="courier" color="white" size=2>$sec</font></b> ETXT

After Compline,
Zaxo