• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Redirect 301

C

CaseHost

Guest
Redirect 301 Hi,

How make a redirect type 301?

ex:

blabla.mysite.com -> mysite.com
 
Add to htaccess:

RewriteBase /
RewriteCond %{HTTP_HOST} ^blabla.mysite.com$ [NC]
RewriteRule ^(.*)$ http://mysite.com/$1 [R=301,L]
 
.htaccess won't work on Windows without an ISAPI module addon.

If you setup the subdomains individually, you can use a default.asp file (or similar) to redirect with the following code:
Code:
<%
  Response.AddHeader "Location", "http://example.com/"
  Response.Status = "301 Moved Permanently"
%>

However, if you have several of these to do and you want to maintain the path and/or querystring, it's a LOT easier to create the subdomain site manually within IIS Admin, and use the following settings for the site:
Create a new redirector site in IIS Admin with the subdomain alias. Right-click that redirector site in IIS Admin, select Properties, Home Directory, check "a redirect to a URL" and then check "a permanent redirection for this resource". Then set the following (using your own domain, of course):
Redirect to: http://example.com$V$Q

More about those here:
http://support.microsoft.com/kb/313074
 
Buy yourself isapi_rewrite and spare yourself the agony of having to do this with the deprecated ASP code...
 
I provided TWO solutions, solutions which didn't require the administrator to spend money on a third party product that would add complexity, memory overhead and another maintenance headache to the server.

My point is that there's NO REASON at all to go out buying another product to replace functionality that IIS can do already. Sure, the ISAPI rewrite functions are "cool", but they're not necessary for the request from the OP.

And I hardly consider two lines of code "agony" for a simple redirect.
 
You’re comparing apples to oranges. I’d like to remind you that Linux is open-source, which means the development process doesn’t require you to drink the Microsoft Cool aid.

Parallels as a company is already overwhelmed with their products. Adding a rewrite extension to their development would be detrimental. You should also consider that HeliconTech has been doing this for a long time, so why re-invent the wheel when they have already invented it? We all know that Parallels wouldn?t be able to create a better extension, so let?s not ask them to do this, okay?

It seems that your problem is the cost, which is understandable. If that case I would recommend that you stop using Windows and use Linux instead…
 
Will, it is apparent to me that maybe you don't understand English very well. If you did, you might have noticed that this is the WINDOWS support forum. Providing Linux solutions here is all but useless. Sure, there are "ways" to make them work, but they're absolutely unnecessary given that native solutions already exist.

There's literally no way you could help me with this: it was NEVER my problem. The price was never a problem with me, either, since obviously I didn't ask the question, I provided options to the OP (Original Poster) that weren't going to affect performance on his machine or cost him UNNECESSARY money.

I'm sure you feel you're doing someone a favor here by arguing with me about whether an ISAPI extension would be a better simple redirection solution to any of the native methods offered under Windows. You're not. In fact, you're wasting your own time and mine. And chances are you would have ended up costing the OP money and server performance.

It seems that your problem is the language. Good luck with that.
 
I'll call you Hal since I don't know your real name but thank you for using my real name.

Wasting time? I don't think so. The choice to reply is up to you. If you don't want your time wasted, then don't reply. Just ignore me. Trust me, it has worked for a lot of other folks.

I understood the question correctly. This is a Windows support forum and I've posted a link to a product that runs only in Windows, not Linux. I'm merely stating that nearly all products in Windows will be licensed, requiring you to pay for it. That includes Plesk, ISAPI_rewrite 3, etc.

I'm not really arguing with you since I don't know you and I certainly don't have the desire to argue with you. I may debate a point but I that's far from arguing. If you want to argue with someone, do it with your significant other, pending that you have one. My posts aren't to single you out and you're absolutely right, I'm not going to win any brownie points with you. If you don't want to use isapi_rewrite, then don't. But please, don't tell me to stop posting.

It seems that your problem is that you take replies too personally. Besides this a forum and in an effort to keep this thread in the classic forum context, everyone is entitled to their own opinion, no matter how backwards it may sound to you. Good luck with that, okay?
 
Back
Top