CakePHP site is down

2013-01-11 Thread sdc53
Just thought I'd let someone know, in case you didn't already.

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en.




Re: ACL from View

2009-04-30 Thread sdc53

Faza, appreciate the help. The problem I see with your approach occurs
in your earlier example here:
in view i put this: (yes, I will make a helper to do it one day)
if (in_array($session-read('Auth.User.group'), array(Administrator,
Designer))
{
...

}

This assumes (hard-coded in the view) that group Designer will
always have access to this particular view item. If you remove the
right from the designer group, but the logged in user is still a
member of group Designer then the condition will still pass. It's
only checking group membership, not the rights of that group (really,
the effective rights of the user is what should be checked) to that
particular action in the view.

What I want is a way, from the view, is to check if the logged-in user
has access to a particular controller/action pair, so that I can show
or hide links to any clickable link.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



ACL from View

2009-04-29 Thread sdc53

I was wondering if anyone has any ideas regarding determining based on
ACL whether or not a particular user has access to a specific
controller/action pair from the view.
Currently, we use the html helper to generate links to edit actions,
etc something like the following:

?php echo $html-link('Edit', array('action'='edit', $model['Model']
['id'])); ?

Ideally, it would be in the form of a special helper (which I know has
no access to the database) that checks to see if the logged-in user
has access to that method and just does not generate the link if there
is no access.

We have a variety of user types and groups, with varying levels of
access in our application using the same views.

Based on the quantity of links and variability of some of the views we
generate, I'd like to stay away from generating special variables for
this purpose in the controller before the view is rendered, or
creating special views that are basically identical for the different
types of users in the system to hide these links.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: ACL from View

2009-04-29 Thread sdc53

Thanks Faza - but that doesn't work because that makes the assumption
in the view that the group would always have access to that item.
Let's say then with ACL you remove that right... all the views where
you have that hard-coded logic would then need to be updated, which is
the problem I am trying to avoid.

Ideally, ACL would be the one place to go where that is controlled.

We currently have an application that is in flux - meaning that there
will be different types of free, discounted, and full memberships,
along with different levels of administrators. What these users and
groups are allowed to do will change over time. I want to minimize the
hard-coded stuff, and just ask ACL, can this user do
whateverController/whateverMethod, from the view.

Sure, if the link is present, and the user clicks on it, I can deny
access in the controller (which I do) but that becomes annoying to the
end users. If they don't have rights to do a particular action, the
link shouldn't be present in the view.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
CakePHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: problem with 1.2 __() function

2007-11-08 Thread sdc53

thanks Sliv.
 Scott


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



problem with 1.2 __() function

2007-11-07 Thread sdc53

In my baked view/edit/index screens, the __() internationalization
function is used with values coming from the DB inside $html-link.
For example:
echo $html-link(__($placement['Status']['status'], true),
array('controller'= 'statuses', 'action'='view', $placement['Status']
['id']));

when the values are NULL (which is allowed in some cases), it spits
out this in my view, for each null field:

Project-Id-Version: CakePHP 1.2.x.x POT-Creation-Date: PO-Revision-
Date: 2006-12-23 03:28-0600 Last-Translator: Larry E. Masters Language-
Team: CakePHP I18N  I10N Team MIME-Version: 1.0 Content-Type: text/
plain; charset=utf-8 Content-Transfer-Encoding: 8bit Plural-Forms:
nplurals=2; plural=(n != 1); X-Poedit-Language: English X-Poedit-
Country: UNITED STATES X-Poedit-SourceCharset: utf-8

I found this in the core.po file:
msgid 
msgstr 
Project-Id-Version: CakePHP 1.2.x.x\n
POT-Creation-Date: \n
PO-Revision-Date: 2006-12-23 03:28-0600\n
Last-Translator: Larry E. Masters phpnut (at) gmail (dot) com\n
Language-Team: CakePHP I18N  I10N Team [EMAIL PROTECTED]\n
MIME-Version: 1.0\n
Content-Type: text/plain; charset=utf-8\n
Content-Transfer-Encoding: 8bit\n
Plural-Forms: nplurals=2; plural=(n != 1);\n
X-Poedit-Language: English\n
X-Poedit-Country: UNITED STATES\n
X-Poedit-SourceCharset: utf-8\n

So I figured, the null is matching on msgid , and spitting that
stuff out.
I don't know anything about gettext, but I removed the above and
rebuilt the core.mo file in an attempt to get rid of this. No luck.

Works fine if I remove the __() stuff, but heck.. I'm going to have
around 130 affected files * however many fields to seek and destroy.
I'd rather fix the problem with the internationalization gunk.

Anyone seen this? I'm running the latest 1.2.
Thanks
Scott


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



removing certain columns from automatic joins

2007-08-07 Thread sdc53

I've seen unbindModel, but that removes the reference to the entire
table. I need to not automatically retrieve certain columns from
related tables, in this case a table that contains blobs and
filenames.
for example:
parent
 id
 name
 company
 etc..
child blobs
 id
 parent_id
 filename
 filetype
 data

when I do a $row=$this-Parent-read(null, $id);
obviously I get everything. I haven't seen any examples of what the
first argument would do, but I think it would be a one-dimensional
array of fieldnames to include. does it allow you to specify something
like child.id?
If so, I'd prefer not to go that route as there are many tables I'm
retrieving data from and the schema is still changing. What I'd like
to do is simply specify specific columns to exclude. Is there an
elegant way to do this?


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: removing certain columns from automatic joins

2007-08-07 Thread sdc53

thanks, that looks like that would work, then later on when I want
that data I could just retrieve it directly based on id from the child
table, which is probably what I would end up doing anyways. I had seen
that in the docs in the past but didn't realize that is what it was
for. thanks!



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---