|
Andrea_R
|
 |
« on: March 31, 2008, 07:32:07 AM » |
|
Allrighty tech-heads got a question for ya. I have a member blog that has "graduated" and moved off to her own domain. i would like to redirect her old blog address to her new domain. (also? She paid me.) Mr google helped plenty except for the fact what I typed in did not work.  naturally, there was not a specific example of what I wanted to do and I'm not sure how to handle the whole virtual subdomain and a 301 redirect. redirect 301 sublog.hsj.net to http://hernewdomain.com was a no-go. It's at the bottom of the file, if that helps.
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
drmike
|
 |
« Reply #1 on: March 31, 2008, 09:06:52 AM » |
|
A quick google tells me that this is what's needed: RewriteCond %{HTTP_HOST} ^username\.hsj\.net RewriteRule (.*) http://hernewdomain.com/$1 [R=301,L] Damn if I know though. For reference, I got it from here. I see mention of doing it as a server alias which would probably be best. That way, it's done at the apache level and doesn't fill up your htaccess file.
|
|
|
|
|
Logged
|
|
|
|
|
Andrea_R
|
 |
« Reply #2 on: March 31, 2008, 09:25:57 AM » |
|
Ahhh your google-fu is exceeding mine today.  thanks. Forgot to mention new domain is on another server (ie; not mine). wasn't ready to host her yet. Edit: those htaccess lines worked like a charm. i didn;t mind it int he htacces because it;s 2 lines. I doubt I'd have ten people doing this. and if I do get to that spot, I'll host 'em and do it the other way. :d
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
drmike
|
 |
« Reply #3 on: March 31, 2008, 09:41:40 AM » |
|
Not a problem.
|
|
|
|
|
Logged
|
|
|
|
|
trent
|
 |
« Reply #4 on: March 31, 2008, 11:02:59 AM » |
|
The only other thing you could do is create a premium plugin that redirects to whatever address the user wants. I am not sure if a javascript solution would work or a simple redirect subscribing to the the wordpress header function would be enough, but then the user could put in the address through an option in their dashboard and redirect their blog wherever they want. Might be something for the future versus constantly using .htaccess to do it. I know I am going to run into this myself since I also have a few extra lines in the .htaccess now that I wouldn't mind getting rid of  Trent
|
|
|
|
|
Logged
|
|
|
|
|
Andrea_R
|
 |
« Reply #5 on: March 31, 2008, 11:13:31 AM » |
|
Yeah, I'm totally putting on the "whenever" list for a future premium feature. But my heavy coder still has his day job. 
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
Luke
|
 |
« Reply #6 on: March 31, 2008, 11:23:08 AM » |
|
* Luke prefers to let php handle it, so htaccess remains small. An if check in the main index.php file, before it calls blog header. If it's only a blog or two, htaccess is OK, but more than that is really not worth it.
|
|
|
|
|
Logged
|
10 frames? Heh, that's for Quakers.
Note: This message may be Canadian friendly.
"Pornographic monster on the floor"
|
|
|
|
drmike
|
 |
« Reply #7 on: March 31, 2008, 12:47:44 PM » |
|
Could also just use a special theme assigned to only the old site where the index.php grabs the url that's being called, replaces the root of the address with the new site and does a 0 second refresh and sends the visitor on their way.
Nothing gets placed in the server or htaccess. You do have another theme though to keep track of. That's what some of our installs do although they do it quietly. Offer it publicly and you wind up with hundreds of special themes when everybody want to do this.
Hmm, I wonder if this is how wp.com does it with their sunrise file that Donncha has hinted about.
|
|
|
|
|
Logged
|
|
|
|
|
Luke
|
 |
« Reply #8 on: March 31, 2008, 01:42:06 PM » |
|
But, why go through loading WP just to redirect?
Doesn't make resource sense.
Load a theme just to redirect? Nah.
Now, sunrise capabilities are another thing. For a large amount of such rewrites, it would make sense. As for how Donncha has it worked out, I've got a pretty good idea about it.
|
|
|
|
|
Logged
|
10 frames? Heh, that's for Quakers.
Note: This message may be Canadian friendly.
"Pornographic monster on the floor"
|
|
|
|
Andrea_R
|
 |
« Reply #9 on: March 31, 2008, 01:47:29 PM » |
|
Gonna tell us? :Dthe sunrise file ultimately sounds like a decent solution. And yeah - so far this is *one* blog. I have a mountain of work to do before I even think about making it a publicly announced paid feature.
Edit: permalinks for the blog don't redirect. hmmm. hafta think about that. (whether I even want to, you know?)
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
trent
|
 |
« Reply #10 on: March 31, 2008, 02:32:39 PM » |
|
The following does redirects for me  RewriteCond %{HTTP_HOST} ^blog.yourdomain.com$ [NC] RewriteRule ^(.*)$ http://newdomain.com/$1 [R=301,L] Trent
|
|
|
|
|
Logged
|
|
|
|
|
drmike
|
 |
« Reply #11 on: March 31, 2008, 07:40:49 PM » |
|
I hate rewrite rules.
|
|
|
|
|
Logged
|
|
|
|
|
ron_r
|
 |
« Reply #12 on: March 31, 2008, 07:45:23 PM » |
|
The only other thing you could do is create a premium plugin that redirects to whatever address the user wants. <snip> but then the user could put in the address through an option in their dashboard and redirect their blog wherever they want.
I won't be writing something which will permit the user to do this themselves. Barring rare exceptions, this is something that would only be done once for each user. Between education time and errors, we would end up spending more time enabling the user to do it than we would doing it ourselves.
|
|
|
|
|
Logged
|
The key to problem solving is identifying the problem.
|
|
|
|
Luke
|
 |
« Reply #13 on: March 31, 2008, 08:10:55 PM » |
|
Who is this "Ron" character?
|
|
|
|
|
Logged
|
10 frames? Heh, that's for Quakers.
Note: This message may be Canadian friendly.
"Pornographic monster on the floor"
|
|
|
|
Andrea_R
|
 |
« Reply #14 on: April 01, 2008, 08:42:07 AM » |
|
seems familiar...
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
trent
|
 |
« Reply #15 on: April 01, 2008, 09:21:56 AM » |
|
I would have it close to the top of the .htaccess file as it only works for me that way. If it is below the WPMU stuff it seems to not work. It is at the top of mine.
Trent
|
|
|
|
|
Logged
|
|
|
|
|
ron_r
|
 |
« Reply #16 on: April 03, 2008, 08:13:17 PM » |
|
Who is this "Ron" character?
*Delurking* 
|
|
|
|
|
Logged
|
The key to problem solving is identifying the problem.
|
|
|
freshestnoob
Newbie
Karma: 0
Offline
Posts: 7
|
 |
« Reply #17 on: May 01, 2008, 02:47:25 AM » |
|
@Luke. You've spent months staring at that ron's profile picture and you still can't figure who he is?  I spent five minutes here and I realised he is andrea's 'heavy coder' and lots more (who do you think he's kissing?). I wish xer could see his profile picture. 
|
|
|
|
|
Logged
|
|
|
|
|
Andrea_R
|
 |
« Reply #18 on: May 01, 2008, 07:44:50 AM » |
|
lol Ron posts sporadically here, luke was giving him a hard time.  Yep, he;s my heavy coder and more for almost 20 years. And yeah... lol at that other thread...
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
ron_r
|
 |
« Reply #19 on: May 01, 2008, 08:44:44 PM » |
|
Which thread was that? (another occasional post) 
|
|
|
|
|
Logged
|
The key to problem solving is identifying the problem.
|
|
|
|
Andrea_R
|
 |
« Reply #20 on: May 02, 2008, 07:45:49 AM » |
|
It was that one on the other forum, honey - the where I said some guy didn't know I was a woman.  @fresestnoob - it was funnier a few days ago when Ron & I still had the same avatar.
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
Luke
|
 |
« Reply #21 on: May 02, 2008, 09:05:24 AM » |
|
We need to make Ron a big, manly avatar. Something with guns, explosions, hunting, fishing, or sports. You know, grown-ass man stuff.  Either that or we might have to color his username pink. 
|
|
|
|
|
Logged
|
10 frames? Heh, that's for Quakers.
Note: This message may be Canadian friendly.
"Pornographic monster on the floor"
|
|
|
|
drmike
|
 |
« Reply #22 on: May 02, 2008, 09:34:52 AM » |
|
Who is this "Ron" character?
Didn't he have a girlfriend by the name of Kim.... As to the manly stuff line: LinkDon't know if our companions to the north can see that but....
|
|
|
|
|
Logged
|
|
|
|
|
Andrea_R
|
 |
« Reply #23 on: May 02, 2008, 11:47:18 AM » |
|
We need to make Ron a big, manly avatar. Something with guns, explosions, hunting, fishing, or sports. You know, grown-ass man stuff.  Either that or we might have to color his username pink.  *SIGHS* FINE THEN. I shall make him a new one with his shiny tractor AND his chain saw. running. tough enough for ya?  (so much for geek love...  )
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
Luke
|
 |
« Reply #24 on: May 02, 2008, 12:41:37 PM » |
|
I dunno. Throw in some guns a blazing, and it might get close.
I got one sitting around that I could give him. Something about supporting single moms. he he he
|
|
|
|
|
Logged
|
10 frames? Heh, that's for Quakers.
Note: This message may be Canadian friendly.
"Pornographic monster on the floor"
|
|
|
|
ron_r
|
 |
« Reply #25 on: May 02, 2008, 07:52:44 PM » |
|
I dunno. Throw in some guns a blazing, and it might get close.
I got one sitting around that I could give him. Something about supporting single moms. he he he
Do remember I live with 4 women, 3 of which are single and dependent. That's more than enough to support  New icon should arrive tomorrow 
|
|
|
|
|
Logged
|
The key to problem solving is identifying the problem.
|
|
|
|
ron_r
|
 |
« Reply #26 on: May 04, 2008, 12:12:28 PM » |
|
New icon should arrive tomorrow  Done 
|
|
|
|
|
Logged
|
The key to problem solving is identifying the problem.
|
|
|
|
Luke
|
 |
« Reply #27 on: May 04, 2008, 12:28:24 PM » |
|
Where's the beer, gun, explosions, and funny furry hat with the ear flaps? 
|
|
|
|
|
Logged
|
10 frames? Heh, that's for Quakers.
Note: This message may be Canadian friendly.
"Pornographic monster on the floor"
|
|
|
|
Andrea_R
|
 |
« Reply #28 on: May 04, 2008, 03:08:41 PM » |
|
well he has a hat at least ... 
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
drmike
|
 |
« Reply #29 on: May 04, 2008, 03:49:00 PM » |
|
He does? I can't see it in that picture.
My eyesight can't be that bad.
|
|
|
|
|
Logged
|
|
|
|
|
Andrea_R
|
 |
« Reply #30 on: May 05, 2008, 07:41:50 AM » |
|
It's a black touque.  Aw heck, I can't remember what americans call 'em... you know, the knitted round hats you pull on.
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
drmike
|
 |
« Reply #31 on: May 05, 2008, 09:11:47 AM » |
|
heh heh heh: http://en.wikipedia.org/wiki/HatThey call them Toboccans down here in the Southern US. I never called them that up north.
|
|
|
|
|
Logged
|
|
|
|
|
ron_r
|
 |
« Reply #32 on: May 05, 2008, 07:01:23 PM » |
|
Snow blindness 
|
|
|
|
|
Logged
|
The key to problem solving is identifying the problem.
|
|
|
|
Luke
|
 |
« Reply #33 on: May 05, 2008, 07:40:18 PM » |
|
In cats?
|
|
|
|
|
Logged
|
10 frames? Heh, that's for Quakers.
Note: This message may be Canadian friendly.
"Pornographic monster on the floor"
|
|
|
|
Andrea_R
|
 |
« Reply #34 on: May 05, 2008, 08:30:44 PM » |
|
i think we have seriously derailed this thread. 
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|
Luke
|
 |
« Reply #35 on: May 05, 2008, 10:29:10 PM » |
|
|
|
|
|
|
Logged
|
10 frames? Heh, that's for Quakers.
Note: This message may be Canadian friendly.
"Pornographic monster on the floor"
|
|
|
|
drmike
|
 |
« Reply #36 on: May 05, 2008, 11:00:15 PM » |
|
i think we have seriously derailed this thread.  Did you ever get your issue dealt with?
|
|
|
|
|
Logged
|
|
|
|
|
trent
|
 |
« Reply #37 on: May 05, 2008, 11:01:55 PM » |
|
Andrea that is Canada. It is a toque 
|
|
|
|
|
Logged
|
|
|
|
|
Andrea_R
|
 |
« Reply #38 on: May 06, 2008, 07:06:18 AM » |
|
i think we have seriously derailed this thread.  Did you ever get your issue dealt with? yep, the first day. 
|
|
|
|
|
Logged
|
Am I the only one with a sig? Ah well, might as well read my blog for lols.
|
|
|
|