http://www.enterana.com/blog/web-development/adding-custom-links-drupal-views
For a project that I am working on, I needed to add function links to various Views that I was creating. I wanted to add links to actions that I had written in the site's custom module. Initially, I had some trouble figuring out how to do this but once I found the right kind of field to add it's a piece of cake.
The magic lies in the "Global: Custom Text" field type, and the only real trick is that you need to add your included fields first. Here's how to do it:
For a project that I am working on, I needed to add function links to various Views that I was creating. I wanted to add links to actions that I had written in the site's custom module. Initially, I had some trouble figuring out how to do this but once I found the right kind of field to add it's a piece of cake.
The magic lies in the "Global: Custom Text" field type, and the only real trick is that you need to add your included fields first. Here's how to do it:
- Create or open a View
- Add your desired Fields
- For my action, I wanted to reference the Node's id (nid). However, I had no reason to display the nid to the user. So, I added the nid Field but selected the "Exclude from Display" option.
No comments:
Post a Comment