i thought it was my hoster server issue
i enabled debug ..this error is displayed
Quote:
Warning: Division by zero in file /home/portal_users/xxx/xxx_data/caches/smarty_compile/05d3d339-xlanguage-mytheme-default^%%D6^D6E^D6E59BDD%%db%3Axlanguage_block.html.php line 27
Warning: Division by zero in file /home/portal_users/xxx/xxx_data/caches/smarty_compile/05d3d339-xlanguage-mytheme-default^%%D6^D6E^D6E59BDD%%db%3Axlanguage_block.html.php line 27
this is line 27
<?php if ($this->_foreach['lang_it']['iteration'] % $this->_tpl_vars['block']['number'] == 0): ?>|<?php endif; ?>
this is the whole file xlanguage_block.html
<?php /* Smarty version 2.6.26, created on 2011-09-18 11:25:04
compiled from db:xlanguage_block.html */ ?>
<?php if ($this->_tpl_vars['block']['display'] == 'images' || $this->_tpl_vars['block']['display'] == 'text'): ?>
<?php $_from = $this->_tpl_vars['block']['languages']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }$this->_foreach['lang_it'] = array('total' => count($_from), 'iteration' => 0);
if ($this->_foreach['lang_it']['total'] > 0):
foreach ($_from as $this->_tpl_vars['lang']):
$this->_foreach['lang_it']['iteration']++;
?>
<a href="<?php echo $this->_tpl_vars['block']['url']; ?>
<?php echo $this->_tpl_vars['lang']['name']; ?>
" title="<?php echo $this->_tpl_vars['lang']['desc']; ?>
">
<?php if ($this->_tpl_vars['block']['display'] == 'images'): ?>
<img src="<?php echo $this->_tpl_vars['lang']['image']; ?>
" alt="<?php echo $this->_tpl_vars['lang']['desc']; ?>
"
<?php if ($this->_tpl_vars['block']['selected'] != $this->_tpl_vars['lang']['name']): ?>
style="MozOpacity: .8; opacity: .8; filter:Alpha(opacity=80);"
<?php endif; ?>
/>
<?php else: ?>
<?php echo $this->_tpl_vars['lang']['desc']; ?>
<?php endif; ?>
</a>
<?php if ($this->_foreach['lang_it']['iteration'] % $this->_tpl_vars['block']['number'] == 0): ?>|<?php endif; ?>
<?php endforeach; endif; unset($_from); ?>
<?php else: ?>
<select name="selectlang"
onChange="if(this.options[this.selectedIndex].value.length >0 ) { window.document.location=this.options[this.selectedIndex].value;}"
>
<?php $_from = $this->_tpl_vars['block']['languages']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }$this->_foreach['lang_it'] = array('total' => count($_from), 'iteration' => 0);
if ($this->_foreach['lang_it']['total'] > 0):
foreach ($_from as $this->_tpl_vars['lang']):
$this->_foreach['lang_it']['iteration']++;
?>
<option value="<?php echo $this->_tpl_vars['block']['url']; ?>
<?php echo $this->_tpl_vars['lang']['name']; ?>
"
<?php if ($this->_tpl_vars['block']['selected'] == $this->_tpl_vars['lang']['name']): ?>selected<?php endif; ?>
><?php echo $this->_tpl_vars['lang']['desc']; ?>
</option>
<?php endforeach; endif; unset($_from); ?>
</select>
<?php endif; ?>
How to fix this
Im using
Quote:
xlanguage 3.11
XOOPS Version XOOPS 2.5.2
PHP Version 5.3.6
mySQL Version 5.1.56
Server API cgi-fcgi
OS Linux
safe_mode Off
register_globals Off
magic_quotes_gpc On
allow_url_fopen Off
fsockopen On
post_max_size 8M
max_input_time 60
output_buffering
max_execution_time 30
memory_limit 32M
file_uploads On
upload_max_filesize 5M