![]() ![]() Node reference (Label: 'Gallery' Name: 'field_gallery' Type: 'Node reference') - This field references the Gallery node where the stored image is supposed to be displayed.Imagefield (Label: 'image' Name: 'field_image' Type: 'file') - This field stores the image file.admin/content/types/add, create a new content type named "Photo" and save it. However, feel free to adjust parameters like Submission form settings, Workflow settings, or Comment settings to your liking this will not harm the following steps in any way. Save it with default values, you don't need to change anything so far. admin/content/types/add, create a new content type named "Gallery". ![]() We'll select this ImageCache action output in the View for the gallery Step 2a: Creating the Gallery Content Type Go to admin/build/imagecache and create a new preset named 'teaser_thumb'.Step 1b: Create ImageCache Thumbnail Action Please note: To create new content types, you have to be logged in with proper permissions (e.g. 'image' instead of 'photo', or 'photoset' instead of 'gallery'), but the required views have to be adapted to those different names. These content types might be created with different names (e.g. Photo - imagefield-based content type for photos.Gallery - a simple "container"-like content type for galleries.Node-based image galleries require two content types that need to be created via. (fixme: required sub-modules) Step 1a: Create Content Types Most of these modules are well known the "essentials" of this specific approach are Views Attach and Nodereference URL.ĭownload an enable all of these modules at /admin/build/modules. Views Attach - add-on for CCK-based content types that attaches a view to a node.Views - all purpose "reports" generator for Drupal.Nodereference URL - widget for CCK node reference fields.Imagecache - generates image derivates on the fly.Imagefield - stores images in a CCK Filefiled.Filefield - stores files through an CCK field.CCK - adds customizable fields to Drupal.This tutorial uses a bunch of core and contributed modules: If you're eaning your money with hacking Drupal core everyday, you'll most probably want to code your own custom gallery module. Skills required: This Howto targets primarily advanced Drupal newcomers and Drupal site administrators with a basic understanding of Views and CCK. Image module offers adifferent gallery solution that is based on Taxonomy and views. Notice: This approach is based on the Content Construction Kit (CCK) and won't work with the contributes Image module. In the end, this is one of the most advanced approach to publish images with Drupal, so there are tons of reasons to educate the Drupal community about this approach. This Howto is a transcript of the screencast Photo galleries with Views Attach by Jeff Eaton, where Jeff demonstrates how to to create node-based galleries with CCK and Views. Thus in many cases a node based photo gallery would be preferrable - if it would exist.Īs usual, Drupal can solve this problem with a set of core and contributed modules. Most Drupal-based Gallery solutions use Taxonomy to build sets of images the resulting galleries are Taxonomy pages that can be easily maintained and expanded, but are not available to the node system: They can't be referenced from other nodes through a CCK node reference field, they can't be tagged, they don't accept comments and so on. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |