Joomla! Discussion Forums



It is currently Wed Nov 25, 2009 9:34 am (All times are UTC )

 




Post new topic Reply to topic  [ 15 posts ] 
Author Message
Posted: Mon Feb 27, 2006 8:47 pm 
User avatar
Joomla! Apprentice
Joomla! Apprentice
Offline

Joined: Fri Dec 30, 2005 1:52 am
Posts: 37
Location: Florida
When viewing an page of archives, if you click on a link to the second or more pages, I get an:

You are not authorized to view this resource.
You need to login.

The numbered pages (and Next, Previous, End) all go to other pages on my site.

URL: http://www.archaicbinary.net/content/ar ... egory/1/2/

This is a fresh install of Joomla! 1.0.8

UPDATE: This only occures with SEF enabled.

_________________
~ Archaic Binary ~


Last edited by stingrey on Wed Mar 08, 2006 8:36 pm, edited 1 time in total.

Top
   
 
Posted: Wed Mar 01, 2006 10:20 am 
User avatar
Joomla! Master
Joomla! Master
Offline

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 11684
Location: **Translation Matters**
I can't even get to the Blog-category listing, whether SEO is on or not...
Same error.

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr · GMT +1
Qui vult dare parva non debet magna rogare.
---------------------------------
Joomla! Translation Coordination Team


Top
  E-mail  
 
Posted: Sat Mar 04, 2006 9:42 pm 
Joomla! Apprentice
Joomla! Apprentice
Offline

Joined: Wed Jan 04, 2006 10:27 pm
Posts: 9
I upgraded from 1.0.7 and get the message "You are not authorized to view this resource.
You need to login."  When trying to view the archives.

Ray


Top
  E-mail  
 
Posted: Wed Mar 08, 2006 8:34 pm 
User avatar
Joomla! Hero
Joomla! Hero
Offline

Joined: Mon Aug 15, 2005 4:36 pm
Posts: 2399
Location: Marikina, Metro Manila, Philippines
Fixed in SVN

_________________
God grant me the Serenity to Accept the things I cannot change, the Courage to change the things I can and the Wisdom to know the Difference.


Top
  E-mail  
 
Posted: Wed Mar 08, 2006 8:37 pm 
Joomla! Apprentice
Joomla! Apprentice
Offline

Joined: Wed Jan 04, 2006 10:27 pm
Posts: 9
What's SVN?

Ray


Top
  E-mail  
 
Posted: Wed Mar 08, 2006 9:03 pm 
User avatar
Joomla! Hero
Joomla! Hero
Offline

Joined: Mon Aug 15, 2005 4:36 pm
Posts: 2399
Location: Marikina, Metro Manila, Philippines
rbjb wrote:
What's SVN?

http://dev.joomla.org/content/view/17/60/#subversion

_________________
God grant me the Serenity to Accept the things I cannot change, the Courage to change the things I can and the Wisdom to know the Difference.


Top
  E-mail  
 
Posted: Wed May 03, 2006 12:44 am 
Joomla! Fledgling
Joomla! Fledgling
Offline

Joined: Wed Mar 29, 2006 5:49 am
Posts: 4
stingrey wrote:
Fixed in SVN

Which particular files were changed in SVN to fix this bug?


Top
  E-mail  
 
Posted: Fri May 05, 2006 10:48 am 
User avatar
Joomla! Enthusiast
Joomla! Enthusiast
Offline

Joined: Fri Aug 19, 2005 11:20 pm
Posts: 114
Location: Ireland
Anyone ever figure out which files actually resolved this issue?


Top
  E-mail  
 
Posted: Sat May 06, 2006 12:54 am 
Joomla! Fledgling
Joomla! Fledgling
Offline

Joined: Wed Mar 29, 2006 5:49 am
Posts: 4
It was content.php in the com_content component.

I found it on another thread.  In most of the functions, like showArchiveCategory, there will be a query and an if statement to check "if (!count(rows))".  You need to also include "&& $check != 0" in that if statement, otherwise it will attempt to load a category that doesn't exist and then the published check will fail, and thus the no permissions error.  If you've actually got content in your Archives, you probably wont see this error.

The latest version in SVN (or at least the versions I've seen) have had $check renamed to something else, like $secId.  There were so many other changes in the latest version, particularly in the queries, I just updated my installation manually for the $check bit.

Do a sanity check on all the show* functions in content.php to make sure they're doing that check, just to be sure.

Reuben


Top
  E-mail  
 
Posted: Sat May 06, 2006 10:25 am 
User avatar
Joomla! Enthusiast
Joomla! Enthusiast
Offline

Joined: Fri Aug 19, 2005 11:20 pm
Posts: 114
Location: Ireland
Many thanks for the reply Reuben. Any chance you could post your amended file to test?


Top
  E-mail  
 
Posted: Sat May 06, 2006 4:17 pm 
Joomla! Fledgling
Joomla! Fledgling
Offline

Joined: Wed Mar 29, 2006 5:49 am
Posts: 4
Sure.  Attached in content.zip is my version of content.php.

The only change from 1.0.8 is the checks on $check to make sure its not zero for the various if statements that also check the row count.

Regards
Reuben Helms


You do not have the required permissions to view the files attached to this post.


Top
  E-mail  
 
Posted: Sun May 07, 2006 7:49 pm 
User avatar
Joomla! Enthusiast
Joomla! Enthusiast
Offline

Joined: Fri Aug 19, 2005 11:20 pm
Posts: 114
Location: Ireland
Thanks Reuben. I'll try that.


Top
  E-mail  
 
 Post subject: Same issue version 1.10
Posted: Mon Jul 03, 2006 9:05 pm 
Joomla! Apprentice
Joomla! Apprentice
Offline

Joined: Tue Apr 18, 2006 3:42 pm
Posts: 5
Hello I am having this same issue in the latest version.  I am new to Joomla and don't understand the prior posts about what to fix to get this to work.  I can see the story titles, but when click says you are not aurhorized to view this resource.  Any detailed help would be appreciated.  Thank you!


Top
  E-mail  
 
Posted: Tue Jul 04, 2006 1:37 am 
Joomla! Fledgling
Joomla! Fledgling
Offline

Joined: Wed Mar 29, 2006 5:49 am
Posts: 4
This "should" actually be fixed with 1.0.10.

Here's what you'll need to check.

First, take a note of what kind of section you're trying to view (is it a Blog or an Archive, is it a Section or a Category, etc).
Second, lets look at the source code. Have a look at components/com_content/content.php.

There are 4 functions you need to look at : showBlogSection(), showBlogCategory(), showArchiveSection() and showArchiveCategory().

They all have a very similar structure.

Lets look at showArchiveCategory().

Somewhere near the top is "$catID = ($id ? $id : 0 );".

Further down, after the SQL code is "if (!count($rows) && $catID != 0) {"

That is the fixed code. The previous code didnt check the value of $catID, so if it was zero, and attempted to do the load, you would get the unauthorized message.

showBlogCategory() does something similar, but different.  Its if statement says "if (!count($rows) && $check) {", which works out to be the same as the other method.  I wish they were all consistent, but thats beside the point.

Anyway, if you track the source through and try to load content with a zero value identifier, you'll get that error.

Hopefully, the problem you are having is located elsewhere, or there'll be a bit of head scratching going on. I just upgraded to 1.0.10, and was able to remove a few customisations / bugfixs I had made in my own distribution. So far, this error has not occured.

Regards
Reuben Helms


Top
  E-mail  
 
Posted: Tue Jul 04, 2006 1:44 am 
Joomla! Apprentice
Joomla! Apprentice
Offline

Joined: Tue Apr 18, 2006 3:42 pm
Posts: 5
these are archived news - latest news items.....I currently have it unpublished because I don't want users to think they have to log in to view archives.  If I do a search from the search menu, the items come up and are viewable archived.  Any ideas for this?  Thanks very much for your help.


Top
  E-mail  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 15 posts ] 

Quick reply

 



Who is online

Users browsing this forum: No registered users and 0 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 © 2000, 2002, 2005, 2007 phpBB Group