WordPress.org

Ready to get started?Download WordPress

Forums

The Perfect Image Plugin! (17 posts)

  1. Brooks
    Member
    Posted 9 years ago #

    Does it exist? I've searched through the forums and tried out a couple (Photopress, Exhibit) and I can't seem to find what I'm looking for. Photopress was close, but I'm not sure how to get it to insert code that aligns my images the way I want them and to wrap text around them when they are small (thumbnails).

    Here's my dream.
    In the Write Post window I would click on an upload button and browse for the image, then upload it. Then a window would ask me if I want to use the thumbnail or FULL SIZE IMAGE ( I don't need the thing to resize my main image. I did that in PS before I got this far). Then it would ask how I want to align the image (left, right, center, whatever would make the text flow around the image, etc. If I chose thumbnail, it would ask me if I want the thumbnail to link to a full size pop-up. After I made my choices, it would insert the correct code into the post and I would live happily ever after.

    I'm sure there are other things that people would want, but I don't ask for much. :-)

    I don't need albums or pages of thumbs or any of that. I just want to insert images into my posts without writing the code in the posts or altering the code inside the plugin itself.

    Is this impossible? Does it already exist?

  2. fishcakes
    Member
    Posted 9 years ago #

    I would recommend using photopress and then doing this:

    1) add this code to your CSS file:

    img.centered {
    display: block;
    margin-left: auto;
    margin-right: auto;
    }

    img.alignright {
    padding: 4px;
    margin: 0 0 2px 7px;
    display: inline;
    }

    img.alignleft {
    padding: 4px;
    margin: 0 7px 2px 0;
    display: inline;
    }

    .alignright {
    float: right;
    }

    .alignleft {
    float: left
    }

    2) Now, whenever you add the image code into your post from Photopress, add within the img tag either class="alignleft" or class="alignright". This should wrap the images correctly.

    BTW, I lifted that CSS straight out of the default Kubrick template, so I take no credit for that whatsoever. Hope that helps!

  3. Jinsan
    Member
    Posted 9 years ago #

    What you can do, and something I did myself, was to create a class in the css such as:

    img.left or img.right or img.centre

    If you use the IImage Gallery, that covers most of the basics for what you want in a plugin for images. Next, use the plugin to browse the image you want and select it, it will then add the code for you. Where you see see img src= before the source or after enter class="left" or class="right" or class="centre" as you've styled in your style.css. This will align the img as required. It's only one part of the process you have to do, and I'm sure that will fit your requirements.

    The reason is this - the plugin is insert the image code, but it doesn't know what your stylesheet looks like, it doesn't know how an image aligned to the left will look like and perhaps it will break the text. All it can do is say, I have an image, and it must go here. You would then say, I want the image specifically here.

    an example I'm using in a wip is:

    img.left {
    margin-right: 6px;
    margin-bottom: 0px;
    margin-top: 5px;
    float: left;
    padding: 0px;
    border: 3px solid #fff;
    }

    I've left the img tag itself alone, because I want all imgs to default to whatever they are before I apply any changes.

    Maybe that helps, or maybe I've confused you?

  4. fishcakes
    Member
    Posted 9 years ago #

    WOW, Jinsan, we posted almost the exact same answer at the exact same time! great minds :)

  5. Brooks
    Member
    Posted 9 years ago #

    Thanks folks. You did solve the main issues I had. Please go to my blog and see my test posts.

    One major problem I'm having is with the weirdness that happens if you click on the pictures though. It completely destroys the page that the main image is on when you click on it. Please take a look and tell me if you think it's a simple fix or not.

    Is there a simple way to make the full size image show in a pop-up window when you click on a thumbnail? That would be WAY better for me. If you have any ideas, that would be cool.

  6. clarke1866
    Member
    Posted 9 years ago #

    Don't you need to add the clear:left component too?

  7. Brooks
    Member
    Posted 9 years ago #

    Sorry Clark. I'm not sure what "clear:left" does.

  8. Bink
    Member
    Posted 9 years ago #


  9. Basilisk
    Member
    Posted 9 years ago #

    Perfect! Exactly what i've been looking for! Thanks guys.... as for the clear:left thing, I haven't needed any more than what was posted above, no idea what clear does either.

  10. clarke1866
    Member
    Posted 9 years ago #

    Clear

    CSS clear is a useful property which gives webmasters the ability to put objects below another. Commonly used with floats, clear gives us the power to make creative designs and add flavor to the web.

    Clear left, right or both
    You may use clear: left;, clear: right;, or clear: both;. When using clear: left; the element will stay clear of the other elements left of it putting it below the others. When clearing both, it makes the element go below all elements above it.

  11. Jo5329
    Member
    Posted 9 years ago #

    Can you explain using Clear in relation to this post, ie: images left/right? I think this is what I need, and I'm confused as to how to use it. Does it need to go in the style sheet, or somewhere after the post?

    Thank you .. I did search on this to find the answer, but couldn't.

  12. Jinsan
    Member
    Posted 9 years ago #

    jo read the post above yours:

    Clear left, right or both
    You may use clear: left;, clear: right;, or clear: both;. When using clear: left; the element will stay clear of the other elements left of it putting it below the others. When clearing both, it makes the element go below all elements above it.

    that pretty much explains it. the value is clear: then left, right or both. It goes into your css. What you can do is add it as a class in your css and call that within a div. Use it any floated element as clear: both or whatever variation you need

  13. station
    Member
    Posted 9 years ago #

    Hey Brooks,
    the Iimage Browser will do this for you easily.
    http://fredfred.net/skriker/index.php/iimage-browser
    Check it out, and look at the personalized code part, the developer Martin Chupá calls them - patterns used in the Iimage gallery, which I don't use, but I use the patterns, or personalized code.
    It still needs the align options but you can include that in your personalization.

  14. chutney
    Member
    Posted 8 years ago #

    Thanks fishcakes!

  15. ColourDreamer
    Member
    Posted 8 years ago #

    I am trying to use the custom patterns for IImage Gallery to show images on templated pages, instead of blank (image) pages. But I can't get it. I only have like half the code. My image page doesn't recognize the variables, but I have it up til then. I can get as far as linking TO the page.

    If I could get this last and very important step, it would be MY perfect image plugin.

    Help?

  16. Conceit
    Member
    Posted 8 years ago #

    I developed a plugin, which lets you upload images from the post form (I know, nearly obsolete in 2.01). The image gets automatically resized twice (thumbnail and image), which can be set up detailed in admin panel. It automatically puts the image into the posts using a pre-defined html template (default template is pre-installed) -> Image top left, floating, small frame around, textual description below, onclick-Javascript to open the full sized image.

    So the only thing you need to do:

    1. Install plugin
    2. Set up final image and thumbnail size
    3. Start/edit a post
    4. Chose a local image for the post (gets uploaded then)
    5. Submit

    Some more features:
    * Resizing like "Fit-best-in-a-bounding-box", Relative-Size, Absolute-Size, No-Resize...
    * Images files get maintained automatically (get deleted, when post gets deleted and get replaced, when new image for that post was uploaded)
    * HTML-Template to give extreme control

    and so on.

    I'd really like to know what you think about the plugin.

    http://www.wp-plugins.net/index.php?filter=sticky+image&filter_search=Go...

  17. xtc
    Member
    Posted 8 years ago #

    try this. I'm using it, and it does exactly what you want and better, you can upload multiple images associated to a post and drag/drop them into the rich text editor. It's really nice :)

    http://guff.szub.net/post-image

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.