I created a blog entry that is dated 2008-11-12 in the archives and the date line.

Pathauto gives it an alias of 2008/11/11/title.

This is likely because the server is in California and running Pacific Time internally. Needless to say, I'd like date URLs to go by the site's default timezone instead of the server's.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

cburschka’s picture

Project: Pathauto » Token
Version: 7.x-1.x-dev » 6.x-1.x-dev

Apologies, I forgot that pathauto uses token for this.

cburschka’s picture

Status: Active » Needs review
FileSize
2.1 KB

token.module does it correctly, using format_date instead of date. This adds the same for token_node.inc

greggles’s picture

Status: Needs review » Needs work

Where does the $tz variable get created?

Either I'm missing something when looking at the current code or this patch is missing something.

Also, I know it's more typing but $tz means a lot less to me than $time_zone. Drupal tends to prefer a more self-explanatory variable name.

Dave Reid’s picture

Status: Needs work » Closed (duplicate)

Marking this as a duplicate of #307520: Date formatting function which would solve this.