Sha256: b45b23c5348a03631b7a1a7783165de636c88c61fb8a3fd56d919ecc638d963f

Contents?: true

Size: 776 Bytes

Versions: 18

Compression:

Stored size: 776 Bytes

Contents

<?php
	$dst = ( isset( $_GET[ "to" ] ) 
		? $_GET[ "to" ] 
		: ( isset( $_POST[ "to" ] ) 
			? $_POST[ "to" ] 
			: false ) );
	if ( $dst ) {
		// **********************************************************************
		// The crucial line: Issue a custom header with the location to which the
		// redirect should happen. For simplicity, we simply redirect to whatever
		// location was specified in the request's "to" parameter, but real-world
		// scripts can compute the destination based on server-side state.
		//
		// NB: This is not a HTTP redirect. As far as HTTP is concerned, this is
		// a normal request/response cycle with a status code of 200.
		// **********************************************************************
		header( "X-Redirect: " . $dst );
	}
?>

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
RubyApp-0.7.16 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.15 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.14 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.13 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.12 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.11 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.10 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.9 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.5 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.4 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.3 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.2 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.1 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.7.0 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.6.71 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.6.70 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.6.69 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php
RubyApp-0.6.68 lib/ruby_app/resources/elements/mobile/document/jquery.mobile-1.3.0/demos/docs/examples/redirect/redirect.php