gurpreetsingh13 has asked for the wisdom of the Perl Monks concerning the following question:
my $roundParams = { 'AllowParticipantsToSeeEachOther' => JSON::PP:: +true, 'DurationInMinutes' => 10, 'MaxGamePegValue' => 5, 'MaxNumberOfCrackAttemptsPerCode' => 18, 'MaxNumberOfCrackAttemptsPerTeam' => 0, 'NumberOfDefaultHostParticipants' => 1, 'NumberOfPegsInRound' => 4, 'RoundStartTime' => "\\/Date(" + . $milliSeconds . ")\\/", 'TimeBetweenRoundATimeBetweenRoundAttemptsInSeconds' => 10 }; say Dumper $roundParams; say $roundParams->{'RoundStartTime'}; say to_json $roundParams;
Output:
Tried various things like eliminating one backslash for escape character, adding \e, using qq etc., but nothing worked out. Would be thankful if you could guide in that.{"AllowParticipantsToSeeEachOther":true,"TimeBetweenRoundATimeBetweenR +oundAttemptsInSeconds":10,"NumberOfDefaultHostParticipants":1,"MaxNum +berOfCrackAttemptsPerTeam":0,"RoundStartTime":"\\/Date(1401265928689) +\\/","NumberOfPegsInRound":4,"DurationInMinutes":10,"MaxNumberOfCrack +AttemptsPerCode":18,"MaxGamePegValue":5}
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Json epoch datetime with perl
by hdb (Monsignor) on May 28, 2014 at 09:26 UTC | |
by gurpreetsingh13 (Scribe) on May 28, 2014 at 09:35 UTC | |
by poj (Abbot) on May 28, 2014 at 10:07 UTC | |
by gurpreetsingh13 (Scribe) on May 28, 2014 at 10:53 UTC | |
by Anonymous Monk on May 28, 2014 at 11:26 UTC | |
|
Re: Json epoch datetime with perl
by Anonymous Monk on May 28, 2014 at 08:54 UTC | |
by gurpreetsingh13 (Scribe) on May 28, 2014 at 09:16 UTC | |
by Anonymous Monk on May 28, 2014 at 09:20 UTC |