Hi there,

Just wondering how much work would be involved in cleaning up the URL structure when using the paging module? The clean URL feature of Drupal was one of the biggest drawcards for me, and using the path and pathauto modules I am able to automatically generate the URL exactly as I want, such as;

http://mydomain.com/articles/multi_page_article

However, when I start browsing the pages of an article the URL becomes a bit untidy, looking like;

http://mydomain.com/articles/multi_page_article?page=0%2C1

Would it be possible to get it to follow the same URL structure as when viewing comments, such as;

http://mydomain.com/articles/multi_page_article#page_1

Or even something like;

http://mydomain.com/articles/multi_page_article/page_1

What do you think? Good idea? Bad idea? Impossible?

Comments

alliax’s picture

nice request

slayerment’s picture

I think that would be awesome to have something like that.

merlinofchaos’s picture

Status: Active » Closed (won't fix)

Because we're using the built in Drupal pager, this isn't really possible at this time without foregoing that system.

brashquido’s picture

Ok, I've posted this as a feature request in the pathauto module.

merlinofchaos’s picture

Sorry but pathauto won't be able to do it either.

brashquido’s picture

That's very disappointing then. So you are saying there is no way of implementing clean URL's for multipage articles (even when using URL aliases) without developing a paging system that does not use Drupal's native paging system?

merlinofchaos’s picture

Well, you could always make multiple nodes that link to each other (like book module).

brashquido’s picture

The book module does not really give the effect/structure I am after.

Just looking at the URL structure again, and just seeing some differences and was wondering why. When paging the main page of Drupal the URL looks like this;
/node?page=2

However, when paging an node using the Paging Module the URL looks like this;
/multipage_article?page=0%2C2

The status bar in Firefox shows the URI stem as being;
/multipage_article?page=0,2

So I assume %2C is unicode for the comma symbol. Is there anyway of removing the 0, from the string so that it does not mess up the URL?

merlinofchaos’s picture

The 0, is necessary because comments use the first pager, so paging *has* to use the second one.

merlinofchaos’s picture

chx pointed out elsewhere that one could do some RewriteURL magic using apache and transform the URLs.

brashquido’s picture

Ok, I'll see about doing this with a rewrite rule rather than in Drupal itself.

Success’s picture

Any update to this?

xano’s picture

Version: 4.7.x-1.x-dev » 5.x-1.x-dev
Priority: Normal » Critical
Status: Closed (won't fix) » Postponed (maintainer needs more info)

The best way on doing this would be creating URLs like /article/1/ with '/article/' being the node URL and '1/' being the page. Let's start easy: You need your function to check the last URL argument ('1' in this case) and load the proper page. There are hardly any problems in this part, but here they come: What if you got a node with an URL ending with a number, like /1/? This page is just called '1'. Page one would be located ad /1/1/ (and /1/ as well) and page two at /1/2/. Now the problem is to see whether the last argument does or does not indicate the page number.

If anyone could tell me how to do this I wouldn't mind writing some code to fix this.

This is a rather critical feature in the eye of SEO and usability so I changed the Priority.

merlinofchaos’s picture

Status: Postponed (maintainer needs more info) » Closed (won't fix)

Xano: Read the damn issue. There is a completely valid reason this was won't fixed. Unless you address that reason, you're just being a menace.

kalashari’s picture

I don't understand... Nothing can be done to fix URLs appearing like /multipage_article?page=0%2C2 ????

I mean who wants to use URLs like that on his website?

darren oh’s picture

Just means the module maintainers won't work on this. Any one who comes up with a solution should share it here.

kalashari’s picture

ok... btw if I leave these URLs like this, are they crawled by SEs properly or no?

kalashari’s picture

anybody knows if the URLs like this are crawled by search engines?

darren oh’s picture

I believe XML Sitemap users have successfully submitted URLs like this to Google.

Zoologico’s picture

You guys should try Clean Pagination module:

http://drupal.org/project/cleanpager

I use it for my multipage Views.

Gurpartap Singh’s picture

Version: 5.x-1.x-dev » 6.x-1.0-beta2

Clean pager for paging: http://myzonelabs.com/node/19

:-)

I hope we can move node paging support into cleanpager itself. Tested with 6.x-1.x-dev.

clevy’s picture

This issue is addressed in this thread with some possible solutions:

http://groups.drupal.org/node/3472

moneesh.koundal’s picture

If anyone have used cleanpage module in drupal 5 for clean page url. I have checked that cleanpager module in available in drupal 6 and development version of the module is not working.

I have also checked that module does not support url aliasing links for clean pagination url. Is there is any other solution for this.