Where should the link on the company's logo go? [closed] - hyperlink

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
I'm wondering if the link on the company logo, which usually goes the home page, should be:
http://www.example.com
http://www.example.com/index.html (or other index file)
/index.html (or other index file)
/ (just the root)
Does Google care or are there other rules?

A or D.
Hard coding the full path in removes flexibility - let the web server or the app config handle what the default is.
(iirc google doesn't care any more than it would for any other link)

Well, I would imagine that for simplicity's sake, it should just go to http://www.example.com. including index.html would make it dependant on the implementation of the home page being in index.html, which may not always be the case. Also, if you go off to some subdomain, you probably don't want to be redirected to the subdomain's homepage when clicking on the company logo, which as far as I've ever encountered, should always take you back to the main company home page.

In my humblest of opinions and giving credit to my understanding to TBL, the URL should be identifying a resource and not so much the technical means by which it is generated: so I would argue against including 'index.html' in the link. After all, you're trying to point to the site at that address, and the fact that it's currently HTML (or that DirectoryIndex is set to 'index' on the apache server) is an implementation detail.
That leaves http://example.com and / to consider. I'm somewhat indifferent between the two. Is it possible the domain name where the current content is being served from will change? If it does, do I want to link to example.com or to the current domain? That's what I would be thinking about in deciding between the two.

If you're really trying to achieve proper SEO, I would think that you would rather have a logo or banner (something that's on every page to identify the website, not the page) be set as the background of a div instead of using <img>. I usually reserve <img> for images particular to the content on a specific page. This allows you to set the alt attribute as well which helps with SEO. As for the link, it really shouldn't matter to Google. I'm sure they've handled this on their end.

ok simply put
a never link to http://www.example.com/index.html
as later you might use http://www.example.com/index.php if you change hosting or site design
equally never link to http://www.example.com as this is not a url and your browser must repair it
when linking from other company sites via logo link to http://www.example.com/
note the / as this is the actual url for {default page in first folder}
or internally on same site just link to "/" as this also means {default page in first folder on this site} which will keep your links working if company name changes
also ensure that http://example.com/ 301 redirects to http://www.example.com/
{and dosn't server identical content}
and if many links are already to http://www.example.com/index.html
first fix all you can
second move index.html to index.htm
then 301 redirect /index.html to http://www.example.com/
thus ensuring everyone eventually notices the http://www.example.com/index.html is gone
without loosing hits or PR

I would and do go to /
My PHP/xHTML looks like this
Home

Relative URLs (C and D) would be resolved by clients (Google included) to absolute URLs (to B and A respectively) and therefore treated the same as their absolute counterparts. If your A permanently redirects to B, or B to A, then Google will also treat this as one resource. Google will score A+B+C+D as one page.
Whichever one URL the others eventually resolve or redirect to will be considered the 'canonical' URL.
The words contained in your canonical URL are important. As in the URLs of questions here on stackoverflow, the words should relate to the content. Therefore what you need to decide is whether or not you want the words 'index' and 'html' in the URL. I believe best practice for home pages is to have http://www.example.com/index.html permanently redirect to http://www.example.com/ .
Of course, content is still king, and all of this is just minor tweaking compared to adding quality content.

I think you should set it to ~/
IIS / ASP.NET will translate that to your root automatically.
i.e. http://www.example.com
This is perfect for testing locally too. On your local machine it will point to http://127.0.0.1/whateverYourPathIs, and when its deployed live, it will correctly point to http://www.example.com

Related

Remove multiple indexed URLs (duplicates) with redirect

I am managing a website that has only about 20-50 pages (articles, links and etc.). Somehow, Google indexed over 1000 links (duplicates, same page with different string in the URL). I found that those links contain ?date= in url. I already blocked by writing Disallow: *date* in robots.txt, made an XML map (which I did not had before) placed it into root folder and imported to Google Webmaster Tools. But the problem still stays: links are (and probably will be) in search results. I would easily remove URLs in GWT, but they can only remove one link at the time, and removing >1000 one by one is not an option.
The question: Is it possible to make dynamic 301 redirects from every page that contains $date= in url to the original one, and how? I am thinking that Google will re-index those pages, redirect to original ones, and delete those numerous pages from search results.
Example:
bad page: www.website.com/article?date=1961-11-1 and n same pages with different "date"
good page: www.website.com/article
automatically redirect all bad pages to good ones.
I have spent whole work day trying to solve this problem, would be nice to get some support. Thank you!
P.S. As far as I think this coding question is the right one to ask in stackoverflow, but if I am wrong (forgive me) redirect me to right place where I can ask this one.
You're looking for the canonical link element, that's the way Google suggests to solve this problem (here's the Webmasters help page about it), and it's used by most if not all search engines. When you place an element like
<link rel='canonical' href='http://www.website.com/article'>
in the header of the page, the URI in the href attribute will be considered the 'canonical' version of the page, the one to be indexed and so on.
For the record: if the duplicate content is not a html page (say, it's a dynamically generated image), and supposing you're using Apache, you can use .htaccess to redirect to the canonical version. Unfortunately the Redirect and RedirectMatch directives don't handle query strings (they're strictly for URIs), but you could use mod_rewrite to strip parts of the query string. See, for example, this answer for a way to do it.

Hide website filenames in URL

I would like to hide the webpage name in the url and only display either the domain name or parts of it.
For example:
I have a website called "MyWebSite". The url is: localhost:8080/mywebsite/welcome.xhtml. I would like to display only the "localhost:8080/mywebsite/".
However if the page is at, for example, localhost:8080/mywebsite/restricted/restricted.xhtml then I would like to display localhost:8080/mywebsite/restricted/.
I believe this can be done in the web.xml file.
I believe that you want URL rewriting. Check out this link: http://en.wikipedia.org/wiki/Rewrite_engine - there are many approaches to URL rewriting, you need to decide what is appropriate for you. Some of the approaches do make use of the web.config file.
You can do this in several ways. The one I see most is to have a "front door" called a rewrite engine that parses the URL dynamically to internally redirect the request, without exposing details about how that might happen as you would see if you used simple query strings, etc. This allows the URL you specify to be digested into a request for a master page with specific content, instead of just looking up a physical page at that location to serve.
The StackExchange sites do this so that you can link to a question in a semi-permanent fashion (and thus can use search engines with crawlers that log these URLs) without them having to have a real page in the file system for every question that's ever been asked (we're up to 9,387,788 questions as of this one).

How to improve the structure of URLs

From the article at google's webmaster center and SEO's pdf, I think I should improve my website's URLs structure.
Now the news url looks like "news.php?id=127591". I need to rewrite it to something like "/news/127591/this-is-article-subject"
The problem is if I change the structure of url to the new one. Can I still keep the old one working? If both url working, how to avoid search engine like google and bing to search twice times for one article?
Thanks!
HTTP 301 permanent redirect from the old URL to the new URL
an HTTP 301 redirect has the property of communicate a new (permanent) URL for an old (outdated) ressource to google (and other clients). google will transfer most/all of the allocated value from the old URL to the new URL.
Also, in order to improve the arquitecture of your website, you must keep a clean structure by inserting links within all its pages/posts. But be careful, you must not do this lightly, or Google´s robot will get confused and leave.
Structure is key to your SEO
1. Find one page which is the "really important page" for any given keyword
2. direct relevant content from other pages which is relevant to that particular kw
3. repeat with every relevan kw
I´m gonna leave this post for you, where I explain this more in depth, hoping that you understand spanish. http://coach2coach.es/la-estructura-web-es-la-base-del-posicionamiento/
Yep.. you can use robots.txt to exclude news.php, and create an xml sitemap with the new URLs. mod_rewrite can be set to only change directories, with trailing slashes.. so all files in your root directory should work fine.

How to handle existing indexed Mixed Case url's? [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 11 years ago.
Improve this question
I have an asp.net web forms application that has been live for a number of years and as such has quite a lot of indexed content on google.
Ideally, I'd prefer that all Url's for the website are in lowercase but I understand that having 2 versions of the same content indexed in search engines (MixedCase.aspx and mixedcase.aspx) will be bad for seo.
I was wondering:
a) Should I just leave everything in its current Mixed Case form and never change it?
OR
b) I can change the code so everything is in lowercase from here on in, BUT, is there a way of doing this so as the search engines are aware of this change and don't penalise me?
Having two versions of the same URL will cause duplicate content issues, although the search engines are generally smart enough to know that the two pages are the same.
There are two good solutions. The first is to use the canonical meta tag to specify your preferred version of the URL. With this solution, both MixedCase.aspx and mixedcase.aspx would show the same page, but the search engines know for definite which is the "correct" URL to show. Make sure you update all your links to the lowercase version.
The second solution is to use 301 Redirects. Usually this is preferred because users will always wind up at the correct page. If they decide to link to it, they're using the correct version. As Rocky says, the redirects will need to stay in place permanently if you already have links from other sites. However, technical (or time) limitations may mean you need to use the canonical method.
You are wise to be wary of having two URLs serving the same content, as you will experience duplicate content issues from the search engines.
You can transfer your URLs, and their PR, from mixed case to lower case without too much of an issue by providing a 301 response code on the old mixed case URLs to the new lower case URLs.
So you would essentially have two URLs for every page:
Old mixed case URL which 301 redirects to the lower case URL
New lower case URL which serves the content
You will need to keep the old URLs in effect for a long time, possibly permanently (e.g. especially if there are third party links to them). Having done this myself, the search engines will continue to request the old URLs for years, even when they know that they redirect to the new URLs (Yahoo, in particular, was guilty of this).
force lowercase, redirect all mixed case URLs HTTP 301 to the lowercase version.

SEO help for replacing a website

I run a small e-commerce site that over the last few years has built up a reasonable search engine status.
I've been working on a new site that uses new URL formats and I am worried about how to deal with all the broken links and customer frustration for users finding out dated links through search engines.
Can anyone offer advice on how to mitigate / minimize the damage? The old site was done in ASP.NET the new in ASP.NET MVC
Thanks for any help you can be.
You will need some sort of parallel structure. Ideally, the old site with the old URLs remains fully accessible for some time, but does not get indexed any more.
If that's not feasible, and since you are saying that the site is small, you could establish a URL mapping old-new and have a 404 handler that attempts to redirect to the new content.
You should create permanent redirects for the links you want to preserve (routelevel). This way searchengines will update their references to the new locations.
As cdonner says, you want to have a handler that reroutes the traffic to its appropriate destination. Even more important though, is you want to make sure when you redirect the client, you send a status code of 301 (permanently moved) instead of 404. The search engines will rate you negatively if there are a lot of 404 errors on your site and you will see your standing decrease instead of increase.
You could set up your old site's .htaccess file to redirect traffic to the new site. Beyond that, you could use mod_rewrite to map requests to pages on the old site to the same (or similar) pages on the new one.
This is the way I do it migrating from an old ASP classic site:
Sub Application_BeginRequest(ByVal sender As Object, ByVal e As System.EventArgs)
Dim fullOriginalpath As String = Request.Url.ToString.ToLower
If (fullOriginalpath.Contains("/viewitem.asp?itemid=")) Then
Context.Response.StatusCode = 301
Context.Response.Redirect("/item/" + getItemIDFromPath(fullOriginalpath))
ElseIf (fullOriginalpath.Contains("/search.asp")) Then
Context.Response.StatusCode = 301
Context.Response.Redirect("/search/")
ElseIf (fullOriginalpath.EndsWith("/default.asp")) Then
Context.Response.StatusCode = 301
Context.Response.Redirect("/")
End If
End Sub
Sounds like you have it figured out, but just wanted to add one more option - the canonical tag - which may have advantages if for any reason you needed to keep both the old url and the new URL active. You can create a copy of the page at the old URL and then add the "canonical" tag, which tells the search engines "please credit the link credits of this page to the following page: www.site.com/newpage"
<link rel="canonical" href="http://www.yoursite.com" /> this line goes in before </head>
For example if you have lots of links to certain key pages and those links are pointed to the old URL's, this may be a help.
A 301 also redirects the link credits, and generally moved pages you'll want to use a 301 redirect. Oh and if you use a URL rewrite rule and all the URL's change in the same way, you can probably use regex in the rewrite rule to handle all of them in a single step.

Resources