Buongiorno,
ho installato con successo il componente JEA ( è un componente per real estate) ho settato tutto, il componente sono riuscito a metterlo in italiano. Ho solamente un problema con il form di ricerca... Non riesco a sistemarlo graficamente...
Dal codice PHP sembra settato bene e senza spazi poi in visualizzazione invece manda a capo i campi..
Allego codice php e css
<?php
/**
* This file is part of Joomla Estate Agency - Joomla! extension for real estate agency
*
* @version $Id: search.php 450 2014-01-26 14:07:06Z ilhooq $
* @package Joomla.Site
* @subpackage com_jea
* @copyright Copyright (C) 2008 - 2012 PHILIP Sylvain. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
// no direct access
defined('_JEXEC') or die('Restricted access');
JHtml::stylesheet('media/com_jea/css/jea.css');
JHtml::addIncludePath(JPATH_COMPONENT_ADMINISTRATOR.'/helpers/html');
JHtml::addIncludePath(JPATH_COMPONENT.'/helpers/html');
$useAjax = $this->params->get('searchform_use_ajax', 0);
$transationType = $this->params->get('searchform_transaction_type');
$showLocalization = $this->params->get('searchform_show_departments')
|| $this->params->get('searchform_show_towns')
|| $this->params->get('searchform_show_areas')
|| $this->params->get('searchform_show_zip_codes');
$showOtherFilters = $this->params->get('searchform_show_number_of_rooms')
|| $this->params->get('searchform_show_number_of_bedrooms')
|| $this->params->get('searchform_show_number_of_bathrooms')
|| $this->params->get('searchform_show_floor')
|| $this->params->get('searchform_show_hotwatertypes')
|| $this->params->get('searchform_show_heatingtypes')
|| $this->params->get('searchform_show_conditions')
|| $this->params->get('searchform_show_orientation');
$states = array();
$filters = $this->get('Filters');
foreach ($filters as $name => $defaultValue) {
$states['filter_'.$name] = $this->state->get('filter.'.$name, $defaultValue);
}
if (empty($transationType) && empty($states['filter_transaction_type'])) {
// Set SELLING as default transaction_type state
$states['filter_transaction_type'] = 'SELLING';
} elseif (!empty($transationType) && empty($states['filter_transaction_type'])) {
$states['filter_transaction_type'] = $transationType;
}
$fields = json_encode($states);
$ajax = $useAjax? 'true': 'false';
JHTML::script('media/com_jea/js/search.js', true);
$this->document->addScriptDeclaration("
window.addEvent('domready', function() {
var jeaSearch = new JEASearch('jea-search-form', {fields:$fields, useAJAX:$ajax});
jeaSearch.refresh();
});");
?>
<?php if ($this->params->get('show_page_heading', 1)) : ?>
<?php if ($this->params->get('page_heading')) : ?>
<h1><?php echo $this->escape($this->params->get('page_heading')) ?></h1>
<?php else: ?>
<h1><?php echo $this->escape($this->params->get('page_title')) ?></h1>
<?php endif ?>
<?php endif ?>
<form action="<?php echo JRoute::_('index.php?option=com_jea&task=properties.search') ?>" method="post" id="jea-search-form">
<?php if ($this->params->get('searchform_show_freesearch')): ?>
<label for="jea-search"><?php echo JText::_('COM_JEA_SEARCH_LABEL')?> : </label>
<input type="text" name="filter_search" id="jea-search" value="<?php echo $states['filter_search'] ?>" />
<input type="submit" class="button" value="<?php echo JText::_('JSEARCH_FILTER_SUBMIT')?>" />
<?php endif ?>
<?php if ($useAjax): ?>
<div class="jea-counter"><span class="jea-counter-result">0</span> <?php echo JText::_('COM_JEA_FOUND_PROPERTIES')?><>
<?php endif ?>
<?php echo JHtml::_('features.types', $this->state->get('filter.type_id', 0), 'filter_type_id') ?>
<?php if ($transationType == 'RENTING'): ?>
<input type="hidden" name="filter_transaction_type" value="RENTING" />
<?php elseif($transationType == 'SELLING'): ?>
<input type="hidden" name="filter_transaction_type" value="SELLING" />
<?php else: ?>
<input type="radio" name="filter_transaction_type" id="jea-search-selling" value="SELLING"
<?php if ($states['filter_transaction_type'] == 'SELLING') echo 'checked="checked"' ?> />
<label for="jea-search-selling"><?php echo JText::_('COM_JEA_OPTION_SELLING') ?></label>
<input type="radio" name="filter_transaction_type" id="jea-search-renting" value="RENTING"
<?php if ($states['filter_transaction_type'] == 'RENTING') echo 'checked="checked"' ?> />
<label for="jea-search-renting"><?php echo JText::_('COM_JEA_OPTION_RENTING') ?></label>
<?php endif ?>
<?php if ($showLocalization): ?>
<h2><?php echo JText::_('COM_JEA_LOCALIZATION') ?> :</h2>
<?php if ($this->params->get('searchform_show_departments', 1)): ?>
<?php echo JHtml::_('features.departments', $states['filter_department_id'], 'filter_department_id' ) ?>
<?php endif ?>
<?php if ($this->params->get('searchform_show_towns', 1)): ?>
<?php echo JHtml::_('features.towns', $states['filter_town_id'], 'filter_town_id' ) ?>
<?php endif ?>
<?php if ($this->params->get('searchform_show_areas', 1)): ?>
<?php echo JHtml::_('features.areas', $states['filter_area_id'], 'filter_area_id' ) ?>
<?php endif ?>
<?php if ($this->params->get('searchform_show_zip_codes', 1)): ?>
<label for="jea-search-zip-codes"><?php echo JText::_('COM_JEA_SEARCH_ZIP_CODES') ?> : </label>
<input id="jea-search-zip-codes" type="text" name="filter_zip_codes" size="20" value="<?php echo $states['filter_zip_codes'] ?>" />
<?php echo JText::_('COM_JEA_SEARCH_ZIP_CODES_DESC') ?>
<?php endif ?>
<?php endif ?>
<ul class="jea-search-other">
<?php if ($this->params->get('searchform_show_budget', 1)): ?>
<li>
<h2><?php echo JText::_('COM_JEA_BUDGET') ?> :</h2><?php echo JText::_('COM_JEA_MIN') ?> :
<input id="jea-search-budget-min" type="text" name="filter_budget_min"
size="5" value="<?php echo $states['filter_budget_min'] ?>" />
<?php echo $this->params->get('currency_symbol', '€') ?></li><li>
<?php echo JText::_('COM_JEA_MAX') ?> :
<input id="jea-search-budget-max" type="text" name="filter_budget_max"
size="5" value="<?php echo $states['filter_budget_max'] ?>" />
<?php echo $this->params->get('currency_symbol', '€') ?></li>
<?php endif ?>
</ul>
<?php if ($this->params->get('searchform_show_living_space', 1)): ?>
<h2><?php echo JText::_('COM_JEA_FIELD_LIVING_SPACE_LABEL') ?> :</h2>
<?php echo JText::_('COM_JEA_MIN') ?> :
<input id="jea-search-living-space-min" type="text" name="filter_living_space_min"
size="5" value="<?php echo $states['filter_living_space_min'] ?>" />
<?php echo $this->params->get( 'surface_measure' ) ?>
<?php echo JText::_('COM_JEA_MAX') ?> :
<input id="jea-search-living-space-max" type="text" name="filter_living_space_max"
size="5" value="<?php echo $states['filter_living_space_max'] ?>" />
<?php echo $this->params->get( 'surface_measure' ) ?>
<?php endif ?>
<?php if ($this->params->get('searchform_show_land_space', 1)): ?>
<h2><?php echo JText::_('COM_JEA_FIELD_LAND_SPACE_LABEL') ?> :</h2>
<label for="jea-search-land-space-min"><?php echo JText::_('COM_JEA_MIN') ?> : </label><input id="jea-search-land-space-min" type="text" name="filter_land_space_min"
size="5" value="<?php echo $states['filter_land_space_min'] ?>" />
<?php echo $this->params->get( 'surface_measure' ) ?>
<label for="jea-search-land-space-max"><?php echo JText::_('COM_JEA_MAX') ?> : </label>
<input id="jea-search-land-space-max" type="text" name="filter_land_space_max"
size="5" value="<?php echo $states['filter_land_space_max'] ?>" />
<?php echo $this->params->get( 'surface_measure' ) ?>
<?php endif ?>
<?php if ($showOtherFilters): ?>
<h2><?php echo JText::_('COM_JEA_SEARCH_OTHER') ?> :</h2>
<ul class="jea-search-other">
<?php if ($this->params->get('searchform_show_number_of_rooms', 1)): ?>
<li>
<label for="jea-search-rooms"><?php echo JText::_('COM_JEA_NUMBER_OF_ROOMS_MIN') ?> : </label>
<input id="jea-search-rooms" type="text" name="filter_rooms_min"
size="2" value="<?php echo $states['filter_rooms_min'] ?>" />
</li>
<?php endif?>
<?php if ($this->params->get('searchform_show_number_of_bedrooms', 1)): ?>
<li>
<label for="jea-search-bedrooms"><?php echo JText::_('COM_JEA_NUMBER_OF_BEDROOMS_MIN') ?> : </label>
<input id="jea-search-bedrooms" type="text" name="filter_bedrooms_min"
size="2" value="<?php echo $states['filter_bedrooms_min'] ?>" />
</li>
<?php endif?>
<?php if ($this->params->get('searchform_show_number_of_bathrooms', 0)): ?>
<li>
<label for="jea-search-bathrooms"><?php echo JText::_('COM_JEA_NUMBER_OF_BATHROOMS_MIN') ?> : </label>
<input id="jea-search-bathrooms" type="text" name="filter_bathrooms_min"
size="2" value="<?php echo $states['filter_bathrooms_min'] ?>" />
</li>
<?php endif?>
<?php if ($this->params->get('searchform_show_floor', 1)): ?>
<li>
<label for="jea-search-floor"><?php echo JText::_('COM_JEA_FIELD_FLOOR_LABEL') ?> : </label>
<input id="jea-search-floor" type="text" name="filter_floor" size="2" value="<?php echo $states['filter_floor'] ?>" />
<?php echo JText::_('COM_JEA_SEARCH_FLOOR_DESC') ?>
</li>
<?php endif?>
<?php if ($this->params->get('searchform_show_hotwatertypes', 0)): ?>
<li><?php echo JHtml::_('features.hotwatertypes', $states['filter_hotwatertype'], 'filter_hotwatertype' ) ?></li>
<?php endif?>
<?php if ($this->params->get('searchform_show_heatingtypes', 0)): ?>
<li><?php echo JHtml::_('features.heatingtypes', $states['filter_heatingtype'], 'filter_heatingtype' ) ?></li>
<?php endif?>
<?php if ($this->params->get('searchform_show_conditions', 0)): ?>
<li><?php echo JHtml::_('features.conditions', $states['filter_condition'], 'filter_condition' ) ?></li>
<?php endif?>
<?php if ($this->params->get('searchform_show_orientation', 1)): ?>
<li>
<?php
$options = array(
JHTML::_('select.option', '0', ' - ' . JText::_('COM_JEA_FIELD_ORIENTATION_LABEL') . ' - ' ),
JHTML::_('select.option', 'N', JText::_('COM_JEA_OPTION_NORTH')),
JHTML::_('select.option', 'NW', JText::_('COM_JEA_OPTION_NORTH_WEST')),
JHTML::_('select.option', 'NE', JText::_('COM_JEA_OPTION_NORTH_EAST')),
JHTML::_('select.option', 'NS', JText::_('COM_JEA_OPTION_NORTH_SOUTH')),
JHTML::_('select.option', 'E', JText::_('COM_JEA_OPTION_EAST')),
JHTML::_('select.option', 'EW', JText::_('COM_JEA_OPTION_EAST_WEST')),
JHTML::_('select.option', 'W', JText::_('COM_JEA_OPTION_WEST')),
JHTML::_('select.option', 'S', JText::_('COM_JEA_OPTION_SOUTH')),
JHTML::_('select.option', 'SW', JText::_('COM_JEA_OPTION_SOUTH_WEST')),
JHTML::_('select.option', 'SE', JText::_('COM_JEA_OPTION_SOUTH_EAST'))
);
echo JHTML::_('select.genericlist', $options, 'filter_orientation', 'size="1"', 'value', 'text', $states['filter_orientation'])
?>
</li>
<?php endif?>
</ul>
<?php endif ?>
<?php if ($this->params->get('searchform_show_amenities', 1)): ?>
<h2><?php echo JText::_('COM_JEA_AMENITIES') ?> :</h2>
<div class="amenities">
<?php echo JHtml::_('amenities.checkboxes', $states['filter_amenities'], 'filter_amenities' ) ?>
<?php // In order to prevent nul post for this field ?>
<input type="hidden" name="filter_amenities[]" value="0" />
<>
<?php endif ?>
<?php if ($useAjax): ?>
<div class="jea-counter"><span class="jea-counter-result">0</span> <?php echo JText::_('COM_JEA_FOUND_PROPERTIES')?><>
<?php endif ?>
<input type="reset" class="button" value="<?php echo JText::_('JSEARCH_FILTER_CLEAR') ?>" />
<input type="submit" class="button" value="<?php echo $useAjax ? JText::_('COM_JEA_LIST_PROPERTIES') : JText::_('JSEARCH_FILTER_SUBMIT')?>" />
</form>
questo è il css
.clr {
clear: both;
}
.numberbox {
text-align:right;
padding-right:2px;
}
.right {
text-align: right;
}
/*** Properties Search layout ***/
#jea-search-form label {
display: inline !important;
}
#jea-search-form input {
width: auto !important;
}
#jea-search-form .jea-counter {
float: right;
}
#jea-search-form .jea-counter-result {
font-weight: bold;
}
#jea-search-form h2,#jea-search-form hr {
clear: both;
}
#jea-search-form hr {
margin: 1em 0;
}
#jea-search-form select {
width: 12em;
}
#jea-search-form dl {
padding: 0.5em 0;
}
#jea-search-form dl.col-left,#jea-search-form dl.col-right {
float: left;
}
#jea-search-form dl.col-left {
margin-right: 3em;
}
#jea-search-form dt,#jea-search-form dd {
margin: 0;
padding: 0;
display: table-cell;
}
#jea-search-form dt {
min-width: 5em;
}
#jea-search-form ul {
overflow: hidden;
margin: 1em 0 !important;
padding: 0 !important;
}
#jea-search-form ul.jea-search-other li {
list-style: none;
margin: 0.5em 0 !important;
padding: 0 !important;
}
#jea-search-form ul.jea-search-other label {
display: inline-block;
min-width: 13em;
}
#jea-search-form .amenities li {
width: 17em;
margin: 0 1.5em 0.5em 0 !important;
padding: 0 !important;
float: left;
list-style: none;
}
/* Properties Default layout */
.limitbox {
text-align: right;
}
dl.jea_item {
border-top: 1px dashed #ccc;
padding: 1em 0;
margin: 0;
overflow: hidden;
/* formatting context, prevent overshooting of floating */
}
dl.jea_item:FIRST-CHILD {
border-top: none;
padding-top: 0;
}
dl.jea_item dt.title {
clear: both;
margin-bottom: 0.7em;
}
dl.jea_item dt.title strong {
font-size: 1.3em;
}
dl.jea_item dt.image {
float: left;
margin-right: 1em;
}
dl.jea_item dt.image img {
border-color: #819d26;
}
dl.jea_item span.slogan {
float: right;
}
dl.jea_item span.slogan strong {
color: red;
}
/* Property Default layout */
.prev-next-navigation .previous {
display: inline-block;
margin-right: 20px;
}
.jea-tools {
float: right;
}
.jea-tools img {
border: none;
}
#jea-gallery {
margin-bottom: 10px;
}
#jea-gallery-preview.vertical , #jea-gallery-scroll.vertical {
float: left;
}
#jea-gallery-scroll.vertical {
overflow-x: hidden;
overflow-y: auto;
}
#jea-gallery-scroll.vertical img {
margin-bottom: 5px;
}
#jea-gallery-scroll.horizontal {
clear: both;
margin-top: 5px;
overflow-x: auto;
overflow-y: hidden;
white-space: nowrap;
width: 400px;
float: none;
}
#jea-gallery-scroll.horizontal img{
margin-bottom: 0;
}
#jea-gallery-scroll.horizontal br {
display: none;
}
#jea-gallery-preview {
margin-right: 15px;
}
#jea-preview-title {
font-weight: bold;
}
#jea-preview-description {
font-style: italic;
}
span.rate_frequency {
font-size: 0.9em;
font-weight: normal;
}
table.jea-data {
width: auto;
}
table.jea-data th,
table.jea-data td {
padding: 0.4em;
}
table.jea-data th {
font-weight: normal;
}
table.jea-data td {
font-weight: bold;
}
.jea-col-right {
float: right;
width: 300px;
margin-left: 2em;
padding-left: 2em;
border-left: 1px dashed #b2b4bf;
}
.property-description {
margin: 2em 0;
}
#advantages_list {
margin-bottom: 10px;
}
#jea_property_map {
width: 500px;
height: 300px;
margin-bottom: 1.5em;
}
.google-map-mask {
background: #000 url(../images/spinner.gif) center center no-repeat;
}
/*** SqueezeBox layout ***/
#jea-squeezeBox-navblock {
position: relative;
bottom: -15px;
text-align: center;
}
#jea-squeezeBox-infos {
position: absolute;
bottom: 15px;
right: 15px;
text-align: center;
background: #000;
padding: 10px;
opacity:0.8;
}
#jea-squeezeBox-title {
font-weight: bold;
color: #fff;
font-size: 13px;
}
#jea-squeezeBox-description {
color: #ddd;
font-size: 10px;
}
a#jea-squeezeBox-prev,
a#jea-squeezeBox-next {
color: #fff;
}
#jea-squeezeBox-prev {
margin-right: 10px;
}
#jea-squeezeBox-next {
margin-left: 10px;
}
a#jea-squeezeBox-prev.inactive,
a#jea-squeezeBox-next.inactive {
color: #ccc;
text-decoration: none;
background: transparent;
cursor: default;
}
form#jea-contact-form legend {
font-weight: bold;
}
form#jea-contact-form fieldset dt {
clear: both;
float: none;
padding: 3px 0;
margin: 0;
width: auto;
}
form#jea-contact-form fieldset dd {
clear: both;
float: none;
padding: 3px 0;
margin: 0 0 0.3em 0;
width: auto;
}
/*format tabular list */
table.jea_listing,table.jea_listing thead,table.jea_listing th,table.jea_listing tbody,table.jea_listing td
{
border: 1px solid #ccc;
}
table.jea_listing {
border-collapse: collapse;
}
table.jea_listing th,table.jea_listing td {
padding: 5px;
text-align: left;
}
table.jea_listing tbody th {
font-weight: bold;
}
table.jea_listing thead {
font-weight: bold;
white-space: nowrap;
text-align: left;
}
table.jea_listing tbody tr.row1 {
background: #F9F9F9;
}
table.jea_listing tbody tr:hover {
background: #FFD;
}
table.jea_listing .right {
text-align: right;
}
table.jea_listing .center {
text-align: center;
}
table.jea_listing .nowrap {
white-space: nowrap;
}
/*** Property form layout ***/
ul#amenities {
list-style: none !important;
padding: 0 !important;
margin: 0 !important;
overflow: hidden;
}
ul#amenities li {
width:200px;
margin: 0 15px 10px 0 !important;
padding: 0 !important;
float:left;
}
ul#amenities li label {
font-size: 12px;
line-height: 13px;
}
ul#amenities li input {
float:none;
margin: 0 8px 0 0;
}
ul.gallery {
margin: 10px 0 0 0 !important;
list-style: none !important;
padding: 0 !important;
}
ul.gallery li {
padding: 10px 0 10px 10px !important;
margin: 0 !important;
border-top: 1px solid #ccc !important;
}
ul.gallery li:FIRST-CHILD {
background: #FFFFCC
}
ul.gallery a.imgLink {
float: left;
margin: 0 10px 5px 0;
}
ul.gallery a.imgLink img {
float: none;
margin: 0;
}
ul.gallery .imgTools a {
cursor: pointer;
display: inline-block;
padding: 0 5px;
}
ul.gallery .imgTools a.delete-img {
margin-left: 20px;
}
ul.gallery label {
display: inline-block;
vertical-align: top;
width: 10em;
}
#found_properties {
white-space: nowrap;
}
.slider_background {
background: url("../images/slider_bg.png") center center no-repeat;
height: 20px;
width: 250px;
}
.knob {
background: url("../images/knob.png") center center no-repeat;
height: 20px;
width: 16px;
cursor: move;
}
.jea_slider_block {
float: left;
width: 250px;
margin: 10px 10px 10px 0;
}
.jea_slider_block h2 {
font-size: 12px;
font-weight: bold;
margin: 0 !important;
padding: 0 !important;
text-align: center;
}
.slider_infos {
text-align: center !important;
}
.slider_min_value {
margin-right: 10px;
}
.slider_max_value {
margin-left: 10px;
}
/* property form */
#adminForm label {
display: inline-block !important;
vertical-align: top;
width: 13em;
}
#adminForm input {
width: auto !important;
}