Skip Navigation

[Resolved] single duplicate in a grid

This thread is resolved. Here is a description of the problem and solution.

Problem:

Two grids with single fields are causing duplication issues when the second row is conditional. The second field in red is duplicated in the first one (in blue).

Solution:

- Check for HTML code inside conditionals that might cause errors, especially unclosed tags.
- Verify the conditional logic and ensure it works correctly according to the documentation.
- Make sure you select the year, month and date in the date picker, then click the update button to save the post.

Relevant Documentation:

https://toolset.com/course-lesson/using-toolset-conditional-block/

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.

This topic contains 8 replies, has 2 voices.

Last updated by Christopher Amirian 10 months, 1 week ago.

Assisted by: Christopher Amirian.

Author
Posts
#2678136
album.jpg

Hi
I have two grids with single fields, the second row of which is conditional.
And when the two rows are displayed, the second field in red is duplicated in the first one (in blue).
Thank you

#2678274

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

Please make sure that there is no HTML code inside those conditionals that cause some sort of error, for example not closing a tag might cause such an issue.

Also check the conditional logic and make sure it works ok:

https://toolset.com/course-lesson/using-toolset-conditional-block/

If the problem persists, I'd appreciate it if you could give me the URL/User/Pass of your WordPress dashboard after you make sure that you have a backup of your website.
It is absolutely important that you give us a guarantee that you have a backup so if something happens you will have a point of restore.

Make sure you set the next reply as private.

I will also need the page link to check the editor and what you have done.

Thanks.

#2678346

Hi
I haven't found a solution yet.

#2678510

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

Please provide the login information of your website by setting the next reply as private and tell us where to check and we will see if we can find why this is happening for you.

Thanks.

#2678626

Christopher Amirian
Supporter

Languages: English (English )

Screenshot 2024-01-16 at 18.04.29.png

Hi there,

Thank you for the login information, I clicked on the top left hamburger menu to show the list of the blocks.

Then I clicked on the Conditional block and from the right sidebar I saw that the condition was incomplete .

I clicked on that and I see that you selected the custom field of the post type but you did not specify any value for the static part at the right website.

That is why everything is wrong. The condition should be correct.

#2678649

Hi
I'm having a bit of trouble with the conditions.
I've tried it with empty value and I have the same problem.
Can you guide me a little more towards the right condition.
If the editor2 field is empty, then don't display the conditional block.
And it duplicates again.
thank you

#2678751

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

You can not implement such a thing with Conditional elements.

The issue is that all the data comes from the backend and while PHP loads the data there is no guarantee that the value of item 1 is available to do the comparison.

You can use Javascript code to hide and show the items on the front end of the screen.

Please add them without the conditions and I will help you with the Javascript code.

Thanks.

#2678753

Hi
I removed the if conditional and the problem persists.
on hidden link I still have REEDITION on the second line.
and there hidden link the second line is correct but it is duplicated in the first line
Thanks for your help

#2679390

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

Thanks, and sorry for the late reply.

Would you please watch the video below which I explained how to use the date picker to avoid the issue?

hidden link

Thanks 🙂

#2679405

Thank you a lot