The Joomla! Forum ™



Forum rules


Forum Rules
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.



Post new topic Reply to topic  [ 17 posts ] 
Author Message
PostPosted: Wed Oct 01, 2008 8:14 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Sep 22, 2008 4:43 am
Posts: 44
Hi,
what this error is about ?
Warning: Invalid argument supplied for foreach() in /home/components/com_content/helpers/route.php on line 106

I've checked the file, so I understood, it could have something to do with items or articles, deleted almost everything, teste only with one or two, deleted menu items, etc

*I've created my own template, but I belive I didnt left any importat JDOC statement behind. I remember I wasnt using the "head" once, but it was solved, and the error was kind a diferent of this one.

This is happening while using "Latest News" module! I started by trying to use a free one called News Show GK, that was giving this error also!

Any help is appreciated!


Top
 Profile  
 
PostPosted: Thu Oct 02, 2008 8:01 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Sep 22, 2008 4:43 am
Posts: 44
Solved by doing the following sugestion:

http://joomlacode.org/gf/project/joomla ... m_id=12724


Top
 Profile  
 
PostPosted: Tue Jun 09, 2009 8:42 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Fri Dec 19, 2008 5:50 pm
Posts: 5
Hello,

I'm also havin this "com_content/helpers/route.php on line 106" problem. I don't understand the whole "http://joomlacode.org/gf/project/joomla ... m_id=12724" code. Could anyone please help me out in this one? I have just a little idea about writting code, so please give me a non-coder solution.
Thanks in advance.


Top
 Profile  
 
PostPosted: Wed Jun 10, 2009 4:15 am 
User avatar
Joomla! Virtuoso
Joomla! Virtuoso

Joined: Sat Sep 24, 2005 11:01 pm
Posts: 4779
Location: Toronto, Canada
CarlitosWay wrote:
Hello,

I'm also havin this "com_content/helpers/route.php on line 106" problem. I don't understand the whole "http://joomlacode.org/gf/project/joomla ... m_id=12724" code. Could anyone please help me out in this one? I have just a little idea about writting code, so please give me a non-coder solution.
Thanks in advance.


The issue mentioned was fixed last October. The issue you are experiencing, I believe, is a different issue. Can you try creating a menu item that points to an article and see if that fixes the problem?

I believe something has already been filed for this.

Ian


Top
 Profile  
 
PostPosted: Wed Jun 10, 2009 9:38 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Fri Dec 19, 2008 5:50 pm
Posts: 5
Wow!!

Problem solved! I have to have an article published as a menu item (not only created). Thats not what I actually wanted, but it's ok. I hope the Joomla developers try to get rid of this issue in the next version.

Thanks a lot!

Charly


Top
 Profile  
 
PostPosted: Mon Oct 11, 2010 6:37 pm 
Joomla! Fledgling
Joomla! Fledgling

Joined: Sat Dec 06, 2008 2:52 pm
Posts: 3
There is a very easy solution for this problem:

- Edit the file components/com_content/helpers/route.php
- Insert a new line between line 99 and line 100
- In the new line write: $items = null;
- Now on line 107, before the statement foreach($items as $item) write: if ($items!=null)


Top
 Profile  
 
PostPosted: Thu Oct 21, 2010 12:43 pm 
Joomla! Fledgling
Joomla! Fledgling

Joined: Sun Sep 19, 2010 8:41 pm
Posts: 1
thank you, i think i found the final solution to that problem


Top
 Profile  
 
PostPosted: Mon Nov 22, 2010 9:36 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Wed Apr 22, 2009 6:02 am
Posts: 7
works like a dream!

OP


Top
 Profile  
 
PostPosted: Thu Dec 16, 2010 11:57 am 
User avatar
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Aug 01, 2007 12:08 am
Posts: 232
Location: Kent, UK
DannyRitiu wrote:
There is a very easy solution for this problem:

- Edit the file components/com_content/helpers/route.php
- Insert a new line between line 99 and line 100
- In the new line write: $items = null;
- Now on line 107, before the statement foreach($items as $item) write: if ($items!=null)


Great work! Thank you!

_________________
Company site - http://www.stormit.co.uk
Follow me on Twitter - http://twitter.com/stormit


Top
 Profile  
 
PostPosted: Sun Jan 09, 2011 5:10 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Thu Dec 30, 2010 10:34 am
Posts: 18
DannyRitiu wrote:
There is a very easy solution for this problem:

- Edit the file components/com_content/helpers/route.php
- Insert a new line between line 99 and line 100
- In the new line write: $items = null;
- Now on line 107, before the statement foreach($items as $item) write: if ($items!=null)


Done, Thank you :)


Top
 Profile  
 
PostPosted: Thu Mar 03, 2011 4:38 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Sun Feb 22, 2009 5:38 pm
Posts: 25
I am having the same problem and tried the solution but now I am getting this error:

Parse error: syntax error, unexpected T_VARIABLE in /home2/socialsa/public_html/components/com_content/helpers/route.php on line 101


Top
 Profile  
 
PostPosted: Thu Mar 03, 2011 4:54 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Sun Feb 22, 2009 5:38 pm
Posts: 25
Ok... I figured out what the problem was, I had a link to the Home page but unpublished it until I finished my front page article and had a different link set to default. I just did not realize it would cause so many problems.


Top
 Profile  
 
PostPosted: Sat Jul 09, 2011 5:29 am 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Sun Mar 27, 2011 1:31 pm
Posts: 6
DannyRitiu wrote:
There is a very easy solution for this problem:

- Edit the file components/com_content/helpers/route.php
- Insert a new line between line 99 and line 100
- In the new line write: $items = null;
- Now on line 107, before the statement foreach($items as $item) write: if ($items!=null)


Thanks alot this saved my day... :)


Top
 Profile  
 
PostPosted: Fri Jan 20, 2012 10:47 am 
Joomla! Fledgling
Joomla! Fledgling

Joined: Tue Mar 31, 2009 5:21 am
Posts: 1
Location: http://www.linuxtuts.net
I know this is an old thread, but
Quote:
DannyRitiu wrote:
There is a very easy solution for this problem:

- Edit the file components/com_content/helpers/route.php
- Insert a new line between line 99 and line 100
- In the new line write: $items = null;
- Now on line 107, before the statement foreach($items as $item) write: if ($items!=null)


Still works.

Thanks a million,

P.S.Joomla 1.7.3

EDIT: its on line 136 now though.
make it look like this...
Code:
if ($items!=null) foreach ($items as $item)


Peace..............


Top
 Profile  
 
PostPosted: Sat Feb 04, 2012 9:54 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Sat Feb 04, 2012 9:49 pm
Posts: 14
DannyRitiu wrote:
There is a very easy solution for this problem:

- Edit the file components/com_content/helpers/route.php
- Insert a new line between line 99 and line 100
- In the new line write: $items = null;
- Now on line 107, before the statement foreach($items as $item) write: if ($items!=null)


Thank you ! Worked like a charm ! I installed a social plugin (facebook, chrome, tweeter, etc.) for k2 and I had this error. Now everything is OK thanks to you ! :)


Top
 Profile  
 
PostPosted: Sun Feb 26, 2012 2:50 pm 
Joomla! Fledgling
Joomla! Fledgling

Joined: Sun Feb 26, 2012 2:47 pm
Posts: 1
Works just fine for me too! Thanks! ;D


Top
 Profile  
 
PostPosted: Tue Mar 06, 2012 7:45 pm 
Joomla! Fledgling
Joomla! Fledgling

Joined: Tue Mar 06, 2012 7:39 pm
Posts: 1
Hi. This fix worked for me, too. However, now Facebook doesn't show the item title or text when sharing the stories, or the url's, from the site. Could this be a side-effect of the fix, or is something else causing this problem?

(On Edit): When Facebook renders the url, it just shows my site name as the title and site description where text should show. The images are showing, and the FB links created work for me, but others report that the facebook links aren't working.

Please advise & Thanks.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 17 posts ] 



Who is online

Users browsing this forum: No registered users and 11 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group