1
|
|
2
|
-- SUMMARY --
|
3
|
|
4
|
The Simple hierarchical select module displays selected taxonomy fields as
|
5
|
hierarchical selects on node creation/edit forms and as exposed filter in views.
|
6
|
|
7
|
|
8
|
-- REQUIREMENTS --
|
9
|
|
10
|
Taxonomy module (Drupal core) needs to be enabled.
|
11
|
|
12
|
|
13
|
-- INSTALLATION --
|
14
|
|
15
|
* Install as usual, see http://drupal.org/documentation/install/modules-themes/modules-7
|
16
|
for further information.
|
17
|
|
18
|
|
19
|
-- CONFIGURATION --
|
20
|
|
21
|
* Create a new field (type "Term reference") and select
|
22
|
"Simple hierarchical select" as widget type.
|
23
|
|
24
|
* Field settings
|
25
|
- "Allow creating new terms"
|
26
|
Terms may be created directly from within the dropdowns (user needs to have
|
27
|
permission to create terms in the vocabulary).
|
28
|
- "Allow creating new levels"
|
29
|
If selected users with permission to create terms in the vocabulary will be
|
30
|
able to create a new term as child of the currently selected term.
|
31
|
- "Force selection of deepest level"
|
32
|
Force users to select terms from the deepest level.
|
33
|
|
34
|
* Views (exposed filter)
|
35
|
- add a new filter using the field set-up as "Simple hierarchical select" or
|
36
|
use "Content: Has taxonomy terms (with depth; Simple hierarchical select)"
|
37
|
as a new filter
|
38
|
- use "Simple hierarchical select" as selection type
|
39
|
- select "Expose this filter to visitors, to allow them to change it"
|
40
|
- enjoy :)
|
41
|
|
42
|
|
43
|
-- INTEGRATION WITH OTHER MODULES --
|
44
|
|
45
|
* Chosen (http://drupal.org/project/chosen)
|
46
|
- If you have installed the module "Chosen" (>= 7.x-2.x) all elements of
|
47
|
"Simple hierarchical select" are modified, so the user can search for items
|
48
|
within the list. See http://drupal.org/project/chosen for more information.
|
49
|
- If you have configured "Chosen" to apply always but do not want to apply it
|
50
|
to the dropdowns created by "Simple hierarchical select" you may use the
|
51
|
following CSS selector in the "Chosen" configuration:
|
52
|
<code>select:visible:not(.shs-select)</code>
|
53
|
- Apart from that you can select whether to use chosen on a per-field base by
|
54
|
setting the option "Output this field with Chosen" in the field
|
55
|
configuration.
|
56
|
- "let chosen decide"
|
57
|
The field is modified by Chosen if it matches the Chosen configuration.
|
58
|
- "always"
|
59
|
The field is always modified by Chosen.
|
60
|
- "never"
|
61
|
The field is not modified by Chosen even if it matches the Chosen
|
62
|
configuration.
|
63
|
|
64
|
* High-performance JavaScript callback handler (http://drupal.org/project/js)
|
65
|
- If you have lots of terms and a huge hierarchy you could increase the
|
66
|
performance of "Simple hierarchical select" by installing "JS". It routes
|
67
|
all javascript callbacks needed by "Simple hierarchical select" through a
|
68
|
custom handler to avoid loading of all Drupal functions and speed up
|
69
|
loading.
|
70
|
|
71
|
* Entity reference (https://www.drupal.org/project/entityreference)
|
72
|
- "Simple hierarchical select" works out of the box with simple entity
|
73
|
reference fields. In case you use Views as entity selection mode for your
|
74
|
field there may be some problems, though.
|
75
|
Your reference view needs at least one filter for the vocabulary. Otherwise
|
76
|
"Simple hierarchical select" has no chance to retrieve the list of possible
|
77
|
options to display.
|
78
|
More complex reference views may cause "Simple hierarchical select" to fail,
|
79
|
so its best to keep it as simple as possible.
|
80
|
|
81
|
|
82
|
-- CONTACT --
|
83
|
|
84
|
Current maintainers:
|
85
|
* Stefan Borchert (stborchert) - http://drupal.org/user/36942
|
86
|
|
87
|
This project has been sponsored by:
|
88
|
* undpaul
|
89
|
Drupal experts providing professional Drupal development services.
|
90
|
Visit http://www.undpaul.de for more information.
|
91
|
|