Hello, I was trying the global redirect module because I need to avoid duplicated content (SEO guys suggested that all node/123 should make a 301 redirect to /a-seo-friendly-url) but noticed it doesn't work for anonymous users.

I think the problem may be related to the drupal_get_path_alias function somehow.

I've noticed this behavior on Drupal 5 and haven't tried on Drupal 6.

Am I missing something here? Is drupal_get_path_alias useful just for authenticated users or is this something related just to global_redirect module?

Thanks!

Comments

dave reid’s picture

It should be working just fine. Can you provide more details on your module configuration and how exactly to reproduce the problem?

dave reid’s picture

Priority: Critical » Normal
Status: Active » Postponed (maintainer needs more info)
alexis’s picture

Status: Postponed (maintainer needs more info) » Fixed

Hi, I found my problem. I'm using Boost and pages like /node/123 were being cached so the rewrite rules on .htaccess were working before the request hit Drupal and global redirect had no chance to do its magic.

I fixed by adding this condition in the Boost rewrite rules on .htaccess:

RewriteCond %{REQUEST_URI} !^/node

This has to be added for the three rewrite rules between the lines commented as BOOST START and BOOST END on .htaccess.

Regards!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

plan9’s picture

Thanks for the tip Alexis!