Php problem with undefined variables?

I’m playing around with a PHP script and am running into an odd problem.

I’m trying to adapt the RSSViewer wrtiiten by Erational

Flash calls the PHP script with an url query

In the PHP script there’s the following:


$category = $_GET['category'];
$id = $_GET['id'];
$action = $_GET['action'];

However, when the PHP script is called like this


rssView.php?action=viewCat

then I get errors saying that there’s an
undefined index: category and
undefined index: id

As I understand it the script tries to assign values to these variables that simply are not there 'cause they haven’t been sent to the script.
How can I prevent this from happening?

Thanks