OL Learn

Get path from DataMapper PDF

Is it possible to get the path to use with resource() from BackgroundResource.DATAMAPPER_PDF?

Not officially… but that should be possible with some creative coding.

Create a post pagination script using the selector “.masterobject” and the following source:

const url = results.parent().children().filter("img").attr("src");

This is obviously not elegant and it might break whenever we release a new version of Connect. Unfortunately my proposal to make it easier for post pagination scripts to access page containers has been stuck in backlog limbo for a long time.

1 Like

Note: I’m afraid this can only be done in a post pagination script, not in a control or standard script.