JCollection Homepage

  • Increase font size
  • Default font size
  • Decrease font size
Home Forum
Welcome, Guest
Please Login or Register.    Lost Password?

Warning when I want to see a list
(1 viewing) (1) Guest
Bugs in JCollection 0.9.x beta/1.x
Go to bottomPage: 1
TOPIC: Warning when I want to see a list
#280
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
Beutelbär
Posts: 23
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#281
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.
tcriess
Posts: 224
graph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#282
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%" />';
}
Beutelbär
Posts: 23
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#283
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!
Beutelbär
Posts: 23
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#284
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!
Beutelbär
Posts: 23
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#286
Re: Warning when I want to see a list 6 Months, 3 Weeks ago  
Ok, glad it works now
tcriess
Posts: 224
graph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
Go to topPage: 1

Donations

If you like JCollection, please consider a small donation to help developing the component. If you don't have a PayPal account and still wish to donate, feel free to send an Amazon.de gift certificate (to thorsten.riess@sh-riess.de). Thank you very much!

Amount: 

Flattr

Advertisement