• Resolved febinky

    (@febinky)


    Dear Smart Slider 3 Support Team,

    We are in the process of developing a mobile app for our WordPress site, and as part of this project, we need to access and retrieve gallery images stored in the WordPress application via Smart Slider 3. We plan to create custom APIs for this purpose.

    While reviewing the database, we were unable to get a clear understanding of how the images are stored, especially in relation to the slider IDs and associated posts. Could you please provide us with details on how we can fetch images based on the slider IDs? Any guidance on retrieving these images efficiently for each post would be greatly appreciated.

    Thank you for your assistance.

    • This topic was modified 4 months, 2 weeks ago by febinky.

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support Gabor

    (@nextendweb_gabor)

    Hi @febinky!

    I just wrote to your email support ticket, but I will paste my answer here too:

    “If you would like to retrieve the background images of slides, those are stored in the [prefix]_nextend2_smartslider3_slides database table. The “slider” row contains the ID of the slider, so that could be used at your query. The “params” row contains the json encoded data of the given slide. You could paste that content for example here, to see it through. Amongst the data you will find the background image:

    backgroundImage: $upload$/slider68/imageslider-background2.jpeg

    $upload$ means the upload folder of WordPress, by default: /wp-content/uploads

    So with a json_decode function: https://www.php.net/manual/en/function.json-decode.php
    you can convert the “params” data into an object or array, and there you could access the backgroundImage value.

    Officially we don’t support custom coding, so our help is limited in such matters, but if you have any questions, let me know!”

    • This reply was modified 4 months, 2 weeks ago by Gabor.
    Thread Starter febinky

    (@febinky)

    Hi Team,

    While examining the slider parameters, I came across the following data structure:

    {
    "ordering": 0,
    "static-slide": 0,
    "backgroundColor": "ffffff00",
    "backgroundImage": "{image}",
    "backgroundImageOpacity": 100,
    "backgroundAlt": "",
    "backgroundTitle": "",
    "backgroundMode": "default",
    "backgroundVideoMp4": "",
    "backgroundVideoOpacity": 100,
    "backgroundVideoMuted": 1,
    "backgroundVideoLoop": 1,
    "backgroundVideoMode": "fill",
    "link": "|*|_self",
    "slide-duration": 0,
    "background-type": "image",
    "record-slides": "200",
    "version": "3.3.27"
    }

    <span style=”font-size: inherit; text-wrap: var(–wp–custom–body–typography–text-wrap);”>This seems to represent various properties related to a slide, such as the background image, colors, video settings, and more. Specifically, the </span><code style=”text-wrap: var(–wp–custom–body–typography–text-wrap);”>”backgroundImage”: “{image}”<span style=”font-size: inherit; text-wrap: var(–wp–custom–body–typography–text-wrap);”> parameter indicates the background image, which is likely a placeholder that will be replaced with the actual image reference.</span>

    I can see that in the wp_posts table (with post_type = 'attachment'), there are multiple image GUIDs (12 in total) associated with a post. However, I’m unclear on where to retrieve all the images related to each slider, as I’m looking for not just background images, but additional images related to the post.

    Could you please clarify:

    1. Where the remaining images are stored: Beyond the background image, where can I find other images used in the slider (such as in the wp_posts table or elsewhere)?
    2. How to correctly link the images from the slider parameters: For example, how do I map the image placeholders in the slider configuration to the actual published images in WordPress?

    I appreciate your guidance in clarifying how to retrieve all the images associated with a post and its sliders.

    Thread Starter febinky

    (@febinky)

    Thank you for your assistance. In the wp_nextend2_section_storage table, I used the following query:

    SELECT * FROM wp_nextend2_section_storage WHERE section LIKE ‘%-304%’

    This query retrieves the image->images array under the assets object in the column’s value, where application is set to cache. These images are the ones we’re expecting.

    However, I’ve noticed that when we publish or unpublish through the backend site of the wordpress application, these cached images do not reflect the changes unless we reload the WordPress application site successfully.

    Could you please advise on how to ensure the cache updates properly without needing to reload the site?

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.