Rewriting URLs

Started by Tynan, September 26, 2013, 12:08:04 PM

Previous topic - Next topic

Yarkista


Tynan

Quote from: Hypolite on September 27, 2013, 06:32:42 AM
How much time did you wait between the promotion of the parked domain to a full-featured domain? DNS changes can take up to a few hours to propagate.

For more efficient troubleshooting, I would require access to the new domain FTP. From what I understand, there will be nothing on it except the .htaccess, so I won't be able to break anything  ;)

Thanks for the help; I want to continue towards solving this problem in future but for now it's on the back burner.
Tynan Sylvester - @TynanSylvester - Tynan's Blog

British

By the way, what will happen to www.rim-world.com ?
I'm asking since it's the URL used in your first-look video, and thus might have gained some traction...

Tynan

Quote from: British on September 30, 2013, 03:39:17 AM
By the way, what will happen to www.rim-world.com ?
I'm asking since it's the URL used in your first-look video, and thus might have gained some traction...

I'll probably just make it permanently redirect to rimworldgame.com.
Tynan Sylvester - @TynanSylvester - Tynan's Blog

Tony

I see that this is on the back burner for now, so I'll add this here for reference in case you wish to tackle it again.

To have the domain point to the page on the blog, and stay in the address bar, isn't completely achievable, due to the page being just that, a page within the blog. Because there is no existing rimworld directory for the domain to latch on to, the best you can hope for is rimworldgame.com/rimworld (or any other page name, 'buy' for example). (Adding a directory would be the easiest, but it doesn't work unfortunately.)

If you are able to try, set rimworldgame.com up as an Addon Domain, and configure the Document Root field for the path to the blog (from the screenshot, this appears to be /public_html/ludeon.com/blog/). rimworldgame.com should then find its way to the blog also.

In the .htaccess file for the blog (/public_html/ludeon.com/blog/.htaccess) set the following:

RewriteCond %{HTTP_HOST} ^(www.)?rimworldgame\.com [NC]
RewriteRule ^(/)?$ /rimworld/ [R,L]


This, hopefully, will send you to the rimworld page of the blog (rimworldgame.com/rimworld/). I'm not fully sure, but removing the R, from the square brackets should tell Apache to use a silent redirect. My testing of this proved futile though, and I added the R, to make the page re-direct. You might get lucky if you try.

It's not perfect, and the .htaccess code could do with a way to reduce errors from possible bad links or extra words stuck on the end and such, but I'm no expert at that sort of thing. (I also don't know how WordPress works, so cross your fingers it doesn't cry through the whole process.) :P
Tony Gibson

Tynan

Thanks tony! I appreciate your helping out. In the meantime I may take a shot at your solution.

Since this seems to be such a challenge (and perhaps impossible to solve), I'm thinking I might actually just make a little page for rimworldgame.com, separate from the blog entirely. That would, of course, solve this problem. And it's going to be a static landing page anyway.
Tynan Sylvester - @TynanSylvester - Tynan's Blog

Tony

Looking in to it I really wanted it to work, because it would be useful in many ways, especially with a large amount of people using blog software as a CMS. I guess we're not yet meant to have individual domains for every post.

Making a standalone page will be the best option for using the domain, though you would lose the slight ease of editing through the blog. But a static page just means you can save the source and upload it, make a cup of tea and call it a success. :D
Tony Gibson

Tynan

In truth the blog isn't exactly helpful with this anyway. I always edit the post in html mode because the WYSIWIG editor trashes it.

Thanks again for the help.
Tynan Sylvester - @TynanSylvester - Tynan's Blog

British

Speaking about the blog, you still haven't found a way to tie its entries to the forums ?

AcDie

Quote from: British on October 25, 2013, 04:51:40 AM
Speaking about the blog, you still haven't found a way to tie its entries to the forums ?
Bridge between WP & SMF? I thought topic about .htaccess  ::)

British

It has to do with URLs, in a very broad sense :P

Tynan

Quote from: British on October 25, 2013, 04:51:40 AM
Speaking about the blog, you still haven't found a way to tie its entries to the forums ?

I haven't had any time to look into this. It's still on my to-do.
Tynan Sylvester - @TynanSylvester - Tynan's Blog

Tony

#42
Quote from: Tynan on October 25, 2013, 12:35:14 PMI haven't had any time to look into this. It's still on my to-do.
This one is easy. Installing a modification and importing the feed. The hardest part is choosing which modification to add.

Edit: This one has been updated recently, and is compatible with the version of SMF used here: http://custom.simplemachines.org/mods/index.php?mod=624
Tony Gibson

Tynan

Quote from: Tony on October 25, 2013, 07:19:37 PM
Quote from: Tynan on October 25, 2013, 12:35:14 PMI haven't had any time to look into this. It's still on my to-do.
This one is easy. Installing a modification and importing the feed. The hardest part is choosing which modification to add.

Edit: This one has been updated recently, and is compatible with the version of SMF used here: http://custom.simplemachines.org/mods/index.php?mod=624

Again, thanks very much Tony.

..looking at this, it just looks like a way to make forum threads based on news posts. But what about actually integrating them with WP, so the comments link points right at the forums and reports the proper number of posts?
Tynan Sylvester - @TynanSylvester - Tynan's Blog

Tony

Ahh. Hmm, a quick search gives me this: http://wordpress.org/plugins/post-to-smf-forum/ (It is for an older version of SMF though.)

I'm not sure about the Weblog posts showing the fora post count, as it doesn't mention this in the description, but it can add a link. You can then simply turn comments off on the Weblog.
Tony Gibson