Action if image is empty

WooCommerce
March 18, 2025 09:32:53
lahtec
Topics: 1
Messages: 1
I have an image container with the following value:
[e2pdf-wc-product key="get_gallery_image_ids" path="0" attachment_image_url="true" size="full"]
The container has the ID 21.

Now I would like to adjust the position of another image by -50 pixels to the left if the image (with ID 21) is empty.

What exactly do I need to configure to achieve this?

Thank you in advance for your help!
March 18, 2025 09:51:26
E2Pdf
Topics: 7
Messages: 3617
Support
Hello,

In the "Actions" the shortcodes that output the value should be used, not the container IDs, so the condition should look as follows:

If [e2pdf-wc-product key="get_gallery_image_ids" path="0" attachment_image_url="true" size="full"] is empty, the block where the action is applied will be moved 50px to the left.

We would really appreciate your feedback at WordPress.org!
Get News and Updates
Our monthly newsletter keeps you in the loop, so you'll always be up to date with the latest news and updates about E2Pdf.
* You can update your email subscription preferences here.
All trademarks, service marks, trade names, product names, and logos appearing on this website are the property of their respective owners. The use of trademarks such as Formidable Forms®, Forminator Forms®, Gravity Forms®, JetFormBuilder®, WordPress®, WooCommerce®, WPForms® and others is solely for identification purposes (nominative use) and does not imply any affiliation, sponsorship, or endorsement by the respective trademark holders.
© 2017 - 2026, https://e2pdf.com

We use cookies to collect and analyse information on site performance and usage, to provide social media features and to enhance and customise content and advertisements. By clicking "Accept Selected", you consent to use of selected cookies according to our Cookie Policy.