diff options
| author | Greg Roach <fisharebest@gmail.com> | 2013-08-29 22:35:00 +0100 |
|---|---|---|
| committer | Greg Roach <fisharebest@gmail.com> | 2013-08-29 22:35:00 +0100 |
| commit | def8f50065a593a06a051ceb58b7686884a8ce58 (patch) | |
| tree | df7cb13b850c7f6332d9c40bc9daf560d0b19586 /library/WT/Controller/Pedigree.php | |
| parent | cd3cb363db375e0e9b7d5214b33e382f77aa9400 (diff) | |
| download | webtrees-def8f50065a593a06a051ceb58b7686884a8ce58.tar.gz webtrees-def8f50065a593a06a051ceb58b7686884a8ce58.tar.bz2 webtrees-def8f50065a593a06a051ceb58b7686884a8ce58.zip | |
New filter/validation functions for GET/POST variables
Diffstat (limited to 'library/WT/Controller/Pedigree.php')
| -rw-r--r-- | library/WT/Controller/Pedigree.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/library/WT/Controller/Pedigree.php b/library/WT/Controller/Pedigree.php index ad68d9bc27..82c18cd354 100644 --- a/library/WT/Controller/Pedigree.php +++ b/library/WT/Controller/Pedigree.php @@ -60,10 +60,10 @@ class WT_Controller_Pedigree extends WT_Controller_Chart { $this->shadowoffsetX = $shadowoffsetX; $this->shadowoffsetY = $shadowoffsetY; - $this->show_full =safe_GET('show_full', array('0', '1'), $PEDIGREE_FULL_DETAILS); - $this->talloffset=safe_GET('talloffset', array('0', '1', '2', '3'), $PEDIGREE_LAYOUT); - $this->box_width =safe_GET_integer('box_width', 50, 300, 100); - $this->PEDIGREE_GENERATIONS=safe_GET_integer('PEDIGREE_GENERATIONS', 2, $MAX_PEDIGREE_GENERATIONS, $DEFAULT_PEDIGREE_GENERATIONS); + $this->show_full = WT_Filter::getInteger('show_full', 0, 1, $PEDIGREE_FULL_DETAILS); + $this->talloffset = WT_Filter::getInteger('talloffset', 0, 3, $PEDIGREE_LAYOUT); + $this->box_width = WT_Filter::getInteger('box_width', 50, 300, 100); + $this->PEDIGREE_GENERATIONS = WT_Filter::getInteger('PEDIGREE_GENERATIONS', 2, $MAX_PEDIGREE_GENERATIONS, $DEFAULT_PEDIGREE_GENERATIONS); if ($this->talloffset==1) $this->talloffset=1; // Make SURE this is an integer if ($this->talloffset>1 && $this->PEDIGREE_GENERATIONS>8) $this->PEDIGREE_GENERATIONS=8; @@ -253,4 +253,4 @@ class WT_Controller_Pedigree extends WT_Controller_Chart { if ($f<count($treeid)) adjust_subtree($f, $diff); if ($m<count($treeid)) adjust_subtree($m, $diff); } -} +}
\ No newline at end of file |
