deleting 301 redirect

deleting 301 redirect

by Tina Smith -
Number of replies: 5

Let's see if I can explain this in a way that's not confusing...

So I have a Moodle install on a subdirectory of one domain (let's call that site 1). And another domain (let's call it site 2) that I was using for other purposes. Site 2 I had redirected to specific pages a wordpress install on the main directory of site 1 (long story, but it made the most sense at the time). 

Now I have decided to use the domain for site 2 for a new purpose that involves the Moodle install on site 1. So I want to move the Moodle install from site 1 to site 2's domain and stop redirecting site 2 to site 1 and have it back to it's own space.

I already deleted the 301 redirect for site 2 to site 1 on my cpanel. But it's still redirecting.

So at this point I'm unable to do anything on site 2's actual location until I figure out how to get it to stop redirecting.

In hindsight, I do realize that I should have done a temporary redirect, not a permanent. But at the time, I didn't know I'd be coming up with this idea. I thought it WOULD be permanent.


SO, my question is....HOW do you permanently CHANGE a 301 redirect to get it to STOP redirecting so I can install Moodle again in the new location??

Average of ratings: -
In reply to Tina Smith

Re: deleting 301 redirect

by Ken Task -
Picture of Particularly helpful Moodlers
In reply to Ken Task

Re: deleting 301 redirect

by Tina Smith -

I'm not sure what this link is for?

In reply to Tina Smith

Re: deleting 301 redirect

by Ken Task -
Picture of Particularly helpful Moodlers

Couldn't tell what your problem was ... hard to follow what you did, but don't think it's a moodle problem, is it?  It's getting to a place to install a moodle after you did some server re-config using cpanel and redirects (that much I think I understood).

Thought I'd try to help ... couldn't give you specific directions cause I couldn't really understand what you did.   Besides, and again, cpanel ... not Moodle.

So the first link was to google ...
Search term: "cpanel redirect not working"
Maybe one of those links could help you.

The second link:
https://www.site24x7.com/tools/redirection-checker.html
A redirection checker.
You put in domain name (e.g. your server URL) and choose a user agent ... like Chrome, Firefox
It outputs header details (responses) from server you pointed it to - e.g. your server.  Might provide a hint or clue as to where to look in your cpanel/web service config.

Thought maybe either or both might help.  If not, sorry 'bout' that!  Minus 1 for trying.

Best of luck!

'spirit of sharing', Ken

In reply to Ken Task

Re: deleting 301 redirect

by Tina Smith -

Perhaps not Moodle...I wasn't really sure WHAT the issue is. It's a redirect issue. I deleted a redirect but google is still redirecting. Perhaps I'll try the google help forums. I just wasn't really sure what the issue was or where to go...


Thanks anyway.

In reply to Tina Smith

Re: deleting 301 redirect

by Ken Task -
Picture of Particularly helpful Moodlers

Still uncertain but .... how about checking your servers logs - especially error logs after restarting apache ... assuming you are using apache as the web server.

One last try at some info: https://airbrake.io/blog/http-errors/301-moved-permanently

In the config files for apache (domains/sites in cPanel - I guess) look for a  'Rewrite' rule ... here's an example of one:

RewriteEngine on
RewriteCond %{HTTP_HOST} ^somehost.com
RewriteRule ^/(.*)$ http://www.somehost.com/$1 [L,R=301

Could also be in an .htaccess file

If one removed the above from config, apache service would have to be restarted for changes to take effect.

'spirit of sharing', Ken