hello,
I want to display node signup links with views 2 (raw style: fields). However, only nodes with enabled signup must have the signup link. I don't know how to add such an optional field. More generally is it possible to display conditional fields with views 2?
Thanks

Comments

iNade’s picture

Subscribing.

dawehner’s picture

at the moment its not possible, sure you could create a display which can do this.

As alternative you can theme the fields, then you can use $row to check for another field.

masood_mj’s picture

Title: How to display conditional fields with views 2 ? » How to get a field value without its html tag

I want to use "has new content" field in the table theme file to highlight unread messages. However, when I print the "timestamp" field using print $row["timestamp"]; it prints <span class="marker">new </span>. I want to use its value in a if to change the row css class. How can I get a field value without its html tags

dawehner’s picture

then you can look in $view->results, i think.

There should be the result of the databasequery

masood_mj’s picture

I'm writing a view theme file. It seems that $view variable is not defined there.

merlinofchaos’s picture

Category: feature » support
dawehner’s picture

what do you mean with view theme file?

masood_mj’s picture

I mean "views-view-table.tpl.php," file that I have written in my theme file to override the default table style of a view

esmerel’s picture

Status: Active » Closed (fixed)

Given the age of this issue, I have hope that it's resolved or no longer relevant.