blue-mouse
Member
Hi,
I have Joomla 2.5 and fabrik 3.0.9.
I have made my custom calculation on my list1 using custom template for list. In file default.php i have code:
Problem is for case:
if (!(isset($order1))) {
$zam1 = "Razem wszystkie zam?wienia";
I get an notice error:
Notice: Undefined offset: 0 in /var/www/cc.joomla/components/com_fabrik/helpers/element.php on line 91
---- Zam?wienie nr: Razem wszystkie zam?wienia ----
I have no idea how to clean/remove this error notice.
I try also:
but also for case:
if ($order1==0){
$zam1 = 'Razem wszystkie zam?wienia';
}
i get the same error notice.
line 91 is in fabrik file:
/var/www/cc.joomla/components/com_fabrik/helpers/element.php
is
line 91 ---- $value = $filters['value'][$index];
sample of this code with line 91 is:
This error notice appear when in Joomla configurations is set : error reporting = maximum
for error reporting = System Default this error notice doesn't appear.
I need use for my Joomla error reporting = maximum and need remove this error-notice.
Can i get any help?
I have Joomla 2.5 and fabrik 3.0.9.
I have made my custom calculation on my list1 using custom template for list. In file default.php i have code:
PHP:
<td colspan="5"><table class="rysio1">
<?php $j=0;
echo '<tr class="fabrik_calculations">';
echo "<td>";
$db =& JFactory::getDBO();
$order1 =FabrikHelperElement::filterValue(11152); //with 81
echo "<br/>";
if (isset($order1)) {
$query = "SELECT `ip2_zamowienie_symbol1` FROM `ccjom_cc_kk_ip2_zamowienie` WHERE `id`= ".$order1." ";
$db->setQuery($query);
$result = $db->loadResult();
$zam1 = $result;
}
if (!(isset($order1))) {
$zam1 = "Razem wszystkie zam?wienia";
}
echo " ---- <strong><font color='blue'> Zam?wienie nr: $zam1 </font></strong> ---- <br/><br/>";
echo "</td>";
Problem is for case:
if (!(isset($order1))) {
$zam1 = "Razem wszystkie zam?wienia";
I get an notice error:
Notice: Undefined offset: 0 in /var/www/cc.joomla/components/com_fabrik/helpers/element.php on line 91
---- Zam?wienie nr: Razem wszystkie zam?wienia ----
I have no idea how to clean/remove this error notice.
I try also:
PHP:
$db =& JFactory::getDBO();
$order1 =FabrikHelperElement::filterValue(11152); //with 81
if ($order1==0){
$zam1 = 'Razem wszystkie zam?wienia';
}
else {
$query = "SELECT `ip2_zamowienie_symbol1` FROM `ccjom_cc_kk_ip2_zamowienie` WHERE `id`= ".$order1." ";
$db->setQuery($query);
$result = $db->loadResult();
$zam1 = $result;
}
echo " -- Zam?wienie nr: $zam1 -- <br/><br/>";
but also for case:
if ($order1==0){
$zam1 = 'Razem wszystkie zam?wienia';
}
i get the same error notice.
line 91 is in fabrik file:
/var/www/cc.joomla/components/com_fabrik/helpers/element.php
is
line 91 ---- $value = $filters['value'][$index];
sample of this code with line 91 is:
PHP:
public static function filterValue($elementId)
{
$app = JFactory::getApplication();
$pluginManager = FabrikWorker::getPluginManager();
$model = $pluginManager->getElementPlugin($elementId);
$listModel = $model->getListModel();
$listid = $listModel->getId();
$key = 'com_fabrik.list' . $listid . '_com_fabrik_' . $listid . '.filter';
$filters = JArrayHelper::fromObject($app->getUserState($key));
$elementIds = (array) JArrayHelper::getValue($filters, 'elementid', array());
$index = array_search($elementId, $elementIds);
$value = $filters['value'][$index];
return $value;
}
This error notice appear when in Joomla configurations is set : error reporting = maximum
for error reporting = System Default this error notice doesn't appear.
I need use for my Joomla error reporting = maximum and need remove this error-notice.
Can i get any help?