Jump to content

Media Management - Select Images From Other Pages


Recommended Posts

Beware… Newbie Question! Have checked forums first but couldn’t find exact answer.

I have a use case where Customer loves to store images in folder structure. If I adapt this in PW, it can be pretty cool as I can add a lot of rich detail onto each Page in the folders that store images.

For example..

—Country
    — Zambia
    — Zimbabwe

On each country page exists Imagefield, plus a few text fields for copyright, tags and mapMarker for geolocation data.

When a user drops a batch of 20 or so images onto the country page, they can add “global“ tags, location, copyright data for these images in one go.

If they need fine grained data on a per image basis, then I am looking at a cool little module for extending Imagefield….. https://github.com/justb3a/processwire-imageextra

So part one is looking good :-)

Part two of the eternal problem is how to get images copied off of one page onto another page in the CMS. Preferably as a copied image, not a linked image because the file tree described above holds the master image repository for the website, plus also future web sites or use cases as well.

So I imagine an extension of the image field where I replace the File Upload button with another dialogue allowing me to cherry pick images out of the folder structure in Part 1.

Is this possible ? Looking at the code around lines 1586, 1544 for function TraverseFiles(files) in InputfieldImage.js would it be possible to send in an alternate file collection cherry picked via a dialogue & jquery from the pages in the image repository tree into this function ?

Then I can take full advantage of all the existing neat code in here ? It would be so crazy to try and re-invent the wheel as existing code looks so rock solid and cool.

Many thanks for reading!

 

Link to comment
Share on other sites

If you go the "a image is a page" route you could take a look at this older basic image manager that works with template image and possible custom fields for them.

There is a professional Media Manager for central orgranised media, too:

And at least a modul called MediaLibrary the also works with a template for images and files so this could used and expanded, too:

 

So as always many options to choose from ;)

  • Like 1
Link to comment
Share on other sites

All this modules does almost what you wrote:

- Central Image Management

- Using a Template for Images (So a Image is a single "Page")

If you need other things you could describe more in detail what you need. Since ProcessWire is hookable i don't thing editing Corefiles is a good idea.

As a example you could take a look at this little snippet that use images in a folder structure

https://github.com/mr-fan/AutoImagePages

(But i don't use it anymore...)

regards mr-fan

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...