Forums | Mahara Community

Support /
Despite config, public views request auth


anonymous profile picture
Account deleted
Posts: 10

04 September 2009, 14:17

I'm hoping this one's been answered already but I didn't find an answer in the forums: Public views an profiles don't appear to work in my installation.  Both prompt for authentication despite the configuration being correct as far as I can tell.  (I've set the appropriaet allow-public options in the Site Config.)  Stranger still?  The Secret URL stuff for Views DOES work. 

Any ideas on what I could look into?  

anonymous profile picture
Account deleted
Posts: 808

06 September 2009, 17:45

Hi John,

I'm afraid I haven't come across this problem before, and I've just confirmed that it's all working as expected for me on my local 1.1 and master installs. I presume the views in question have public access set on them?  You could check the database to make sure there's a record in the view_access table with the appropriate viewid and the string 'public' in the 'accesstype' column.

If that's all good, then I think it's going to be very hard for us to reproduce this problem -- it seems specific to your installation.  All I can suggest is to edit the code and put some logging into view/view.php, and maybe also into the can_view_view() function in lib/mahara.php and see where it's going wrong.

Let me know if you want to do this -- it's basically a matter of adding a few calls to log_debug() in the code, hitting the page and then looking in the apache error log.

R.

anonymous profile picture
Account deleted
Posts: 14

18 November 2009, 7:55

Mahara 1.2.0, Windows Xp, XAMPP, MySQL 5.0.67

I experience the same problem with the "Secret URL" function - the system prompts the user to log in in order to see the view.

When "Secret URL" is created, there is no record for it in the view_access table.

How to setup the debug?

anonymous profile picture
Account deleted
Posts: 1643

18 November 2009, 16:44

I just tried on Mahara 1.2, Linux, Postgres 8.1 and it seems to work ok. I could access a secret view while logged out. I wonder if it's related to MySQL or Windows in some way...

RichardM: do you remember what steps you were going to suggest to debug this? 

anonymous profile picture
Account deleted
Posts: 808

18 November 2009, 17:53

The secret urls sit in the view_access_token table (not view_access).  Do records get created there?
anonymous profile picture
Account deleted
Posts: 14

19 November 2009, 5:21

Yes, the record for the view is there. After I have been prompted to log I can see the view with the secret URL.

Something odd - I created another view with a secret URL from the same user and it works OK.

anonymous profile picture
Account deleted
Posts: 2

29 December 2009, 2:22

Hello: I am having (maybe) a related problem. When I create a secret URL (Mahara v 1.2.2, ; Apache Unix 2.2; MySQL 5.1.41; OS Linux, PostGreSQL) any files that are included in the portfolio view (e.g. inserted images) are not visible and show up as broken links. If an attempt is made to download a file (like in "Files to Download"), Mahara asks for a login. Unless I'm doing something wrong (may well be) it seems like artefacts in the Secret URL view would be, in effect, public. When a view is shared with a friend, everything seems fine.

Any ideas?

And developers, thanks for your hard work. This looks great.

7 results