Apache Question - where do I ask it

  • freder181
  • Newbie
  • Newbie
  • freder181
  • Posts: 9

Post 3+ Months Ago

First time working with an Apache web server. I have a few questions re. best practices for page redirects. i'm not sure which forum to ask in. Any suggestions.

  • SpooF
  • ٩๏̯͡๏۶
  • Bronze Member
  • User avatar
  • Posts: 3423
  • Loc: Richland, WA

Post 3+ Months Ago

That could probably be asked in a few forums depending on the context. Just ask your question in this thread and a mod will move it to the appropriate forum.
  • freder181
  • Newbie
  • Newbie
  • freder181
  • Posts: 9

Post 3+ Months Ago

I am working with a 3 page e-commerce site
- landing page
The landing page is sitting in a subdomain
The subdomain also exists as a symlink under /var/www/html/folder/subdomain
Visitors enter sub.example.com into their browser. I want to redirect them to /var/www/html/folder/subdomain
I have found several different way to do this. Wondering what is the most stable way?
Suggestions I have seen are as follows
1. RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://www.example.com/folder/subdomain [R]
2. Redirect 301 /oldpage.html http://www.example.com/newpage.html
3. RewriteEngine On
RewriteCond %{HTTP_HOST} ^.*oldwebsite\.com$ [NC]
RewriteRule ^(.*)$ http://www.preferredwebsite.net/$1 [R=301,L]

The point of all this is to redirect visitors from the unsecured sub.example.com to the secured http://www.example.com.
  • joebert
  • Genius
  • Genius
  • User avatar
  • Posts: 13511
  • Loc: Florida

Post 3+ Months Ago

From the sounds of this, I'm thinking you don't need a redirect on the Apache level.
Isn't there a "buy now" button, or a pre-order form on that landing page pointing to the checkout page on the secure domain ?

Post Information

  • Total Posts in this topic: 4 posts
  • Users browsing this forum: No registered users and 9 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-2016. Ozzu® is a registered trademark of Unmelted, LLC.