Drupal: images in posts, nodes

Created by janroe

Originally created Fri, 23 Dec 2011 - 10:50. Moved here to separate the image topics.

For D6, checking to see what's currently the best, and most forward looking (= most D7 compatible) way to show images in standard user generated posts and comments.

Apparently the image module and its image assist module are "legacy", not the way to go. So, image is out for images. Well.

Forward way to go is with CCK: http://mustardseedmedia.com/podcast/episode29. Also http://drupal.org/node/877140 #35.

Summarising those, the modules are available both in D6 and D7, so the result actually appears to be forward looking: - http://drupal.org/project/insert formerly file field insert, cck 2.5+ - http://drupal.org/project/wysiwyg formely WYSIWYG API - http://drupal.org/project/image_resize_filter allows resizing of image

- http://drupal.org/project/filefield CCK submodule (easy upgrade to D7 because in core) - http://drupal.org/project/filefield_sources CCK submodule to insert existing images, cck 2.6+, filefield 3.5+ - http://drupal.org/project/imagecache (easy upgrade to D7 because in core)

- http://drupal.org/project/imagefield CCK submodule (allows image preview) (easy upgrade to D7 because in core). not compatible with image module

Need to understand/learn: imagecache. Input format: it requires as a user input. This can be done by using input format full html, adding to filtered html, or setting up a specific new input format for roles that are allowed to use or and possibly others.

Direct implications: - FileField Sources 6.x-1.4, when used for attaching images that are already on the site, cannot access subdirectories within the directory that you set for it to look up images. At least I have not been able to figure this out.

This is unfortunate, because the alternative is to use IMCE which in turn requires an editor like CKEditor and WYSIWIG. I do much prefer a clean, clear input screen over the IMCE/CKE/WYSIWIG option.

But I need the ability to browse images, at least for administrators. IMCE module can can be set to behave more like a file manager, browsing subdirectories; a disadvantage is that it needs the WTSIWTG, plus an editor, and it uses a pop-up window as file manager:

- WYSIWYG editor alternatives, after research I chose CKeditor: http://drupal.org/project/ckeditor, installation http://www.janroe.com/node/150

- WYSIWYG and/or CKE Editor deletes line and paragraph breaks when switching from content made in "Filtered HTML" to "Full HTML" even if unchecking "Remove all line breaks". To avoid losing formatting, install contributed module: http://drupal.org/project/wysiwyg_linebreaks and enable the "Force linebreaks" check mark.

- IMCE is either an alternative, or "additional means" for FileField Sources to "select existing files"; upgradable from D6 to D7: http://drupal.org/project/imce for file uploading and attaching existing files, to integrate IMCE module with WYSIWYG module, must have: http://drupal.org/project/imce_wysiwyg = "IMCE Wysiwyg bridge" and enable IMCE as a plugin in WYSIWYG administration. But IMCE appears to work also without this brigde, not sure what is missing from it without it.

- IMCE and attaching files already on the site. As well as file deletion behaviour. http://drupal.org/node/1099994 - IMCE does not read all files

- IMCE Warning: Make sure you have the settings right for user roles access to the images. You may not want to give all users access your root image section!!! In one of my installations someone inadvertently did just that.

Interesting http://drupal.org/node/528074 images http://drupal.org/node/265416 file management http://drupal.org/project/image_caption http://drupal.org/node/1083742 (with css static positioning of images) http://drupal.org/project/views is not needed to insert images into posts.