Skip Navigation

[Resuelto] logic not empty still shows field

This support ticket is created hace 8 años, 2 meses. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Etiquetado: 

This topic contains 1 respuesta, has 1 mensaje.

Last updated by Marisa hace 8 años, 2 meses.

Autor
Mensajes
#368211
  [wpv-conditional if="( NOT(empty($([wpv-post-excerpt]))) )"]
          <div class="excerpt">
            <h4 class="white" style="margin-top:0; margin-bottom:0; padding-bottom:0;">[wpv-post-excerpt length="20"]<h4>
              </div>
    [/wpv-conditional]

See how it returns only the empty fields in the screen shots? It's backwards of what I'm asking it to do. If I try to reverse it, they all disappear.

screenshot:
hidden link

I feel like this code is very simple, so if you can point out the error of it, maybe that will help me.

If not, I can clone the site to a staging version (right now it is local), and share logins and urls with you.

But if you see a problem with my code let me know.

#368224

I removed the brackets.

I also created a custom fields to use instead of the default excerpt, with which it just didn't work.

So new code is:

 [wpv-conditional if="( NOT(empty($(sticker))) )"]
          <div class="excerpt">
            <h4 class="white" style="margin-top:0; margin-bottom:0; padding-bottom:0;">[wpv-post-field name="sticker"]<h4>
              </div>
             [/wpv-conditional]
This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.