Jump to content

How to get POST variables?


Recommended Posts

header('Content-type: text/html; charset=UTF-8');
include(dirname($_SERVER['DOCUMENT_ROOT']) . DIRECTORY_SEPARATOR . 'configlin.php');
error_reporting(E_ERROR | E_WARNING | E_PARSE | E_NOTICE);
include($path_www2 . 'forum/sphinxapi.php');
define( 'IPB_THIS_SCRIPT', 'public' );
define( 'IPS_ENFORCE_ACCESS', TRUE ); // Приложение работает при отключенном форуме
require_once( $path_to_ipb . 'init.php' );
//require_once( IPS_ROOT_PATH . 'sources/base/ipsRegistry.php' );
//require_once( IPS_ROOT_PATH . 'sources/base/ipsController.php' );
//$ipbRegistry	= ipsRegistry::instance();
//$memberData = &$ipbRegistry->member()->fetchMemberData();
$search_term = "";
$page = 1;
$text_out = "";
//$request	=& $ipbRegistry->fetchRequest();
$request = \IPS\Request::i()->var;
print "<pre>";
print_r ($request); 

Its changed code from 3.4 version, but don't work.


Link to comment
Share on other sites

require_once( "path_to_ipb" . 'init.php' );
$request = \IPS\Request::i()->var;
print ($request);

How to get POST variables? Can not find it in docs. This method don't work :(

​Can you describe what isn't working? POST is merged into the data that object works with after REQUEST, so if you have a POST id=2 and a REQUEST id=3(should never happen obviously, merely an example), \IPS\Request::i()->id would return 2.


Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...