BeansTag update

If you have no idea about BeansTag, please refer to BeansTag – The SEO tool for Drupal 7

Although BeansTag is not going to be approved as a Drupal 7 module, i still added some features to it as requested by the BeansTag users. But before i talk about the new features, i want to clarify a BeansTag concept

BeansTag depends directly on the url path.

For example, a node with nid = 1 has an url alias articles/abc, you can create 2 different BeansTags with the following paths.

  • node/1
  • articles/abc


The above 2 pages could have different titles and meta tags.

 

Here are the new BeansTag features.

1. Permission setting
You can now configure the BeansTag permission and allow other roles to edit BeansTag.

 

2. Token support
We can use now tokens in BeansTag. but please make sure a proper token is used. For example, if you use node token in a term page, the node token will never be substituted by the correct value.

 
Here is another token example.
Assume the url alias of node with nid 1 is one/two/three.

  • [current-page:url:unaliased:args:value:0] => node
  • [current-page:url:unaliased:args:value:1] => 1
  • [current-page:url:args:value:0] => one
  • [current-page:url:args:value:1] => two
  • [current-page:url:args:value:2] => three

 

3. * support in BeansTag path alias
Consider the following case.
i) france/paris/* can be used in BeansTag path alias. but it must be end with *, sth like france/*/paris WOULD NOT WORK.

ii) Assume you have the following 3 BeansTags
BeansTag A: france/paris/eiffel-tower
BeansTag B: france/paris/*
BeansTag C: france/*

  • If france/paris/eiffel-tower url is shown, BeansTag A will be applied becoz it has the exact match.
  • If france/paris/palace-of-versailles url is shown, BeansTag B will be applied. Although BeansTag C also match the url, the url pattern is less matched compared to BeansTag B.
  • If france/paris url is shown, BeansTag C will be applied since it is the only match.

 

That’s all. If you have any questions or suggestions about BeansTag, feel free to create an issue at the BeansTag project. =)

Advertisements

2 thoughts on “BeansTag update”

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.