Join our DNN Community    (Newsletter, Tips, Tricks and Forums for DNN Skins & Modules)

 


 
Microsoft Gold Certified Partner - DNN Benefactor

DotNetNuke Powered! 


Thursday, August 28, 2008 Register · Login · Contact · Search:  
Company Solutions Portfolio Contact
Forums
General
The ever-powerful ListX module forum. Post your questions, new configuration ideas and reviews.
Subject: ListX paging vs Google?

You are not authorized to post a reply.   
Author Messages
DavidWSnow
Cruiserweight
Posts:122

06/30/2008 1:47 PM Alert 
I use a ListX table as part of a site map to tell Google about the web sites associated with Aging Safely. This is working well. However, Google has some strange limits (9) of external links on a page before they drastically discount the "value" of those links to the receiving sites.

Since I don't expect "real people" to be looking at this table I don't care much what it looks like. I though that an easy solution might be to enable paging and set the limit to 9. This worked EXCEPT that the links are "javascript do_postback" functions and would not be followed by Google.

Has anyone figured out an easy way create paging links that the true links that Google will follow?

Regards,

Dave Snow
alantan
Lightweight
Posts:16

07/05/2008 7:36 AM Alert 
This is something that I'm trying to achieve too. So far, the only solution I can seem to implement is using a "page" querystring:
1) Adapt the custom paging example query in the manual, replacing [PAGENUMBER] with @page (where @page is a variable set to [page,Q])
2) Produce the numeric links manually, adding the relevent querystring each time. For example, for next page, page={MATH,"[PAGENUMBER]+1"}
(don't forget to handle the first and last pages specifically).
HTH
DavidWSnow
Cruiserweight
Posts:122

07/05/2008 12:10 PM Alert 
Don't happen to have a work example, do you? ;=}

There always seems to be a whole lot more to discover when you slug thru this sort of coding.

/Dave

PS: Thanks for the idea.
alantan
Lightweight
Posts:16

07/05/2008 12:28 PM Alert 
Actually, I have nearly perfected it (well not perfect, but good enough for Google). I am just getting the "Next" and "Prev" links sorted out - as I am using friendly URLs and the querystring is optional, the relative links are a bit tricky to get right.

Hopefully I'll have something to post in the next hour or so.
DavidWSnow
Cruiserweight
Posts:122

07/05/2008 12:35 PM Alert 
Super -- I am amazed that more ListX uses don't seem to care about how their work interacts with Google. A lot of mine is internal and Google shouldn't be indexing it.

However, there always seems to be a ListX module to two that one really cares how Goggle indexes them and they really require some thought and lots more work that I wished to spend on them.

BTW I am told that Google discounts more than 9 external links on a page when distributing your pagerank to your external links. I already have a hundred, so I though that I should really drop this number down.
alantan
Lightweight
Posts:16

07/05/2008 1:50 PM Alert 
Agree with you entirely David. I am tearing my hair out, as Google only wants to index five of my pages. It took me a while to realise just how little of the site Lynx saw due to Ajax and JS. As my site has similarities to a directory (but it isn't - it's more of a review site), I am expecting Google to be a little difficult as it has been said on a number of blogs and sites that Google algorithms are slanted against directories...

Anyway, here is my solution. Rather than post an uncommented xml that even I find hard to follow, I'll break the solution into pieces:

<b>1) General Settings:</b>
- No Ajax
- No Javascript
- Use Custom Paging
- Don't show any of the paging options

<b>2) Variable:</b>
The variable is pretty straightforward:
Type - QueryString
Source - page
Target - @PageNumber
Empty Target - 1

<b>3) Query:</b>
Define the query based on the ListX documentation, but use the @PageNumber variable to define your current page number position. Before the query itself, gather the TOTAL number of results for the criteria into a @NumberOfResults variable, and output it with each record. This makes it easier to handle the test for the last page link.

For SQL server, you should end up with something like:

DECLARE @NumberOfResults int;
SELECT @NumberOfResults = count(*)
FROM myTable
WHERE myConditions;

WITH ordered AS
(
SELECT *,
@NumberOfResults AS TotalCount,
@PageNumber AS PageNo,
ROW_NUMBER() OVER (ORDER BY mySortOrder ASC) AS RowNumber
FROM myTable
WHERE myConditions
)
SELECT * FROM ordered
WHERE RowNumber BETWEEN ((@PageNumber-1) * [PAGESIZE]) + 1 and ( @PageNumber *

[PAGESIZE])

<b>4) Form:</b>
Now for the form. I initially tried placing the <noscript> and </noscript> in
the module header and footer, but this made all the page content vanish as the
</noscript> was not being rendered for some reason. Then I put them in the ListX
Header/Footer parts of the form, and saw that the page numbers were still showing
for javascript users as they are rendered below the module output. Just then, I
realised (as you did) that they are javascript anyway, so are useless for SEO
purposes. So this is what I did:

Header: Just place a <noscript> before the content.
Footer: After the content, place links for Prev and Next pages, followed by
</script>. My code is not particularly elegant, and relies on the MATH formatter
to calculate whether we're on the last page, but it seems to work:

{IIF,"[page,Q]>1","
<a href='[FORMAT,PortalSettings.ActiveTab.FullUrl,System,{REPLACE:.aspx,}]/page/
{MATH,"[page,Q]-1"}.aspx'>Prev</a>
",""}
{IIF,"[PageNo]<{MATH,"[TotalCount]/[PAGESIZE]"}","
<a href='[FORMAT,PortalSettings.ActiveTab.FullUrl,System,{REPLACE:.aspx,}]/page/
{MATH,"[PageNo]+1"}.aspx'>Next</a>
",""}

Bear in mind that my URL is friendly, so instead of obvious query strings, I have:
http://www.mydomain.com/path/pagename.aspx
http://www.mydomain.com/path/pagename/page/1.aspx
http://www.mydomain.com/path/pagename/page/2.aspx
etc... where /page/1 is instead of ?page=1

<b>The problems:</b>
There is still the issue of producing the internal links directly to the pages instead of Prev and Next. Not sure how many links Google will follow (as it may interpret multiple Next links as navigating down a tree).
You are not authorized to post a reply.
Forums > Bi4ce.Modules.ListX > General > ListX paging vs Google?



ActiveForums 3.6
 
Latest Post
 
At R2integrated (formerly Bi4ce), we take support seriously.  That's why we support our customers and DNN community with daily monitoring from our experienced engineering team.  We ask that the first step taken is to read the relevant documentation and support forums prior to submitting any questions that may already be available or have been answered.  We ask that you review the documentation that we provide for our products before posting a question.

The Forums are for our customers to chat, exchange ideas and strategies, and submit feedback.  Please be sure to perform keyword searches for previous related forum responses.

To be helpful when submitting a new item, please include the following: 
  1. DNN Version
  2. Module Version
  3. Admin Log Viewer Information
  4. Environment detail: Operating system, .NET framework version, database and version, IIS version, Browser version (if appropriate)
We always try to respond quickly and monitor the forums daily during business hours (EST).  Occasionally, requests for a specific project requirement may not apply for the free support offered. For project specific support please submit via our Information Request form.

Thank you for using our Forums.

Click here to register for the Forums
 
© 2008 by R2integrated (formerly Bi4ce) | DNN® is a registered trademark of DotNetNuke Corporation