|
Warning when I want to see a list 6 Months, 3 Weeks ago
|
|
|
Hello!
In the list- module (and at the top of each item descritption) there is this link like "recently read" (or "Lists: recently read"). So when I click on this link then the list doesn't appear but this message:
Warning: Invalid argument supplied for foreach() in /srv/www/htdocs/XXX/html/XXX/components/com_jcollection/views/list/tmpl/default.php on line 22
It used to work but for any reason it doesn't work now.
First I thought it was my fault since I changed a little the code (I didn't want to have this link in the list module) but after I have changed it back the problem was still there.
Any ideas?
Best
Andy
|
|
|
|
|
|
|
Re: Warning when I want to see a list 6 Months, 3 Weeks ago
|
|
|
Hi,
mh, no idea... could you paste some of the code lines? There is no "foreach" statement anywhere near line 22, that confuses me a bit.
Best,
Thorsten.
|
|
|
|
|
|
|
Re: Warning when I want to see a list 6 Months, 3 Weeks ago
|
|
|
Line 16- 30
//$link = JRoute::_("index.php?option=com_jcollection&view=list&id=".$items->slug);
$link = JRoute::_( JCollectionHelperRoute::getListRoute( $items->slug ) );
}
//echo "<a href=\"".$link."\">".htmlspecialchars( $items->name )."</a>\n";
?>
<?php foreach ( $items->items as $item ) {
$info = &$item->infos[0];
?>
<div style="width:100%;padding-bottom:0.5em;padding-top:0.5em;border-top:1px solid;border-color:#333333"><?php
//$link = JRoute::_( "index.php?option=com_jcollection&view=item&id=".$item->slug );
$link = JRoute::_( JCollectionHelperRoute::getItemRoute( $item->slug ) );
if( $show_image && $item->image ) {
echo '<img src="'.$item->image.'" alt="'.htmlspecialchars( $item->name ).'" style="float:left;margin-left:5px;margin-right:3px;width:20%;" width="20%" />';
}
|
|
|
|
|
|
|
Re: Warning when I want to see a list 6 Months, 3 Weeks ago
|
|
|
oh... I guess I know the problem... looks like I have overwritten the wrong file!
|
|
|
|
|
|
|
Re: Warning when I want to see a list 6 Months, 3 Weeks ago
|
|
|
well... forget about my problem... as I expected I have overwritten the wrong file!
|
|
|
|
|
|
|
Re: Warning when I want to see a list 6 Months, 3 Weeks ago
|
|
Ok, glad it works now 
|
|
|
|
|
|
|