I am used to writing multi-line IF statesments which bogs the code so I'm trying to convert some of them into one line. But for some reason, this attempt which I thought I was sure would work, doesn't. Is there a syntax problem?
$name = param('name');
$hash{"name"} = "this and that" if $name ne "";