New answers tagged redirects
2
You can use the .htaccess file to redirect from IP to domain using this code:
Options +FollowSymLinks
RewriteEngine on
RewriteCond %{HTTP_HOST} ^555\.555\.555\.555
RewriteRule (.*) http://www.example.com/$1 [R=301,L]
Change 555.555.555.555 to match the IP of your server, additionally though you can use canonical urls that will prevent duplicates entering ...
0
In answer to your last question, Google does say
Websites that provide content for different regions and in different
languages sometimes create content that is the same or similar
but available on different URLs. This is generally not a problem as
long as the content is for different users in different countries.
While we strongly recommend ...
0
Google sites has a help document that answers this question for you.
The basic steps are:
Tell Google Sites about your domain name. There are a different set of instructions for this depending on your sites is powered by Google Apps or not.
Use your domain registrar or DNS host to set a CNAME record pointing to ghs.google.com. The ability to do this is ...
0
Ok, I finally got this to work (sort of). Here's my final code
RewriteCond %{REMOTE_ADDR} !=123.456.789.0
RewriteRule ^secretdir- [F]
I removed the escaping of the periods, and now it seems to work with my external IP address. I'm not sure if that's what is actually causing the problem, but now it works.
I say that it sort of works because (1) it's not ...
2
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
Should do the trick.
0
You don't need your main keyword in your domain to rank for well it, and the gains form having it there are minimal, and arguably could be bad after Googles Exact Match Domain update:
Minor weather report: small upcoming Google algo change will reduce
low-quality
"exact-match" domains in search results.— Matt Cutts (@mattcutts)
With this in ...
1
I think it's a bad idea to try to insert a keyword inside your domain name. It appears spammy. Domain name like companyname.com is the best choice. Think about big corporations like Google, Facebook and so on, do you see domain name like search-engine-google.com or social-network-facebook.com? Of course not, only the brand for the domain name.
Moreover, you ...
0
You need to add conditions to your match, like this:
RewriteCond %{REMOTE_ADDR} !=123\.123\.123\.123 [OR]
RewriteCond %{REMOTE_ADDR} !=123\.123\.123\.124
RedirectMatch 302 ^/mydir/.*$ http://mysite.org/myotherdir
Obviously, replace the 123 stuff with the actual IP addresses in question, remembering to escape the dots, as shown.
0
I would mix the two answers above
1. you HAVE to set properly the website URL So that the CMS always prints the correct address
2. you can set a proper rewrite rule so that in case someone links the wrong url [without www] you don't end up with google indexing all pages twice penalizing the SEO ranking
0
Altering the .htaccess shouldn't be necessary. You should only need to change the website URL under Settings -> General in the WP Admin to include the www.
If you try John's answer and you have the website URL in WP settings set to the non-www version, you will create a redirect loop.
WordPress 3.5
0
You are correct but also incorrect at the same time.
Hotlinking
If people are hotlinking to the file, i.e not visiting your site first then the GA will not be loaded therefor it will not be tracked.
Page Visit Downloads
If they visit your page and then click a download button for example this event will be tracked no problem regardless if it includes an ...
1
When using international characters in your URLs there are a few issues to be aware of:
Percent URL encoding requires a character set. To display the URL correctly in the web browser, you should use "UTF-8" character set when percent URL encoding your slug. See: What is the proper way to URL encode Unicode characters?
If there are lots of encoded ...
0
A 301 Moved Permanently is used to mark a page as having moved permanently. It should not be used to pass data back and forth between servers or services.
0
I strongly recommend not to use these redirects just check the user is login or not. Let me explain what 301 redirect will do:
when you use 301 redirect from page1 to page2, search engine will pass all page authority, rankings, and backlinks value from page1 to page2. In this situation, page1 will loose its rankings and page2 will start gaining ranks as it ...
2
You'll want both in the root of the site, especially robots.txt because that's where Bot's will be looking for it. The Sitemap could go anywhere, but it would make the most sense in your case to put it in the root, rather than having several sitemaps for each additional language you add in the future.
Top 50 recent answers are included



