Comments

dave reid’s picture

Status: Active » Needs review
StatusFileSize
new1.03 KB
dave reid’s picture

StatusFileSize
new1.03 KB
dave reid’s picture

Title: The [metatags-normal-url] and [metatags-url-alias] tokens are unnecessary » Cleanup token handling code
Assigned: Unassigned » dave reid
Issue tags: +token
StatusFileSize
new11.04 KB

Gah, there are additional of cleanups that were necessary with token handling code:
1. Not using the 'global' or 'node' token namespace complicates things unnecessarily.
2. The nodewords_replace_tokens() function that is called by every single meta tag processor still works even if the user has actually disabled the 'Enable tokens' option.

dave reid’s picture

StatusFileSize
new12.57 KB

Rerolled patch.

dave reid’s picture

StatusFileSize
new17.5 KB

One last effort. Noticed that we are using the fracking default meta tags on the front page by default. That is just wacky.

dave reid’s picture

Status: Needs review » Fixed

Alright, I feel really strongly about getting this in before 6.x-1.12 and I've tested this one extensively and fixes a few bugs, so I'm committing to CVS.
http://drupal.org/cvs?commit=444876

pfx’s picture

After updating to the latest development version from the previous I can not find the token [metatags-description] nor [metatags-description-raw] in the list of available tokens ?
In the previous development version these tokens were present and functioning properly ?
....
oops, excuse me, these tokens are absent from the list but their use for the description meta tag works!
sorry

dave reid’s picture

If you're using a fairly recent version you should find them under the 'Global' or 'Node' sections.

Only local images are allowed.

pfx’s picture

Yes I found the token [metatags-description] under 'Node' section when I edit a page from the tab 'Custom pages meta tags'.
However, this token [metatags-description] is absent from the list 'Replacement pattern' from the tab 'Default meta tags'.
thank you very much

dave reid’s picture

Why would you need a node-related token on the default meta tag page? Why not just edit the meta tags on the node itself?

dave reid’s picture

Oh wait, I see what you need. You want a default that applies to all nodes.

pfx’s picture

Yes exactly, I use the token [metatags-description] to automatically populate the meta tag 'Description' for each node.
Maybe it's not a very academic ... I do not know?
thanks

keva’s picture

Status: Fixed » Active

There are a whole lot of tokens that are not available with Nodewords 6.x-1.x-dev (2010-Nov-08).

In previous versions, there were tokens for [metatags-description] (very useful) and more: author, node, cck fields, vocab etc.

These are the only ones I currently have available:

[page-title] The page title.
[user-name] The name of the currently logged in user.
[user-id] The user ID of the currently logged in user.
[user-mail] The email address of the currently logged in user.
[site-url] The URL of the site's front page.
[site-name] The name of the site.
[site-slogan] The slogan of the site.
[site-mission] The optional 'mission' of the site.
[site-mail] The administrative email address for the site.
[site-date-small] The current date in 'small' format. (06/07/2010 - 23:28)
[site-date-yyyy] The current year (four digit)
[site-date-yy] The current year (two digit)
[site-date-month] The current month (full word)
[site-date-mon] The current month (abbreviated)
[site-date-mm] The current month (two digits with leading zeros)
[site-date-m] The current month (one or two digits without leading zeros)
[site-date-ww] The current week (two digits with leading zeros)
[site-date-date] The current date (numeric representation of the day of the week)
[site-date-day] The current day (full word)
[site-date-ddd] The current day (abbreviation)
[site-date-dd] The current day (two digits with leading zeros)
[site-date-d] The current day (one or two digits without leading zeros)
[site-date-raw] The current in UNIX timestamp format (1269441371)
[site-date-since] The current in 'time-since' format. (40 years 3 months)
[current-page-title] The title of the current page.
[current-page-path] The URL alias of the current page.
[current-page-path-raw] The URL alias of the current page. Warning: Token value contains raw user input.
[current-page-url] The URL of the current page.
[current-page-number] The page number of the current page when viewing paged lists.
[metatags-global-keywords-1] The global keywords.
[metatags-global-keywords-2] The global keywords.
[metatags-global-keywords-1-raw] The raw global keywords. Warning: Token value contains raw user input.
[metatags-global-keywords-2-raw] The raw global keywords. Warning: Token value contains raw user input.

Perhaps this should be added to this issue instead?

dave reid’s picture

Status: Active » Postponed (maintainer needs more info)

@keva: No, we could use more details about what page you're not seeing all the tokens listed? Are you using the latest Token module release?

keva’s picture

The token list above is from "Replacement patterns" at admin/content/nodewords/default.

Using Token 6.x-1.15

keva’s picture

StatusFileSize
new157.02 KB
new21.15 KB

I just noticed that on node/edit, all the tokens are available.

Attached are 2 screenshots showing "Replacement patterns" at node/edit and at admin/content/nodewords/default.

dave reid’s picture

Status: Postponed (maintainer needs more info) » Needs review
StatusFileSize
new0 bytes

This should probably work in the meantime.

dave reid’s picture

StatusFileSize
new605 bytes
keva’s picture

Status: Needs review » Postponed (maintainer needs more info)

Thanks for the lightening-fast fix. It worked perfectly!

keva’s picture

Status: Postponed (maintainer needs more info) » Needs review
dave reid’s picture

Status: Needs review » Postponed
dave reid’s picture

Status: Postponed » Fixed

Status: Fixed » Closed (fixed)
Issue tags: -token

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