Fieldset info

I've got a grid field I'm using for open graph content open_graph_grid_field.

Within this grid field I've got a text field type for open_graph_title.

Page template

In my page template, I'm using a template partial. When I call to that template partial I'm passing the values for the various grid field sub-fields into that template partial using {{partial:_open-graph-partial :html_open_graph_title_vars="{{title}}"}}

Template partial

Within the template partial I've got multiple section:open-graph-partial-name

The piece for the open graph title looks like {{section:html_open_graph_title_var}} {{html_open_graph_title_vars}} {{/section:html_open_graph_title_var}}

In my layout template I pull in that information where I need it. For any conditionals where I'm just using a normal field this approach works perfectly.

Problem

I'm having a problem when I want to use a conditional to pull in the entry's {{title}} value for when the content administrator hasn't added any open_graph_title information.

I'm not sure how to properly format the conditional for a grid's child fields within that template partial, so that if they're empty I can then pass in some other value to the partial.

I've already tried

:open_graph_title_vars="{{open_graph_grid_field:doesnt_exist='true'}} {{title}} {{/open_graph_grid_field}}{{open_graph_grid_field}} {{open_graph_title|specialchars|truncate:60}} {{/open_graph_grid_field}}"

I was thinking the :doesnt_exist="true" was the correct solution - no success.

Any suggestions?

I'd like to use a conditional so that if that field is empty, I can instead pull the entry title value and display that in the html title in the template markup.

Using a conditional and the above appraoch does work for me for other field types (without the doesnt_exist piece), but not so far with the grid.

Thanks, Reuben