Is there a way to list and insert the images attached by the imagefield module?

Comments

nubeli’s picture

There's a common need for this. On one site I've been using imagefield_assist module, which has been a bit neglected lately, but appears to work well. It's based on img_assist. You use this button code to integrate it into BUeditor (it's very close to that used for img_assist):

php: global $base_url;
return "js: window.open('$base_url/imagefield_assist/load/textarea?textarea='+ E.textArea.id, 'imagefield_assist_link', 'width=600,height=400,scrollbars=yes,status=yes,resizable=yes,toolbar=no,menubar=no')";

It will show all the images uploaded to all nodes. The caveat is that you either use the default content type set up with an imagefield (in the latest dev from July 11, 2010) where you can upload images through the popup window, or you need to save whatever node you have the imagefield attached to before you will see it available in the popup for insertion into the textarea.

An alternative is listed on the main page of BUeditor (http://ufku.com/drupal/bueditor/contributions/imagecache). Or you can use methods that aren't integrated into BUeditor, such as the Insert module. It's not as elegant or user-friendly but it works. It won't, however, allow you to set classes to the image for styling.

ufku’s picture

Status: Active » Closed (won't fix)

This could be implemented by a custom button.