- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
- 31
- 32
- 33
- 34
function ***_helper_form_alter(&$form, &$form_state, $form_id) {
if(substr($form_id, -9) == 'node_form') { // Make sure this stuff only happens for node edit forms.
// make helpful menus items available for editors on season types
if(isset($form['#node']->type) && $form['#node']->type == 'season') {
$form['field_menu_items'][0]['#description'] = 'Cut and paste the text in the blue box below into field above for menu items.<br />
(You must have created and submitted the season first, and the links below should look like "/show-name/season-#/link".)<br />
Delete items you don\'t wish to appear: The second section of the code is for items below the dotted line.<br />
<div style="margin:15px;border:1px solid #0CA2FF;padding:10px;">
<li><a href="/'.$form['#node']->path.'/about">About</a></li><br />
<li><a href="/'.$form['#node']->path.'/bios">Bios</a></li><br />
<li><a href="/'.$form['#node']->path.'/blogs">Blogs</a></li><br />
<li><a href="/'.$form['#node']->path.'/episodes">Episodes</a></li><br />
<li><a href="/'.$form['#node']->path.'/games">Games</a></li><br />
<li><a href="/'.$form['#node']->path.'/photos">Photos</a></li><br />
<li><a href="/'.$form['#node']->path.'/videos">Videos</a></li><br /><br />
<!-- Use code below for additional menu items: --><br /><br />
</ul><ul class="season-extras"><br />
<li><a href="http://games.***.com/">Full URL needed if not on www.***.com</a></li><br />
<li><a href="/top-chef/diet-dr-pepper-challenge">Dr. Pepper Challenge</a></li><br />
<li><a href="/foodies/recipe-finder">Recipe Finder</a></li><br /><br />
<!-- Use code below for the "flyout" navigation: --><br /><br />
<li><a href="/tweettracker">Talk</a><br />
<ul> <br />
<div class="separator" style="float: left;"><br />
<li><a href="/tweettracker">Tweet Tracker</a></li><br />
<li><a href="/tweetbattle">Tweet Battles</a></li><br />
<li><a href="/iwanttobeahousewife">Just Saying</a></li><br />
</div><br />
</ul><br />
</li><br />
</div>';
}
Phabyd 13.02.2012 23:02 # +1
Phabyd 13.02.2012 23:05 # +1
guest 14.02.2012 09:50 # 0
Глаза нужно было закрыть.
guest 18.02.2012 01:14 # 0
guest8 09.04.2019 12:41 # −999
macaque_gomosek 25.08.2021 06:18 # 0