WordPress.org

Ready to get started?Download WordPress

Forums

How do u insert multiple images into a post?, On WordPress 2.5 (29 posts)

  1. maxguy
    Member
    Posted 6 years ago #

    With the new wordpress, whenever u need to insert an image, you need to click on the "add an image", then a flash will pop up for you to upload pictures. After you have done that, u need to click on gallery, and click "show' on each photo, then click on the "insert into post" button.

    This is fine if you only add 1 or 2 image to your post, but if there is alot of image to insert, you have to go through the same process each time.

    Is there any easier way to mass insert photos?

  2. mnogueir
    Member
    Posted 6 years ago #

    Same problem here. I opened a ticket: http://trac.wordpress.org/ticket/6454

    Maybe it gets some support...

  3. Darran
    Member
    Posted 6 years ago #

    You can use the gallery function

    Just type [gallery] to display all the pictures you have uploaded in a batch, it worked for me.

  4. maxguy
    Member
    Posted 6 years ago #

    mnogueir : Yeah thats exactly what i think in your open ticket, still prefer the old way. Hopefully this will go through

  5. callmeforsox
    Member
    Posted 6 years ago #

    The [gallery] shortcode is only good if you want to show all the pictures you've uploaded for the post. What if you upload 1 as a header pic, 9 others as real pics and you only want to show those 9.

    There's got to be a way to put a selection box or multi-select in the flash dialog or define which pictures you want to be in the gallery.

  6. moshu
    Member
    Posted 6 years ago #

    You may try to use this plugin
    http://mfields.org/wordpress-plugins/mf_gallery_shortcode/
    until something else will happen in the WP code.

  7. macwise
    Member
    Posted 6 years ago #

    First off, as a long time WP user, I want to say I am very pleased so far with 2.5. Being a full time photographer, I was inclined to upgrade for the multiple image upload feature. However, I feel that this feature, like all new features, is young and incomplete. While technically it's exactly as advertised (you can upload multiple files at once), it's actually likely to be more work than the old version of WP if you are uploading many images and adding titles to each image. Here's what I think should happen:

    Step 1: Upload the images
    ---they crunch, GOOD!
    Step 2: Click on each separate image to modify individual details (as you can do now)
    ---OR---
    ---Modify the "Apply to All" settings to create/change settings on all images in gallery at once
    Step 3: Send all images from gallery to post (formatted in the post exactly as they would be should you add them individually.)

    That's it. Currently you have to modify each and every image one at a time, and then place them in the post one at a time. This is a huge problem if you are adding 30-50 images per post at a time as I am, especially as the post grows longer with each image insertion. We have bulk upload, now let's get a real "BULK ADD" feature.

    Hopefully this all makes sense.

  8. beardedknight
    Blocked
    Posted 6 years ago #

    While it is frowned upon, you can edit a core file in wp-admin to achieve what you want:

    in the file "wp-admin\includes\media.php", look for "function media_send_to_editor($html)".

    change the following code:

    function media_send_to_editor($html) {
    	?>
    <script type="text/javascript">
    <!--
    top.send_to_editor('<?php echo addslashes($html); ?>');
    top.tb_remove();
    -->
    </script>
    	<?php
    	exit;
    }

    to this:

    function media_send_to_editor($html) {
    	?>
    <script type="text/javascript">
    <!--
    top.send_to_editor('<?php echo addslashes($html); ?>');
    //top.tb_remove();
    -->
    </script>
    	<?php
    	//exit;
       return;
    }

    In this case, you are effectively telling the editor to stay open and returning back to the iframe code to load again. I still haven't figured out how to hook in the code through a plugin, though.

  9. running_m
    Member
    Posted 6 years ago #

    thanks! i implemented this, and it works like i thought it should have originally. now i can insert multiple images without the pop-up viewer closing every time. a real time-saver.

    still looking forward to an "Insert All Images" button that inserts all the images separately so i can move them around in the posts.

  10. duncanmc
    Member
    Posted 6 years ago #

    Yes, "Insert All Images" button is absolutely necessary. I want to insert all of them at once and then write comments between them.

  11. macwise
    Member
    Posted 6 years ago #

    I modified my media.php file, and though not the comprehensive solution I'd love to have eventually, it is a HUGE help and definitely speeds up posting multiple images. Thanks!

  12. Samgreen
    Member
    Posted 6 years ago #

    I have multiple images in many posts on one of my blogs. I just use ftp software to create an images folder.

    Upload the image files to that folder, place a link to the image files I want on that page. Voila ! All done.

    So I could create it this way: blog_url/images/

    so a link in my blog would be blog_url/images/joe.jpg blog_url/images/marsport.jpg etc.

    You can then add text between each <,img src line.

    No need to alter the core php files.

  13. artsy.ca
    Member
    Posted 6 years ago #

    thank you so much!! works really well!
    It would be nice if you could click five times to insert five images, but this is reasonably well under the circumstances!

  14. Samgreen
    Member
    Posted 6 years ago #

    You're welcome. I prefer easy to impliment solutions over those solutions that take major work to accomplish. These are blogs we are working with, not engineering projects like the Panamal Canal.

    For the grouches out there: Obviously, I'm not talking about the work done on wordpress itself.

  15. etegration1
    Member
    Posted 5 years ago #

    the chunk is now:

    function media_send_to_editor($html) {
    	?>
    <script type="text/javascript">
    /* <![CDATA[ */
    var win = window.dialogArguments || opener || parent || top;
    win.send_to_editor('<?php echo addslashes($html); ?>');
    /* ]]> */
    </script>
    	<?php
    	exit;
    }

    any side effects if changed to the following?

    function media_send_to_editor($html) {
    	?>
    <script type="text/javascript">
    <!--
    top.send_to_editor('<?php echo addslashes($html); ?>');
    //top.tb_remove();
    -->
    </script>
    	<?php
    	//exit;
       return;
    }
  16. omgitztrey
    Member
    Posted 5 years ago #

    I tried adding just the return;

    It didn't work on version 2.6

  17. jaiunblog
    Member
    Posted 5 years ago #

    on wp 2.6
    i try (it's work on simple test)
    in media.php

    function media_send_to_editor($html) {
    	?>
    <script type="text/javascript">
    /* <![CDATA[ */
    var win = window.dialogArguments || opener || parent || top;
    win.send_to_editor('<?php echo addslashes($html); ?>');
    /* ]]> */
    </script>
    	<?php
    	//exit;
    return;
    	}

    and in wp-admin/js/media-upload.js
    add // on tb_remove();

    //tb_remove();
  18. wordpressorgnewbie
    Member
    Posted 5 years ago #

    dear jaiunblog

    The function media_send_to_editor($html)codes couldn't be found in the WP 2.6.1 media.php file, did you mean that we directedly insert it to that php.

    Or do you have any other way to batch-insert multiple images into a WP 2.6.1 post?

    Thanks

    wordpressorgnewbie

  19. wordpressorgnewbie
    Member
    Posted 5 years ago #

    sorry, Jaiunblog, I mis-looked at media.php in wp-includes not wp-admin. But anyway, just what omgitztrey encountered, I still can't make it in wp2.6.1 even after I used your way, changing js in media-upload js file. :-(

  20. macwise
    Member
    Posted 5 years ago #

    I'm wondering if this can become a plugin. I would really like to be able to manage a gallery under the premise that I have more than one image to insert into my posts at a time, and that I don't want to use the built in gallery that only shows a limited, cropped thumbnail of the images. I would love to do this myself, but A) I'd hack it, B) I wouldn't keep up with it, and C) I don't really have time/skill to make it a really slick plugin.

    Anyone out there looking to show their skills? Lester Chan?

  21. Samuel Wood (Otto)
    Tech Ninja
    Posted 5 years ago #

    WordPress 2.7 is getting some enhancements to the gallery, hopefully. There's some talk about making a multiple gallery thing per post, but there's still disagreement as to how to best do it.

    Expect improvements though.

  22. NicholasReed
    Member
    Posted 5 years ago #

    http://www.hollywoodcelebgossips.com/2008/08/31/insert-multiple-images-into-a-post-published-by-wordpress-26-or-higher/

    dudes, this dude (well, it could possible be a female), well considering the 'content' of the website, well who knows.

    It is surely true that a 'gentleman' would not expect to find such a powerful solution, on a website featuring such content.

    Well none the less, electronic justice has been done.

  23. deevio
    Member
    Posted 5 years ago #

    I couldn't figure out how to do this via a plugin but I hope this helps someone out there. This is a hack to WordPress 2.7's 'wp-admin/includes/media.php' file and will add an "Insert all images" button.

    Download here:

    http://www.deevio.com/downloads/wordpress-hack-to-insert-all-images.zip

    Install by replacing the file 'media.php' on your server with the contents of the file 'media_hacked_just-rename-to-media.php' found in the zip.

    And here's a screenshot of what you should see:

    http://www.deevio.com/downloads/wordpress-hack-to-insert-all-images/screenshot_and_installation_guide.gif

  24. bentupper
    Member
    Posted 5 years ago #

    @deevio

    Stardate: February 9, 2009...

    This fix works great for WP2.7! Anyone know how to take it and make it into a plugin now? Come on PHP gurus!!

    You can see my implementation of this on this test page here:
    http://tkdesignindy.com/index.php/a-gallery-test-page/
    (subject to removal over time).

    By the way - I'm using the Lightbox 2 plugin (http://www.stimuli.ca/lightbox/)to run my slideshow after you click on a thumbnail from deevio's gallery implementation.

    Thanks deevio!! Great work!

  25. michael_u
    Member
    Posted 5 years ago #

    I've been following this topic for quite a while now, hopping to finally find a solution to insert several images at one time.
    The hack from deevio seems like a good start, although it's only inserting the bulk images, without the frames, titel of the image and so on.

    I'd really aprectiate if a coder could look at how to make a plugin for our all problem.

    Cheers,
    Michael

  26. thehungrymouse
    Member
    Posted 5 years ago #

    I'm with Michael_U. My posts can include dozens of photos. I'd love to be able to insert all my full-size images at once, then be able to write between them. It would save me so much time that I think I'd pay for a plug-in that did this.

    Cheers!
    Jessie

  27. dbasulto
    Member
    Posted 5 years ago #

    thehungrymouse,

    i suggest you to try this plugin: http://wordpress.org/extend/plugins/faster-image-insert/

    will do exactly what you want..what a timesaver!

  28. michael_u
    Member
    Posted 5 years ago #

    thank you so much dbasulto!!!!!!
    you saved my day finally I will save so much time!
    It's exactly what I (and I think every one else here) was looking for!
    Works perfect with 2.7.1
    It's only two steps now
    1. upload the images, tag them, save the changes
    2. In the Gallery arange the order of your images, select thoose that you want and hit "insert selected images"

    lol "http://thanks.for.considering.a.donation/you.can.keep.it/" ... too bad

  29. ocroquette
    Member
    Posted 5 years ago #

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags