• Resolved majesticix

    (@majesticix)


    I am using a shortcode Pod template to display a file thumbnail image. That works fine however when paired with Ajax Search Pro to filter the results of these, the pod reference is lost and I get an embed error. This is the Pod shortcode used within my Elementor Post Item:
    [pods field=”resource_file._img.medium”]

    If add the name of the pod in the shortcode, it fixes the embed but then it simply just loads the first post for all the post items (so all the images look the same)—regardless if I use the filter or not.
    [pods name=”resource” field=”resource_file._img.medium”]

    If I append the use_current parameter to force the query, I get the same result as if I didn’t use the name parameter.
    [pods name=”resource” use_current=”1″ field=”resource_file._img.medium”]

    Any way to get this reference to work with Ajax Search Pro?

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

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Jory Hogeveen

    (@keraweb)

    Hi @majesticix

    This is because it the Ajax call probably isn’t passing the current object. If that doesn’t exists then it cannot find anything.
    Are you using auto templates to add this shortcode?

    Cheers, Jory

    Thread Starter majesticix

    (@majesticix)

    No, I am using a custom skin for the Elementor Post Widget (Elementor Custom Skin) which allows me to change the look of the default Elementor Post Widget’s items. I’m able to display custom pod fields and such normally using the default Elementor dynamic tags but no dice on the shortcode.

    I did however get it working with a little trickery.

    I inserted the shortcode widget and used the default Elementor dynamic tag to display the Post ID which properly pulls in the ID in raw text. In that same menu, there is an advanced pane that allows you to add text before and after your dynamic tag–so I injected the first part of the shortcode in the “Before” and closed it out in the “After”

    Post ID Dynamic selected
    Before = [pods name=”resource” field=”resource_file._img.medium” id=”
    After = “]

    This miraculously still fires the shortcode…basically a shortcode in a shortcode lol. Pretty janky so if there is a better way, I’m all ears but this correctly references the image during AJAX calls.

    Plugin Author Jory Hogeveen

    (@keraweb)

    Hi @majesticix

    Sounds like this is more a hack than a fix but if it works then great!
    Not sure if it will work in the future.

    I also can’t think of an alternative solution as this is Elementor area.
    Scott is working on a Pro Addon for Elementor though:
    https://pods-pro.skc.dev/downloads/page-builder-toolkit/
    Maybe that can help you in the future!

    Cheers, Jory

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Ajax Search Pro – Display Issues on filtering’ is closed to new replies.