Jump to content
  • 0

Hiding an empty field.



Hi Gurus, 
I have this business directory working in Wordpress + Avada Theme. Now we are moving to DIVI theme and some things are not working. I have this tabular report that shows all the offices for the specific company that was select. In the "Search and Report Wizard - Configure Results Page Fields" part I have this javascript to hide the fields that are blank:

if("[@field:Address]".length > 0){
document.write('<strong>Address:</strong> [@field:Address]<br />')
if("[@field:City]".length > 0){
document.write('<strong>City:</strong> [@field:City] ')
if("[@field:State]".length > 0){
document.write('<strong>State:</strong> [@field:State] ')
if("[@field:ZIP]".length > 0){
document.write('<strong>ZIP:</strong> [@field:ZIP]<br />')
if("[@field:Country]".length > 0){
document.write('<strong>Country:</strong> [@field:Country]')

it works very nice in AVADA:

 but it's not working in DIVI: 


I also tried also this technique: 

but no success again.

Can someone help? 
thank you very much for any clues. 

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...