Skip to content

Commit

Permalink
Missing global variables for additional criteria lines
Browse files Browse the repository at this point in the history
  • Loading branch information
lem9 committed Jul 4, 2012
1 parent 5223035 commit 0c9effa
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions db_qbe.php
Expand Up @@ -25,6 +25,22 @@
}
}

/**
* Sets globals from $_POST patterns, for Or* variables
* (additional criteria lines)
*/

$post_patterns = array(
'/^Or/i'
);
foreach (array_keys($_POST) as $post_key) {
foreach ($post_patterns as $one_post_pattern) {
if (preg_match($one_post_pattern, $post_key)) {
$GLOBALS[$post_key] = $_POST[$post_key];
}
}
}

/**
* Gets the relation settings
*/
Expand Down

0 comments on commit 0c9effa

Please sign in to comment.