OSDN Git Service

初回コミット(v2.6.17.1)
[magic3/magic3.git] / templates / art41_sample1 / html / mod_search / default.php
1 <?php
2 /**
3  * @package             Joomla.Site
4  * @subpackage  mod_search
5  * @copyright   Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved.
6  * @license             GNU General Public License version 2 or later; see LICENSE.txt
7  */
8
9 // no direct access
10 defined('_JEXEC') or die;
11 ?>
12 <form action="<?php echo JRoute::_('index.php');?>" class="art-search" method="post">
13         <div class="search<?php echo $moduleclass_sfx ?>">
14                 <?php
15                         $output = '<label for="mod-search-searchword">'.$label.'</label><input name="searchword" id="mod-search-searchword" maxlength="'.$maxlength.'"  class="inputbox'.$moduleclass_sfx.'" type="text" size="'.$width.'" value="'.$text.'"  onblur="if (this.value==\'\') this.value=\''.$text.'\';" onfocus="if (this.value==\''.$text.'\') this.value=\'\';" />';
16                         if ($button) :
17                                 if ($imagebutton) :
18                                         $button = '<input type="image" value="'.$button_text.'" class="button art-search-button '.$moduleclass_sfx.'" src="'.$img.'" onclick="this.form.searchword.focus();"/>';
19                                 else :
20                                         $button = '<input type="submit" value="'.$button_text.'" class="button art-search-button '.$moduleclass_sfx.'" onclick="this.form.searchword.focus();"/>';
21                                 endif;
22                         endif;
23
24                         switch ($button_pos) :
25                                 case 'top' :
26                                         $button = $button.'<br />';
27                                         $output = $button.$output;
28                                         break;
29
30                                 case 'bottom' :
31                                         $button = '<br />'.$button;
32                                         $output = $output.$button;
33                                         break;
34
35                                 case 'right' :
36                                         $output = $output.$button;
37                                         break;
38
39                                 case 'left' :
40                                 default :
41                                         $output = $button.$output;
42                                         break;
43                         endswitch;
44
45                         echo $output;
46                 ?>
47         <input type="hidden" name="task" value="search" />
48         <input type="hidden" name="option" value="com_search" />
49         <input type="hidden" name="Itemid" value="<?php echo $mitemid; ?>" />
50         </div>
51 </form>