Rank: Member
Joined: 2/26/2007(UTC) Posts: 57
|
How do I add "no follow" to links like customer service and search?
|
|
|
|
Rank: Member
Joined: 2/3/2007(UTC) Posts: 100
|
Ahh... you are learning pretty fast :-)
Example: <a rel="nofollow" href="http://www.mysite.com/Search.aspx">Search</a>
That will stop PageRank flowing into general links like Contact Us or Customer Service. A good idea to prevent PageRank being wasted on unimportant links. That will help PR being shared more equally towards your content pages. Good point.
|
|
|
|
Rank: Member
Joined: 6/6/2005(UTC) Posts: 483
|
I've often wondered about that.
Not a programmer here, so specifically where do you put the code? I'm I'm primarily interested in Your Account, Customer Service and Search.
Bob Noble
|
|
|
|
Rank: Member
Joined: 2/26/2007(UTC) Posts: 57
|
I am seasoned in html and java but not completely in asp.net yet. I know what html to use just not sure what files to place it in and where in those files. Can you help me out Omer? I would like to no follow my search page, contact us, myaccount_orders/login, privacy policy, terms, faq, affiliate program and return request.
|
|
|
|
Rank: Member
Joined: 4/28/2003(UTC) Posts: 141
|
I don't really know about asp.net and links, but you can just about any indexing in a robots.txt file as listed below User-agent: * Disallow: /Search.aspx Disallow: /ContactUs.aspx and so on The Robot.txt needs to reside in the root of your directory You can find more about it here http://www.javascriptkit.com/howto/robots.shtmlRichard www.somethingmorestore.com
|
|
|
|
Rank: Member
Joined: 2/3/2007(UTC) Posts: 100
|
Placing links in Robots.txt will not stop the PageRank flowing to those pages.
Sure jvmaloley. I didnt visit your site but I can tell you how it is done. Very easy. Look at all the links that are not important on your page. Those links are most of the time placed in Footer and Header. Here is a simple list: Contact Us / FAQ's / Shipping Policy / Order Tracking / Privacy Policy / Search / Terms of Use / Customer Service / Your account / Sign In.... you can also consider some other pages depending on your site content and internal navigation.
One you determine all of them, then first you will need to either modify your Header.ascx.vb or Footer.ascx.vb files. BV comes with ready linking from those pages to search, contact us etc. Just remove the ones pointing to pages like contact us, your account etc...
Then just write the links' codes including 'nofollow' like the following: <a rel="nofollow" href="http://www.mysite.com/ContactUs.aspx">Contact Us</a> | <a rel="nofollow" href="http://www.mysite.com/Terms.aspx">Terms of Use</a>.... etc.
You probably also know how to do the same with <ul><li>...etc All depends how you want to place the links.
Google PR computations are very frequent. Google bar wont show it but they internally calculate PR often. So you should see the results within like 2-3 weeks. Some of your MAIN content pages will start getting ranked better. I am looking at most sites and I see potential 1st page rankings but since their internal navigation is poorly desıgned, their rankings are also not as they should be.
|
|
|
|
Rank: Member
Joined: 2/3/2007(UTC) Posts: 100
|
Bob, If you do not know coding, I do not suggest you make any modifications directly on your site. Try it first on your local server, then upload the files if working. The code is simply rel="nofollow". It is added to any link that you do not want the PR to flow into. This came up for basically to stop spamming in blogs' comments. People overused it of course to get more inbound links to their external pages. So Google thought that it is appropriate for the blogs to use this rel="nofollow". But you can also use it in your internal site navigation where you do not want some unimportant pages to use up your PageRank like Contact Us or PrivacyPolicy etc... If you look at my above post, you will see how it is used. It makes a difference and you start seeing the difference if you also have good internal navigation. Hope this information helps.
|
|
|
|
Rank: Member
Joined: 2/26/2007(UTC) Posts: 57
|
Omer,
the current link looks like this
<li> <asp:HyperLink ID="lnkContactUs" runat="server" NavigateUrl="~/ContactUs.aspx" /> | </li>
so my links should look like this?
<li> <asp:HyperLink ID="lnkContactUs" runat="server" NavigateUrl="<a rel="nofollow" href="http://www.mysite.com/ContactUs.aspx">Contact Us</a>" /> | </li>
Could you post what the code looks like in your header and or footer?
|
|
|
|
Rank: Member
Joined: 2/3/2007(UTC) Posts: 100
|
No. You need to modify the Header.ascx.vb file first and remove the coding there. You can't add that code there. Probably it wil give an error message. See it already starts with <asp:Hyperlink.... you can't add another '<a...>link</a>' within that code. Try adding just rel="nofollow" right before the NavigateURL or right after '<asp:Hyperlink'. See if it works. I didn't try before so I don't know if it will.
BV comes with a header somethink like that:
Imports BVSoftware.Bvc5.Core
Partial Class BVModules_Themes_Print_Book_Header Inherits System.Web.UI.UserControl
Protected Sub Page_Init(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Init Me.Page.ClientScript.RegisterClientScriptInclude("bvsoftwareclient", Me.Page.ResolveUrl(PersonalizationServices.GetPersonalizedThemeVirtualPath & "scripts/theme.js")) End Sub
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load If Not Page.IsPostBack Then
lnkStoreName.Text = WebAppSettings.SiteName lnkStoreName.ToolTip = WebAppSettings.SiteName & " Home Page"
lnkHome.Text = Content.SiteTerms.GetTerm("Home") lnkHome.ToolTip = Content.SiteTerms.GetTerm("Home")
lnkMyAccount.Text = Content.SiteTerms.GetTerm("MyAccount") lnkMyAccount.ToolTip = Content.SiteTerms.GetTerm("MyAccount")
lnkContactUs.Text = Content.SiteTerms.GetTerm("CustomerService") lnkContactUs.ToolTip = Content.SiteTerms.GetTerm("CustomerService")
lnkSearch.Text = Content.SiteTerms.GetTerm("Search") lnkSearch.ToolTip = Content.SiteTerms.GetTerm("Search")
lnkCart.Text = Content.SiteTerms.GetTerm("ViewCart") lnkCart.ToolTip = Content.SiteTerms.GetTerm("ViewCart")
End If End Sub
End Class
I personally like to hand-code the links myself. So I modified the header.ascx.vb and removed all the 'Protected Sub'. I don not know if this is the correct way to do it but it is working :-) Then you can add nofollow as I showed above.
|
|
|
|
Rank: Member
Joined: 8/1/2007(UTC) Posts: 310
|
Guys, You dont need to edit a code behind (.aspx.vb) file for adding this attribute. Your existing link looks like this: <asp:HyperLink ID="lnkContactUs" runat="server" NavigateUrl="~/ContactUs.aspx" /> Change it to this: <asp:HyperLink ID="lnkContactUs" runat="server" NavigateUrl="~/ContactUs.aspx" rel="nofollow" /> You are not required to make any other changes to get it working. All you are doing here is to add an additional attribute. If you want to know how google interprets this attribute, please read: http://www.google.com/support/webmasters/bin/answer.py?hl=en&answer=96569 Thanks, Satya support @ bayquel.com |
Thanks, Satya support @ bayquel.net Work: +1 803 883 3226 |
|
|
|
Rank: Member
Joined: 2/26/2007(UTC) Posts: 57
|
Thanks for the help this is good stuff both ways work but Satya's seems to be the standard way of doing this.
|
|
|
|
Rank: Member
Joined: 2/26/2007(UTC) Posts: 57
|
How do I no follow Login.aspx? Here is my code but I can not see where there is a link for Login.aspx. When I look at my source code in the browser it shows my Login.aspx does not have the "no follow".
<%@ Control Language="VB" AutoEventWireup="false" CodeFile="Header.ascx.vb" Inherits="BVModules_Themes_Painted_Paper_Header" %> <%@ Register Src="~/BVModules/Controls/WaitingMessage.ascx" TagName="WaitingMessage" TagPrefix="uc4" %> <%@ Register Src="~/BVModules/Controls/CartTotals.ascx" TagName="CartTotals" TagPrefix="uc3" %> <%@ Register Src="~/BVModules/Controls/LoginMenu.ascx" TagName="LoginMenu" TagPrefix="uc2" %> <%@ Register Src="~/BVModules/Controls/MainMenu.ascx" TagName="MainMenu" TagPrefix="uc1" %> <div id="header"> <div id="brandingarea"> <h1> <asp:HyperLink ID="lnkStoreName" runat="server" Text="Print Book" NavigateUrl="http://www.myurl.com/" Style="text-decoration: none;"></asp:HyperLink></h1> <div id="headernavmenu"> <ul> <li> <asp:HyperLink ID="lnkHome" runat="server" NavigateUrl="http://www.myurl.com/" /> | </li> <li> <uc2:LoginMenu ID="LoginMenu1" ShowUserName="True" runat="server" /> | </li> <li> <asp:HyperLink ID="lnkMyAccount" runat="server" NavigateUrl="~/MyAccount_Orders.aspx" rel="nofollow" /> |</li> <li> <asp:HyperLink ID="lnkContactUs" runat="server" NavigateUrl="~/ContactUs.aspx" rel="nofollow" /> | </li> <li> <asp:HyperLink ID="lnkSearch" runat="server" NavigateUrl="~/Search.aspx" rel="nofollow" /> </li> </ul> </div> <div id="minicart"> <uc3:CartTotals ID="CartTotals1" runat="server" /> - <asp:HyperLink ID="lnkCart" runat="server" NavigateUrl="~/Cart.aspx" rel="nofollow" /> </div> </div> <div id="headermainmenu"> <uc1:MainMenu ID="MainMenu1" LinksPerRow="7" MaximumLinks="7" runat="server" /> </div> <uc4:WaitingMessage ID="WaitingMessage1" runat="server" /> <hr /> </div>
|
|
|
|
Rank: Member
Joined: 11/5/2003(UTC) Posts: 2,136
Was thanked: 1 time(s) in 1 post(s)
|
Originally Posted by: "jvmaloley" How do I no follow Login.aspx? Here is my code but I can not see where there is a link for Login.aspx.
There is no link to Login.aspx. The browser is redirected to Login.aspx when the server-based code determines that the client is not logged in. You can add a nofollow meta tag to the page (see the Google link that Satya quoted for details). Or you can use the robots.txt file. Note that robots.txt is "more standard" in that it has been around longer and is supported by more bots than the recently invented nofollow stuff. On the other hand, many people find the nofollow tags to be easier to implement and all the important bots support them. On the third hand, you can use both. |
|
|
|
|
Rank: Member
Joined: 2/26/2007(UTC) Posts: 57
|
My source code in browsers shows my Login.aspx as followable. How do I change this if there is not Login.aspx link in my header? Also the nofollow method is strictly for better distribution of Google PageRank throughout content. This way PageRank is not being wasted on pages that aren't content.
|
|
|
|
Rank: Member
Joined: 8/1/2007(UTC) Posts: 310
|
Andy is right to some extend. The web app automatically detects the user state and redirects to the login page when a user is trying to access member related pages.
However, to answer your questions, yes you can add a nofollow tag to the login/logout links. To do that, open up the LoginMenu.ascx.vb file located in BVModules\Controls\ folder. Locate the Page_Load. The content of this subroutine will be as follows:
[color=#ff0000>rel='nofollow'</FONT> href="""] Else s.Append("<a [color=#ff0000>rel='nofollow' [/color]href=""" & Page.ResolveUrl("~/logout.aspx") & """>") End If</FONT>
[color=#ff0000>rel='nofollow']href=""" & destination & """ TabIndex=""" & Me.TabIndex.ToString() & """>") Else s.Append("<a rel='nofollow' [/color]href=""" & destination & """>") End If s.Append("Sign In") s.Append("</a>") Me.litLogin.Text = s.ToString End If End Sub
You need to edit the Page_Load sub. I have already edited the Sub for you by adding rel='nofollow' <FONT color=#000000][2]attributes to the href element in the above code snippet. Please compare the source in your file with the source I pasted above. It should be the same if you have not customized anything. You should be able to take the above code and override your existing page_load sub. That should do what you want.[/2][/color]
Thanks,
Satya
support @ bayquel.com |
Thanks, Satya support @ bayquel.net Work: +1 803 883 3226 |
|
|
|
Rank: Member
Joined: 2/26/2007(UTC) Posts: 57
|
Thanks Satya! I noticed when you use rel="nofollow" and not rel='nofollow' you get a page load error why is this?
|
|
|
|
Rank: Member
Joined: 8/1/2007(UTC) Posts: 310
|
Thats because, you are writing this tag in code behind and not the aspx page. In code behind file you need to escape the double quotes. For now using single quote will work. Trust me on that.
Thanks,
Satya
support @ bayquel.com |
Thanks, Satya support @ bayquel.net Work: +1 803 883 3226 |
|
|
|
Rank: Member
Joined: 5/18/2005(UTC) Posts: 36
Thanks: 3 times
|
Ok I have a add on question for this. Unfortuantly this question is for BV2004, however it looks like posts/questions for those have been locked.
What I need to do is modify all catagory links in left the left col to included the code rel="nofollow"
I have added the following function to the catagorylist.ascx.vb file:
[2] Private[/2][2]Function[/2][2]ByVal[/2][2]As[/2][2]Integer[/2][2]ByVal[/2][2]As[/2][2]String[/2][2]ByVal[/2][2]As[/2][2]Integer[/2][2]ByVal[/2][2]As[/2][2]String[/2][2]ByVal[/2][2]As[/2][2]Integer[/2][2]ByVal[/2][2]As[/2][2]Boolean[/2][2]As[/2][2]String [/2][2]Dim[/2][2]As[/2][2]String[/2][2]If[/2][2]Then [/2][2]If[/2][2]Then [/2][2]Else [/2][2]End[/2][2]If [/2][2]Else [/2][2]End[/2][2]If [/2][2]If[/2][2]True[/2][2]Then [/2][2]End[/2][2]If [/2][2]Return[/2][2]End[/2][2]Function[/2]
[2]Then within the LoadCategories function[/2]
[2]I modified the following statment:[/2] [2][2] ' Other Category [/2][2]True[/2]However, after I rebuild the project the catagory links do not include the rel="nofollow" tag.
[color=#000000>Am]
<FONT size=2><FONT color=black>Anyhelp you can provide would be appreciated.[/color] [/2]</FONT>
|
|
|
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.