diff options
Diffstat (limited to 'lib/plugins/popularity')
-rw-r--r-- | lib/plugins/popularity/admin.php | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/lib/plugins/popularity/admin.php b/lib/plugins/popularity/admin.php index 364075903..474a09ef9 100644 --- a/lib/plugins/popularity/admin.php +++ b/lib/plugins/popularity/admin.php @@ -50,15 +50,17 @@ class admin_plugin_popularity extends DokuWiki_Admin_Plugin { * handle user request */ function handle() { + global $INPUT; + //Send the data - if ( isset($_REQUEST['data']) ){ - $this->sentStatus = $this->helper->sendData( $_REQUEST['data'] ); + if ( $INPUT->has('data') ){ + $this->sentStatus = $this->helper->sendData( $INPUT->str('data') ); if ( $this->sentStatus === '' ){ //Update the last time we sent the data touch ( $this->helper->popularityLastSubmitFile ); } //Deal with the autosubmit option - $this->_enableAutosubmit( isset($_REQUEST['autosubmit']) ); + $this->_enableAutosubmit( $INPUT->has('autosubmit') ); } } @@ -78,7 +80,9 @@ class admin_plugin_popularity extends DokuWiki_Admin_Plugin { * Output HTML form */ function html() { - if ( ! isset($_REQUEST['data']) ){ + global $INPUT; + + if ( ! $INPUT->has('data') ){ echo $this->locale_xhtml('intro'); //If there was an error the last time we tried to autosubmit, warn the user @@ -106,7 +110,7 @@ class admin_plugin_popularity extends DokuWiki_Admin_Plugin { //If we failed to submit the data, try directly with the browser echo $this->getLang('submissionFailed') . $this->sentStatus . '<br />'; echo $this->getLang('submitDirectly'); - echo $this->buildForm('browser', $_REQUEST['data']); + echo $this->buildForm('browser', $INPUT->str('data')); } } } |