Jump to content

Redirect


wegorz23

Recommended Posts

Posted

Hello, in IPB 3.x.x version I could used this code to redirect to another page : ipsRegistry::getClass('output')->silentRedirect($this->settings['my_url']);

How can I do that in version 4 ? 

Posted

Hello,

\IPS\Output::i()->redirect(\IPS\Http\Url::internal(''));
	/**
	 * Redirect
	 *
	 * @param	\IPS\Http\Url	$url			URL to redirect to
	 * @param	string			$message		Optional message to display
	 * @param	int				$httpStatusCode	HTTP Status Code
	 * @param	bool			$forceScreen	If TRUE, an intermediate screen will be shown
	 * @return	void
	 */
	public function redirect( $url, $message='', $httpStatusCode=301, $forceScreen=FALSE )

 

  • 2 months later...

Archived

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

  • Recently Browsing   0 members

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