WordPress.org

Ready to get started?Download WordPress

Forums

insert image to single.php (3 posts)

  1. to_ul
    Member
    Posted 5 years ago #

    Hi WordPress-people,
    ...i need a piece of code that will show an image that belongs to the post.
    for example:
    my first post hast the id:1, i have uploaded via TDOMF-uploader an image, the image is stored correctly and automaticly after the upload in: ".../uploads/1/image1.jpg"

    now i need a tag/piece of code that will insert the image1.jpg into my single.php.

    i hope someone can put me into the right direction

  2. Joni
    Member
    Posted 5 years ago #

    single.php is a POST TEMPLATE. It is used to view any or all of your posts, individually. If you put an image there, it will show up when you view all your posts individually.

    If you just mean to associate a particular image with a particular post, use the Custom Field.

  3. to_ul
    Member
    Posted 5 years ago #

    yes: i want to associate a particular image with a particular post. can i do this with custom fields? i have already uploaded my images correctly...via the TDOMF plugin.

Topic Closed

This topic has been closed to new replies.

About this Topic