Fast Redirector

  • Inito
  • Graduate
  • Graduate
  • User avatar
  • Posts: 223

Post 3+ Months Ago

When I set cookies, they're only valid after the page is refreshed,
that's why I need a redirector.
Ive used a couple of techniques, but they lack what ive seen on a site.
I need it to be that fast that you cannot see the URL in the address bar.

On a site before, ive seen a link linking to another file, but it redirected so fast you wouldnt notice you actually accessed another site by the way.
  • _Leo_
  • Proficient
  • Proficient
  • User avatar
  • Posts: 279
  • Loc: Buenos Aires, Argentina

Post 3+ Months Ago

Language you are using?
  • Inito
  • Graduate
  • Graduate
  • User avatar
  • Posts: 223

Post 3+ Months Ago

PHP, and a redirection in PHP would be prefered, otherwise javascript should do :wink:
  • CazpianXI
  • Proficient
  • Proficient
  • User avatar
  • Posts: 285

Post 3+ Months Ago

Maybe try this mixture of JavaScript and PHP:

Code: [ Select ]
<script language="JavaScript">
<!--
window.location="<?php echo $HTTP_SERVER_VARS['PHP_SELF']; ?>?whatever";
//-->
</script>
  1. <script language="JavaScript">
  2. <!--
  3. window.location="<?php echo $HTTP_SERVER_VARS['PHP_SELF']; ?>?whatever";
  4. //-->
  5. </script>


This is the script that I use whenever I need to reload the page . It just appends "?whatever" to the end of the present URL to prevent browsers from pulling the page out of their cache. (replace "whatever" with whatever you want)

Hope this helps.
  • rjstephens
  • Professor
  • Professor
  • User avatar
  • Posts: 774
  • Loc: Brisbane, Australia

Post 3+ Months Ago

this is the code I use for redirects, this has the advantage of being more google-friendly than most other methods (the code is in php)

<?php
$siteurl="http://yourwebsite.com/";
header("HTTP/1.1 301 Moved Permanently");
header("Location: $siteurl");
exit();
?>

Post Information

  • Total Posts in this topic: 5 posts
  • Users browsing this forum: No registered users and 115 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.