Redirecting site's index : META Refresh

  • suzie
  • Guru
  • Guru
  • User avatar
  • Posts: 1134
  • Loc: England

Post 3+ Months Ago

Hello everyone,

I have a member pm me to say that my index is able to be seen by imputting http://www.swishmagic.com, this is not good, is there an easy way to change that please, so http://www.swishmagic becomes http://www.swishmagic.com/forum/index.php?act=portal, i tried a re-direct in host cpanel;, they say it takes some hours to point to it by re-direct, when i try it does'nt load for me at all.
suzie.
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

Code: [ Select ]
<html>
<head>
<META HTTP-EQUIV=Refresh CONTENT="5; URL=http://www.swishmagic.com/forum/index.php?act=portal">
<title>You shouldn't be here</title>
</head>
<body>
You are in the wrong place. The webpage is <a href="http://www.swishmagic.com/forum/index.php?act=portal">HERE</a> . If you are not automatically redirected click the link.
</body>
</html>
  1. <html>
  2. <head>
  3. <META HTTP-EQUIV=Refresh CONTENT="5; URL=http://www.swishmagic.com/forum/index.php?act=portal">
  4. <title>You shouldn't be here</title>
  5. </head>
  6. <body>
  7. You are in the wrong place. The webpage is <a href="http://www.swishmagic.com/forum/index.php?act=portal">HERE</a> . If you are not automatically redirected click the link.
  8. </body>
  9. </html>


Copy and paste that into notepad and save it as index.html and upload it into the root directory. That'll take care of it.
  • suzie
  • Guru
  • Guru
  • User avatar
  • Posts: 1134
  • Loc: England

Post 3+ Months Ago

Ooooh, atno, thankyou, hopefully i can manage that...
Today i got in touch with support at hosts, they said a re-direct does the job, well it did'nt atno, i could'nt get to my forums at all, i had to take the re-direct out again, luckily i did it as a temp so removal was simple.
Thanks a lot for your response atno...but i'm not very good with comps where is the root directory, what name is it something specific..?
suzie
:D
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

Take a look at your original post suzie. You know that index you said could be seen? That's your root directory. Just put it in the same directory you have bluebird2.jpg and pat.jpg in.
  • suzie
  • Guru
  • Guru
  • User avatar
  • Posts: 1134
  • Loc: England

Post 3+ Months Ago

atno, before i left the post feeling well stupid lol, i was thinking bet its that www folder, .but i waited till i got the notification first...
Thanks atno, i'll do it now.
suzie.
:D
  • suzie
  • Guru
  • Guru
  • User avatar
  • Posts: 1134
  • Loc: England

Post 3+ Months Ago

Says transfer complete, what now atno.
Will http://www.swishmagic.com go to a new place, not index like before...?
suzie.
:D
**edit** :shock: no, its the same place atno...i put in index [!].txt is this correct as i have....no wait....i saw the web page index.html, all is well atno, they now have a link "here" i retrieved that other file and uploaded the correct one.phew, thank goodness its right now !!
Suzie.
:oops: but :D :D :D
:oops: almost forgot my manners, thanks alot atno.
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

Yep -- you got it -- takes you to the swish magic page now. Perfect
  • suzie
  • Guru
  • Guru
  • User avatar
  • Posts: 1134
  • Loc: England

Post 3+ Months Ago

And here atno is the support i got this am...
Thank you for your correspondence,
I would recommend you do something called a HTML redirect. If you do a little search on the internet you should be able to find the code. It reloads the page to a differnet URL.
I hope this works out for you!
Have a nice day!
I just told support to maybe put a code in the faq's and that i got the result from ozzu.
suzie.
:D
  • UNFLUX
  • Genius
  • Genius
  • User avatar
  • Posts: 6376
  • Loc: twitter.com/unflux

Post 3+ Months Ago

Just a suggestion, but I would set that 5 second delay to 0. that way
people that go to just your domain are immediately taken to the forum
index. Looks nice, and doesn't give the appearance of being under
construction or that you are moving.
  • suzie
  • Guru
  • Guru
  • User avatar
  • Posts: 1134
  • Loc: England

Post 3+ Months Ago

unflux, would atno be ok with that..?
suzie.
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

*lol -- of course. Actually I dropped it down from 10 to 5, but 0 will do exactly what UNFLUX said it will do.
  • suzie
  • Guru
  • Guru
  • User avatar
  • Posts: 1134
  • Loc: England

Post 3+ Months Ago

unflux is very nice and he helps tons atno, but it being your code lol i did'nt want to mess with out your say so, thats just me, hope unflux understand its just the way i am.
:D
btw atno, has BWM altered his banner recently, its the text underneath ozzu, it look s different some how..?
  • digitalMedia
  • a.k.a. dM
  • Genius
  • User avatar
  • Posts: 5149
  • Loc: SC-USA

Post 3+ Months Ago

//moved
  • Carnix
  • Guru
  • Guru
  • User avatar
  • Posts: 1098

Post 3+ Months Ago

Not to be contrary... but... using an HTML meta redirect isn't really the best way to do it.

Instead, drop this on the very very top of your index.php page:

Code: [ Select ]
<?
header("Location: http://www.swishmagic.com/forum/index.php?act=portal");
exit;
?>
  1. <?
  2. header("Location: http://www.swishmagic.com/forum/index.php?act=portal");
  3. exit;
  4. ?>


You have to put this up top, because once you start sending any content out to the browser, you can't send headers anymore... PHP gets mad at that.

The reason I wouldn't use a meta tag is simply that doing it on the server reduces the back-and-forth.

You send the GET for the /index.php page, the server sends it, and your browser sees that meta tag and automatically asks for the specified URL. With the PHP way, you ask for the /index.php page, but the server sends you the /forum/index.php?act=portal page instead, no second request/response routine which means half the time and resources per page view.

.c
  • suzie
  • Guru
  • Guru
  • User avatar
  • Posts: 1134
  • Loc: England

Post 3+ Months Ago

Carnix hello, thanks for your code, its very nice of you to provide it for me.
And where did you learn such stuff carnix...?
:D
DM,
Quote:
//moved

why did you move it, you did'nt leave me a link :cry: i had to wait till someone posted and i got a notification by e-mail...was it in the wrong place, sorry if it was!
suzie.
:D
  • Carnix
  • Guru
  • Guru
  • User avatar
  • Posts: 1098

Post 3+ Months Ago

You're very welcome.
I don't know, I sort of picked it up here and there, no formal training really. That's a pretty standard PHP command. Mostly, I learned PHP (back when it was an early version 3) from reading the php.net site since back then there were very few good resource books for PHP. That's basically what I do now, too, since even though there are probably good PHP books out there, I have yet to pick on up. PHP.net is a great resource, and so far, hasn't failed me...

I think basic concepts of client-server archetecture are pretty simple when you really think about them. I mean, the devil's in the details, as always, but at a high level, it's not really that complex. A client asks a server a question, the server responds. The fewer times the client and server have to exchange pleasentries, the better.

From there, you start asking things like, "well, what does the client say?" The answer is usually pretty straigt forward, depending on your the protocol. For example, an FTP client starts off by saying something different than an HTTP one (a web browser, for example), which is different than an SMTP one (e-mail) and so forth.

Then, you figure out why the client is asking that.... and what the server says and why,... just start digging down. When you break IT down into bitesized chunks (like any other subject in the world) so that the details aren't so overwhelming, things get much easier. Once you understand some of the details, you'll be able to assemble and synthesize those details to form a more wholist view where those disperate details make even more sense when viewed relative to each other. It just takes a determination.

.c
  • digitalMedia
  • a.k.a. dM
  • Genius
  • User avatar
  • Posts: 5149
  • Loc: SC-USA

Post 3+ Months Ago

suzie wrote:
DM,
Quote:
//moved

why did you move it, you did'nt leave me a link :cry: i had to wait till someone posted and i got a notification by e-mail...was it in the wrong place, sorry if it was!
suzie.
:D


suzie: I'll leave you the link in the other forum next time. ;)

It turned out to be a web design question, not a flash question. I thought the thread was wrapped up when I moved it.

Sorry for the inconvenience.
  • suzie
  • Guru
  • Guru
  • User avatar
  • Posts: 1134
  • Loc: England

Post 3+ Months Ago

DM,
Quote:
I thought the thread was wrapped up when I moved it.

Its ok DM, you can move stuff, you being a mod and all lol
Its just i was mouse overing for some minutes then realised it had gone..somewhere..looked at everything around your maessage but nope..its gone..but where lmaooooo
I need to find it again now cus i forgot what it was about..a link DM..could you please!
suzie.
:D

Post Information

  • Total Posts in this topic: 18 posts
  • Users browsing this forum: No registered users and 35 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.