OSDN Git Service

初回コミット(v2.6.17.1)
[magic3/magic3.git] / templates / art26_test1 / html / mod_menu / default_url.php
1 <?php
2
3 defined('_JEXEC') or die;
4
5 // Note. It is important to remove spaces between elements.
6 $attributes = array(
7         'class' => array($item->params->get('menu-anchor_css', '')),
8         'title' => $item->params->get('menu-anchor_title', ''),
9         'href' => $item->flink);
10
11 switch ($item->browserNav) {
12     case 1:
13         // _blank
14                 $attributes['target'] = '_blank';
15         break;
16     case 2:
17         // window.open
18                 $attributes['onclick'] = 'window.open(this.href,\'targetWindow\','
19             . '\'toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes\');return false;';
20         break;
21 }
22
23 $linktype = $item->params->get('menu_image', '')
24         ? ('<img src="' . $item->params->get('menu_image', '') . '" alt="' . $item->title . '" />'
25                 . ($item->params->get('menu_text', 1) ? '<span class="image-title">' . $item->title . '</span> ' : ''))
26         : $item->title;
27
28 if ('horizontal' == $menutype || 'vertical' == $menutype) {
29         if ($params->get('startLevel') == $item->level)
30                 $linktype = '<span class="l"></span><span class="r"></span><span class="t">' . $linktype . '</span>';
31 }
32 echo artxTagBuilder('a', $attributes, $linktype);