I guess all is in the title, I would like to test the value of node's body in a PHP custom field, but it seems that there's no body variable so that I can do it.

I've even tried print_r($data) command, but can't find anything which looks like the actual node's body my view refers to.

So if there's is such a variable, that I might stupidly miss, I'll be grateful taht you give me, and if not, if there's any other way wiche let me test my body into a custom field.

Comments

casey’s picture

Did you add the body field to the view? After that you could exclude the body field from displaying using the "exclude from display" checkbox.

spoonfinger’s picture

Component: Documentation » User interface

That was the problem...

I had added the body field in the view at once, but after the custom field, so it couldn't see it, thank you for your help ^^

PS : the actual variable is $data->node_revisions_body ;)

casey’s picture

Component: User interface » Documentation
Status: Active » Fixed

Component: User interface » Documentation
Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.