Jump to content

?how To Make A Redirect?


AGENT_P6

Recommended Posts

Newbie to web design here, so please dont judge if this is an "easy" questionI want to know how to set up a redirect of sorts. What i have planned is to have a really simple homepage on the website im designing, which will be a gamers website/clan, specifically geared towards black ops and world at war "zombies". The homepage will be just image links to the forums, news, trophy guides, facebook page, etc, and when a user clicks on any of these links i want a redirect for style purposes basically, which i will explain.In the games i mentioned, there is a teleporter that, when you activate it, you are surrounded by electricity and then teleported. I want to take about 10 screenshots of this and create an animated gif that will display as a full page animated background so that the user "teleports" to the forums, news, etc. just as if they were playing the game. Might sound cheesy but for fans of the game, and with a well done gif, i think it may look nice. Usually when i get redirected im on the redirect page for 2-5 seconds so this is a perfect time frame since its a similar time frame in the game.Thanx in advance :)

Link to comment
Share on other sites

Hmmm...im not sure about the java. Im thinking like there have been times when i logged into a website or posted on a forum, and after hitting "go" or "submit post" i would be redirected to a page that says something to the effect of "thank you for logging in/thank you for your post, click (url)here(/url) if your browser doesnt automatically redirect you." its exactly that type of redirect i want to code in. Just when users click links from the homepage tho, cuz it would get annoying if that redirect happened everywhere on the entire siteWhat im thinking of doing is making it so that when users click on a link from the homepage, they get exactly that type of redirect, except the index html of that page wont have any text...just that animated gif as a background to simulate whats in the game. The gif will likely suffice for the effect i want. It will be my first ever website so im not aiming to make front page google. I havent learned java at this stage of the game.I'm more or less hoping to find out the steps id take in my coding. I already have a "redirect folder" with an html skeleton set up...just dont know what to put on my root index.html and dont know what to put on my redirect index.html to make it happen...well i know how to set up the background and all of tht stuff, just dont know the redirect code.

Link to comment
Share on other sites

Just to be clear... you want a page with an animated gif to appear when a link from the homepage is clicked. From the animated gif page you want the browser to redirect the user to a different page..So the link would be animated.htm and the redirect would be page1.htmIs that what you are saying?dink

Link to comment
Share on other sites

Sounds like you would want to use javascript to play some sort of animation to the user. That could be easy or hard depending on the quality of the effect you are hoping to achieve. It seems like you would have to start and just try different things to see how you need to get there, and if it's easy to do or not, and to what degree of quality. Flash could be a better alternative, as mentioned.

Link to comment
Share on other sites

Sounds like you would want to use javascript to play some sort of animation to the user. That could be easy or hard depending on the quality of the effect you are hoping to achieve. It seems like you would have to start and just try different things to see how you need to get there, and if it's easy to do or not, and to what degree of quality. Flash could be a better alternative, as mentioned.
Just curious why can't you use just a plain animated gif on a page and then have it redirect?dink
Link to comment
Share on other sites

Just curious why can't you use just a plain animated gif on a page and then have it redirect?dink
You can't control how a GIF image is being played. That's why i guess. It's just a file.
Link to comment
Share on other sites

Yes, i want to have a user be taken to a "redirect page" where the gif will display, then the user will be redirected to the location of the homepage link they clicked on. The gif will do just fine. The reason being that the in-game teleportation is simply the player just standing completely still, staring off into the distance, and the only movement is lightning streaks flickering in and out from the teleporter's electricity. I can achieve the effect i want with an animated gif for sure because all motion in the game itself is completely sporadic, therefore looping a gif over and over wont look bad. If i was to try to make a gif with a character moving from left to right then that would be an issue because at the end of the loop, the character would reappear at the left and move right again, which would look horrible. Using a gif to animate lightning is easy to do and will look nice. Flash or java is not necessary.So does anyone know how i will code this??

Link to comment
Share on other sites

transfer to page with animated gif, and just add onload javascript function to redirect at given time

<script type="text/javascript"> window.onload=function(){var delay = setTimeout( "redirect()",5000 ) //1000 = 1sec};function redirect(){document.location.href="http://towhateverpage.html"}</script>

Link to comment
Share on other sites

transfer to page with animated gif, and just add onload javascript function to redirect at given time
<script type="text/javascript"> window.onload=function(){var delay = setTimeout( "redirect()",5000 ) //1000 = 1sec};function redirect(){document.location.href="http://towhateverpage.html"}</script>

Perfect, thank you. So what would i change in that code to have the user see the gif for 3 seconds before being redirected to where they want to go?Could you quote your post and edit the quote to show me how to make it 3 seconds?I know i probably sound like the dumbest guy in the world right now for asking that but everyones gotta start somewhere, and this is my very first attempt at a simple website
Link to comment
Share on other sites

Sweet thanx. I know absolutely nothing about java, and i just know the basics of html and css. Im pretty much teaching myself via a couple books i bought and this site, using my website as an actual "project" of sorts to apply what i learn. Thanx for your guys' help :)

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...