/[drupal]/contributions/modules/imagepath/README.txt
ViewVC logotype

Contents of /contributions/modules/imagepath/README.txt

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Tue Mar 11 16:32:53 2008 UTC (20 months, 2 weeks ago) by noelbush
Branch: MAIN
CVS Tags: HEAD
Branch point for: DRUPAL-6--1
File MIME type: text/plain
This module allows you to refer to images that are associated with imagefields using a simple URL structure that locates the images based on the ndoes they belong to, rather than their locations on the filesystem.
1 Image Path Module
2 =================
3
4 This module allows you to refer to images that are associated with imagefields
5 using a simple URL structure that locates the images based on the nodes they belong
6 to, rather than their locations on the filesystem. This is especially convenient
7 for situations where you might be changing the actual filepath in an imagefield
8 sometimes, but it's also nice if you just prefer the idea of having a more consistent
9 URL structure for your site, where images can be treated more like "first-class content".
10
11 When you install this module, it scans all your content types to find which ones
12 have imagefields. It also "notices" when you alter any content types to add or remove
13 imagefields. Without any configuration from you, it allows you to use URLs like this
14 to refer to images:
15
16 /[$node_type]/[$nid]/[$field_name]
17
18 ...where [$node_type] is the "machine-readable" name of your content type, [$nid] is the
19 node id for a particular node, and [$field_name] is the name of the imagefield *without*
20 the "field_" prefix.
21
22 So, for instance, if you have a content type called "biography", and an imagefield
23 defined for it called "field_portrait", you can refer to the portrait on node 34 like:
24
25 /biography/34/portrait
26
27 As a "bonus", if your content type has only one imagefield, then you can omit the
28 field name at the end of the URL, like so:
29
30 /biography/34
31
32 Note that this module works by intercepting the request URI very early in the request
33 processing cycle (via hook_init()), so it may very well interfere with paths that you
34 define using modules like Path or Pathauto. Be careful.
35
36 Also please note that this module does not currently support imagefields with multiple
37 values.

  ViewVC Help
Powered by ViewVC 1.1.2