function css(a) {
var sheets = document.styleSheets, o = {};
for (var i in sheets) {
var rules = sheets[i].rules || sheets[i].cssRules;
for (var r in rules) {
if (a.is(rules[r].selectorText)) {
o = $.extend(o, css2json(rules[r].style), css2json(a.attr('style')));
}
}
An example of view block with related nodes based on 'tags'.
1. Create a block (take a look at screenshots below)
2. Add a relationship: Taxonomy term: Content using: Tags
3. Add contextual filter: (field_tags) Content: Nid
When the filter value is NOT available
Provide default value -> Content ID from URL
MORE
check: Exclude
this contextual filter will remove current node from the view
4. Add contextual filter: Taxonomy term: Term ID
最新评论