Domain redirect domain/domain - wordpress

i have a wordpress with multisite. I redirected my domain to my host and now, when i check my website, my urls are domain.com/domain.com/wp-contents/[...]
In my console, the same :
"NetworkError: 404 Not Found - http://example.com/example.com/wp-content/uploads/2017/08...
Here is my .htaccess :
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]
</IfModule>
# END WordPresshtaccess
I tried to remove htaccess. And i dont have access to wp-admin be cause always redirected.
Any idea ?

Solved, the problem was on database wp_1_options was "example.com" and i changed for "http://example.com".

Related

http:// redirect to http//

I got an issue with an unwanted redirection.
My Wordpress is redirect to http// instead of http://, the : are dissapearing.
Here is my .htaccess :
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]
</IfModule>
# END WordPress
If anyone have any clues on this, that would be great !
Edit : Ok, I got it, the Multisite functions of Wordpress was the problem. Just did a clean reinstall of the site and that's good.

cpanel can't visit temp url - redirects to http://www.ip/~user/

I'm new to VPS servers and just setting up a test environment to find my way around. I have WHM installed and have just created a new account with cpanel, I want to be able to visit the temp url, i.e. http://IP/~user however, when I visit, my browser adds a www. to the front (http://www.IP/~user/) which brings up a "page cannot be found" error.
Can anyone explain to me what is going on here and how I rectify it
Thanks
UPDATE: Here is my htaccess in the root of my public_html file (it's just a standard wordpress multisite htaccess)
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
# uploaded files
RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]
</IfModule>
You have to enable mod_userdir from WHM backend

Changed sub-site path and facing 404

I was running a multi-site on www.madeinindia.club i have made a sub-site with www.madeinindia.club/work-space and now i changed the path to www.madeinindia.club/karmabhoomi but it is not accessible now. both URL showing 404
Note: I have already changed the same URL one time but then the new url worked.
htaccess file
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
# uploaded files
RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]
Also posted on WordPress Developer

Wordpress Post Links With Wrong Day

I am having a strange issue with a new multi-site wordpress installation. This is installed on a Magento website.
I can see my blog and go into the admin area just fine. However, when I click on a post I get a 404 error. If I change the day in the url it will work.
Example: If the link takes me to mysite.com/dev/devsite/default/blog/2013/11/11/hello-world/ I get the 404. But, if I manually change the day in the url to mysite.com/dev/devsite/default/blog/2013/11/12/hello-world/ I can see the post.
Here is my .htaccess file that the multi-site wordpress told me to use.
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /dev/devsite/wordpress/
RewriteRule ^index\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]
</IfModule>
Any idea why this is?
I also have a WP MultiSite installation under my main website. Here's the .htaccess code used by my site.
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]
Try using this instead of your ones. There is a ending too in your code, I think you copied the code wrong way.

Prevent subpages from redirecting to the root URI

I'm having a minor but annoying issue with a site running WordPress 3.1.4 Multisite.
Navigating to the URI of a subpage without the "http://www" such as "abetterworldbydesign.com/2011-conference/" results in a redirect to the root "http://www.abetterworldbydesign.com".
The intent is for "abetterworldbydesign.com/2011-conference/" to redirect to "http://www.abetterworldbydesign.com/2011-conference/".
.htaccess file below (it's specific stuff for WordPress Multisite).
# BEGIN WordPress
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
# uploaded files
RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^[_0-9a-zA-Z-]+/(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^[_0-9a-zA-Z-]+/(.*\.php)$ $1 [L]
RewriteRule . index.php [L]
# END WordPress
Try adding this
RewriteCond %{HTTP_HOST} ^abetterworldbydesign.com
RewriteRule ^(.*)$ http://www.abetterworldbydesign.com/$1 [R=301,L]
at the very top, just after RewriteEngine On.

Resources