Twitter Feed

Xataface Maillist

Sign up to receive the Xataface news letter with weekly updates and development tips.

 

Secure Display

Posted by noreply@blogger.com (Fong Chun Chan) on Nov 6, 2008
See Original Post
If you are using Xataface as your backend management, and also as a front end (through the use of actions and templates) this can save you lots of time. However, sometimes you set permissions on records that you don't want users seeing if they are in the backend. For example, the application could prevent any users not logged in from seeing the backend by returning:br /br /blockquotereturn Dataface_PermissionsTool::NO_ACCESS();/blockquotebr /br /However this could have adverse effects as in the front end some records are no longer viewable because of this. One way to solve this is to set in each of your smarty templates this small block of code which basically causes all records to ignore all permissions:br /br /blockquotebr /{php}br /$pt = Dataface_PermissionsTool::getInstance();br /$pt-gt;setContext($pt-PUBLIC_CONTEXT());br /{/php}br //blockquote
Read more...
Powered by Xataface
(c) 2005-2010 All rights reserved