in reply to How can i add 2 hours to localtime?
There are things like Date::Calc, but I think the easiest way is: my $now_plus_two_h = localtime( time + 2*60*60); time gives unix epoch time in seconds, so we add two hours worth of seconds and apply localtime. If the date format doesn't suit you, call POSIX::strftime() on the localtime result. See man strftime to browse what format strings you can use.
After Compline,
Zaxo
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
| A reply falls below the community's threshold of quality. You may see it by logging in. |