How to Remove redirection on magento site? - wordpress

There is a problem on my client site.Due to some of the redirections set up for magento.. I am not able to access the wordpress pages.. Whenever I try to access a wordpress page, I am redirected to a magento 404 not found page.... so please let me know how to remove redirection on my magento site??

Your question is ambiguous. Is it the rewriting in .htaccess (or somewhere else) doing the redirect, or do they have redirects in the core_url_rewrite table that conflicts?
I would guess the former. You need to create an alias or location for your Wordpress area that are distinctly different from your Magento area. Often this is accomplished through a separate subdomain, like http://blog.example.com/ or through a suffix like http://www.example.com/blog/.

Related

WordPress domain redirection

Beginner question:
I need to perform a 301 redirect from one Wordpress site (domain), to another Wordpress domain, like this:
From:
http://mycompany.com
To:
http://mycompany.se
A problem is that I have no FTP credentials for my From-site. I can't reach the .htaccess file.
Is there a plugin to use? I have studied the Redirection plugin, but this one seems working on pages within the same domain only(?)
I guess I need to be careful, because if some plugin edits the .htaccess file and something breaks, I can't reach the file...
Thankful for any help!
Whit Redirection Plugin you can redirect a url from old to new website.
You can create and manage redirects quickly and easily without needing Apache or Nginx knowledge. If your WordPress supports permalinks then you can use Redirection to redirect any URL.
There is full support for regular expressions so you can create redirect patterns to match any number of URLs.
The plugin can also be configured to monitor when post or page permalinks are changed and automatically create a redirect to the new URL.
You can easily find multiple plugins to perform 301 redirection in wordpress,but if you want to edit .htaccess you can install the plugin called "WP htaccess control" https://wordpress.org/plugins/wp-htaccess-control/ .
Through this plugin you can edit the .hraccess file from admin side.
Thanks.

Rewrite wordpress url to subdomain

i have a wordpress site let just call it testing.com
with a page url called blog/ which can access via testing.com/blog
i am using NGINX as the web server.
How do i rewrite the testing.com/blog to blog.testing.com with all its content still intact?
//edit
in this case, /blog is a page in the wordpress and not the wordpress itself, only that page and all the link inside the page would be rewrite to the subdomain and nothing else
example:
inside of the blog.testing.com there was 2 more link such as:
1. older post
(original link will be testing.com/blog/page/2 and change it to blog.testing.com/page/2)
1. read more on each post
(original link will be testing.com/2017/05/testpost1 and change it to blog.testing.com/2017/05/testpost1)
//end of edit
so as to say as if i am opening testing.com/blog in blog.testing.com
i have tried rewrite and proxy pass
location ^~ /blog/ {
rewrite ^/admin(.*) http://blog.testing.com$uri permanent;
}
with the above block
the result is same as return the url only and not with the supposed content.
or is it not possible to do so?
Hi assuming that you don't want to keep the URL testing.com/blog at all and instead want to use the subdomain blog.testing.com then effectively what you want to achieve is a WordPress migration. There are a number of ways you can achieve a migration, depending on how technically able you are. The easiest way is probably to install and use a WordPress migration plug in such as WordPress Duplicator or WordPress Move. Please take a backup of your files AND database before you start.
The official WordPress guide to migration can be found at https://codex.wordpress.org/Moving_WordPress
In short you would create the subdomain, then move (migrate) the site that's currently at testing.com/blog to the subdomain blog.testing.com
If the subdomain directory is to be left at /blog and you are just pointing the subdomain to that directory, then you might be able to do what you need to do just by updating the database to reset all the internal URLs in the WordPress database. In this case you could consider using https://interconnectit.com/products/search-and-replace-for-wordpress-databases/
This is what I tend to use when migrating sites from test to live. Hope this helps.

Drupal URLs migrated to new WordPress installation

We have an existing Drupal site. That is going to be replaced with a WordPress site on the existing URL. However, there has been a lot of SEO done on the drupal URLs so a google search will return those old URL's. We want to redirect to the new corresponding URL in the Wordpress site. However, since the drupal site is no longer live on the existing domain, the old URL's will just return 404 and cannot be redirected since they are not relative to the WordPress root. Is there a way to do this? Do I need to get those old drupal site URLs into WordPress somehow?
First of all you need to update your sitemap and add canonical's for permanent redirections. This wont directly redirect the page, but will let the search engines know that the url for the page has been changed and hence will avoid loosing your search engine rankings.
Then for actually redirecting the page you will need to update your htaccess
Redirect 301 /folder/oldpage http://www.example.org/newpage
If there are lots of pages you should consider using a wordpress plugin called redirection. This way you dont have to update the htaccess manually, and it will also keep logs of all the 404 pages that users have found, so you can also keep an eye on logs for any missing pages and redirect them accordingly.

How to modify .htaccess file to rewirite https to specific pages and directories for WordPress site?

None of the answers i searched on Google and this site give me the correct answer. It was either because it wasn't for WordPress based platform or it wasn't for pages permalinks.
Anyway, my site using permalinks to get better SEO performance over the regular page ID names. I have one specific page that i want to secure with HTTPS (SSL Socket), a directory under /wp-content/themes/my-theme (/wp-sec), and of course the /wp-admin directory/folder and /login.php page. All the other pages should be HTTP even if i will try to write the link as HTTPS.
The specific page ID is 3519 (/?page_id=3519) and it's permalink is "test".
PLEASE, if you don't know and you are not expert don't answer this question.
Thanks.

Rewrite Magento url to Wordpress page

I have a Magento site installed at the root of my domain and a Wordpress installed in a subdirectory. Currently I access my sites like this:
Magento: "domain.com"
Wordpress: "domain.com/blog"
I would like to be able to use Wordpress Pages seamlessly, without the "/blog" subdirectory showing in the url, such as:
Wordpress Page-X: "domain.com/page-x"
Note that I do want to keep the "/blog" subdirectory showing normally for blog posts etc... I just don't want it for Wordpress Pages.
Could anybody help on how to set that up? I was think tweaking the .htaccess would've work, but I can't find out how. Other solutions are welcome too. Thank you.
Magento provides you with an option to create custom URL rewrites in the backend (admin) you can find it here. This way you should be able to create rewrites. Also if you want to automate the creation of rewrites you can refer to the core_rewrites table in magento's database. Also this is a good read if you want to do logic based rewrites on the fly.

Resources