123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- With the <strong>jump menu</strong> style can you create selectbox menus for the content of your site.
- <a href="path:images/views3-jump-style-menu.png"><img src="path:images/views3-jump-style-menu.png" /></a>
- The <strong>jump menu</strong> style will display each row of your view within a jump menu. This style requires that your view's <a href="topic:views/style-row">row style</a> is set to <a href="topic:views/style-fields">fields</a>.
- To properly configure a jump menu, you must select one field that will represent the path to utilize. In most cases, you will need to rewrite the output of this field. You should set that field to exclude from display. All other displayed fields will be part of the menu. Please note that all HTML will be stripped from this output as select boxes cannot show HTML.
- Some examples of how this might be useful:
- <h3>Jump to a node</h3>
- <ol>
- <li>Create a new <strong>Node</strong> view</li>
- <li>Select the <strong>Node: Path</strong> and <strong>Node: Title</strong> fields</li>
- <li>Configure the <strong>Node: Path</strong> field to "exclude from display" and check "Use absolute link"</li>
- <li>Configure the <strong>Node: Title</strong> field by removing the "Label" and unchecking "Link this field to its node"</li>
- <li>Set the view style to <strong>jump menu</strong></li>
- <li>In the style settings, set the "Path field" to <strong>Node: Path</strong></li>
- </ol>
- Your view will now display with a select list and a <strong>Go</strong> button. If you select an item in the list and hit the <strong>Go</strong> button you will see the selected node's page in the browser.
- <h3>Jump to a node's edit page</h3>
- <ol>
- <li>Create a new <strong>Node</strong> view</li>
- <li>Select the <strong>Node: Nid</strong> and <strong>Node: Title</strong> fields</li>
- <li>Configure the <strong>Node: Nid</strong> field to "exclude from display" and check "Rewrite the output of this field"</li>
- <li>In the text field that appears for rewriting the output of this field, enter <strong>node/[nid]/edit</strong></li>
- <li>Configure the <strong>Node: Title</strong> field by removing the "Label" and unchecking "Link this field to its node"</li>
- <li>Set the view style to <strong>jump menu</strong></li>
- <li>In the style settings, set the "Path field" to <strong>Node: Nid</strong></li>
- </ol>
- Your view will now display with a select list and a <strong>Go</strong> button. If you select an item in the list and hit the <strong>Go</strong> button you will see the selected node's edit page in the browser. Please note that users without rights to the node's edit page will see an access denied message.
- <h3>Jump to a user profile</h3>
- <ol>
- <li>Create a new <strong>User</strong> view</li>
- <li>Select the <strong>User: Uid</strong> and <strong>User: Name</strong> fields</li>
- <li>Configure the <strong>User: Uid</strong> field to "exclude from display" and check "Rewrite the output of this field"</li>
- <li>In the text field that appears for rewriting the output of this field, enter <strong>user/[uid]</strong></li>
- <li>Configure the <strong>User: Name</strong> field by removing the "Label" and unchecking "Link this field to its user"</li>
- <li>Set the view style to <strong>jump menu</strong></li>
- <li>In the style settings, set the "Path field" to <strong>User: Uid</strong></li>
- </ol>
- Your view will now display with a select list and a <strong>Go</strong> button. If you select an item in the list and hit the <strong>Go</strong> button you will see the selected user's profile page in the browser.
|