-
Notifications
You must be signed in to change notification settings - Fork 54
Expand file tree
/
Copy pathdefault.php
More file actions
69 lines (65 loc) · 2.6 KB
/
Copy pathdefault.php
File metadata and controls
69 lines (65 loc) · 2.6 KB
1
2
3
4
5
6
7
8
9
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<?php
/**
* @version SEBLOD 3.x Core ~ $Id: default.php sebastienheraud $
* @package SEBLOD (App Builder & CCK) // SEBLOD nano (Form Builder)
* @url https://www.seblod.com
* @editor Octopoos - www.octopoos.com
* @copyright Copyright (C) 2009 - 2017 SEBLOD. All Rights Reserved.
* @license GNU General Public License version 2 or later; see _LICENSE.php
**/
defined( '_JEXEC' ) or die;
if ( $show_list_title ) {
$tag = $tag_list_title;
$class = trim( $class_list_title );
$class = $class ? ' class="'.$class.'"' : '';
echo '<'.$tag.$class.'>' . @$search->title . '</'.$tag.'>';
}
if ( $description != '' ) {
$description = JHtml::_( 'content.prepare', $description );
if ( !( $tag_desc == 'p' && strpos( $description, '<p>' ) === false ) ) {
$tag_desc = 'div';
}
$description = '<'.$tag_desc.' class="cck_module_desc'.$class_sfx.'">' . $description . '</'.$tag_desc.'>';
if ( $tag_desc == 'div' ) {
$description .= '<div class="clr"></div>';
}
}
if ( $show_list_desc == 1 && $description != '' ) {
echo $description;
}
if ( ( JCck::getConfig_Param( 'validation', 2 ) > 1 ) && $config['validation'] != '' ) {
Helper_Include::addValidation( $config['validation'], $config['validation_options'], $formId );
$js = 'if ( jQuery("#'.$formId.'").validationEngine("validate",task) === true ) { JCck.Core.submitForm("search", document.getElementById("'.$formId.'")); }';
} else {
$js = 'JCck.Core.submitForm("search", document.getElementById("'.$formId.'"));';
}
?>
<script>
<?php echo $config['submit']; ?> = function(task) { <?php echo $js; ?> }
</script>
<?php
echo ( $config['action'] ) ? $config['action'] : '<form action="'.( $action_url ? $action_url : JRoute::_( 'index.php?option=com_cck'.$action_vars ) ).'" autocomplete="off" method="get" id="'.$formId.'" name="'.$formId.'">';
echo ( $raw_rendering ) ? $form : '<div class="cck_module_search'.$class_sfx.'">' . $form . '</div>';
?>
<?php if ( !$raw_rendering ) { ?>
<div class="clr"></div>
<div>
<?php } ?>
<input type="hidden" name="search" value="<?php echo $preconfig['search']; ?>" />
<input type="hidden" name="task" value="search" />
<?php if ( !JFactory::getConfig()->get( 'sef' ) ) { ?>
<input type="hidden" name="option" value="com_cck" />
<input type="hidden" name="view" value="list" />
<?php if ( $params->get( 'menu_item', '' ) ) { ?>
<input type="hidden" name="Itemid" value="<?php echo $params->get( 'menu_item', '' ); ?>" />
<?php } ?>
<?php } ?>
<?php if ( !$raw_rendering ) { ?>
</div>
<?php } ?>
</form>
<?php
if ( $show_list_desc == 2 && $description != '' ) {
echo $description;
}
?>