WordPress.org

Ready to get started?Download WordPress

Forums

Best way to store and retrieve multiple images, custom field? (2 posts)

  1. rughooker
    Member
    Posted 3 years ago #

    I created a custom post type and some meta data boxes with custom fields. So far, so good. Now I need to store multiple images. I will be displaying them on a product pages as "Also recommended." I'd like to enter just the file name, such as, B1, B2, R1, R2, etc., and then display them in a post.

    I am using PHPurchase as my ecommerce plugin, but this plugin will not affect what I do with the images. What is the best way to do this?

  2. rughooker
    Member
    Posted 3 years ago #

    I found some information about explode. If I enter "B1, B2, R1, R2" in a text field and then explode it into individual entries I could feed it to my template file. Something like: <img src="/path/to/my/files + B1 + .jpg">

    I just need to figure out how to check for the images and then loop through all of them. Need an example.

Topic Closed

This topic has been closed to new replies.

About this Topic