Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Better rewrite of multiple ifs

by Dietz (Curate)
on May 01, 2005 at 08:48 UTC ( #452997=note: print w/replies, xml ) Need Help??


in reply to Better rewrite of multiple ifs

You've got 3 characters too many:
for ( keys %error_msgs) )
for ( keys %error_msgs) - removed trailing round bracket

unless ( $error_msgs){$_} )
unless ( $error_msgs{$_} ) - removed right round bracket after $error_msgs

print div( {class=>'tip'},  $%error_msgs{$_} );
print div( {class=>'tip'},  $error_msgs{$_} ); - removed percent sign

Update: Formatting

Replies are listed 'Best First'.
Re^2: Better rewrite of multiple ifs
by Nik on May 01, 2005 at 09:20 UTC
    Thank you!
    I though it was something in the logic but i guess i was too tired to see that extra brackets.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://452997]
help
Chatterbox?
[marinersk]: :-O
[marinersk]: That seems a bit harsh. A newspaper deletes a picture and you respond by deleting a whole city?
[LanX]: yep
[Corion]: First he deleted Bielefeld, now he threatens to delete Darmstadt!
[marinersk]: LOL
[Corion]: People claim that Bielefeld exists, but that's just a ploy to hide LanX's acts!

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (5)
As of 2017-05-29 14:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?