Round Rock / Austin, Texas
Drupal Web Developer

Trouble Getting your 'GET' Variables to Work?

Error message

Deprecated function: implode(): Passing glue string after array is deprecated. Swap the parameters in drupal_get_feeds() (line 394 of /home/thefoxes/

Trouble Getting your 'GET' Variables to Work?

PHP for GET Variables

Always make sure you do some error checking before trying to use the GET variable!

In this example we are passing something like this:

In our code we want to validate by using 'isset' before actually trying to use the value. Otherwise php is going to barf and throw and error such as "Notice: Undefined index: .... $GET"

     $year = $_GET['year'];
} else {
      $year = '2012';