Can a filter be created that would run the Context Links script on each node?
See http://affiliate-program.amazon.com/gp/associates/network/build-links/co...
Would be a nice thing to have i think ...
Can a filter be created that would run the Context Links script on each node?
See http://affiliate-program.amazon.com/gp/associates/network/build-links/co...
Would be a nice thing to have i think ...
Comments
Comment #1
tcblack commentedWhy not just paste the code into a full html block and place the block in your footer or closure area? Quite a trivial cure.
Comment #2
sevanden commentedBecause that option makes the contextual relations based on content even outside the nodes, including all additional links which are counted to set set limits to the amount of Amazon links. Aside from that, it would be nice to be able to chose on what nodes you want this script to run ...
Comment #3
tcblack commentedI see your point.
Comment #4
eaton commentedRather than using a filter, I'd prefer to set up a module that requests the contextual items when the node is saved, and adds explicit relationships to the node using the amazon_item_node table. Using a filter would be relatively inefficient...
Comment #5
sevanden commentedNot a bad idea, but doesn't a filter allow your content to be saved unchanged to the database? The amazon script itself would be looking for the links based on the content of the node as well as the 'up-to-date' suggestions they may have ...
Comment #6
rfayComment #8
rfayFYI: I've just added a number of filters. Now everything that is preprocessed in amazon_preprocess_amazon_item() is available through the [amazon ASIN detail] filter.
Docs will be up today, hopefully. http://drupal.org/node/595464
-Randy