Re: Allowing rights to their own records only for users and admin.

2011-04-24 Thread Fons Vandamme
You can add a user_id to your post or whatever you want users/admins
to delete. then you can use the afterFind to determine if the user can
or can't do actions on that record.

Hope this helps! should be easy to implement ;)



On 24 apr, 09:28, Pankaj Agrawal  wrote:
> Hi,
>
> I feel this is a must feature and should already be there. But after a
> lot of searching I could only find ways to restrict users to
> particular actions like view, add, delete.
>
> I have Baked CURD pages for all my tables that are associated.
>
> What I want is to be able to allow a particular user to be able to
> list/view/edit/update/delete his own posts/profile etc only.
>
> An Admin to be be able to list/view/edit/update/delete only his own
> users and posts from his own users only.
>
> And a particular admin to be able to do everything.
>
> I am not able to find a way which can let any db query to be
> restricted to certain conditions that specifies the ownership for the
> user. For a direct php query it would be comparatively simple with
> some extra where clause.
>
> I did a lot of searching but I am so far disappointed regarding this
> feature which is probably the core of any site.
>
> Thanks for all your help.
>
> - Pankaj

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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


Re: You favorite IDE/ Dev Setup?

2011-04-03 Thread Fons Vandamme
I recommend 'Coda' to all Mac OS X users out there! Awesome editor and
Coda 2.0 (which is still in development) will make it all even
greater!

All you need is MAMP (Mac Os X, Apache, Mysql, PHP) and you are all
set!

As a browser Firefox 4 with the plugin "Firebug" .

For collaboration I suggest using GIT.

Happy baking!

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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


Re: Email Question

2011-03-29 Thread Fons Vandamme
You can troubleshoot this easily by following these steps:

1. Send e-mail;
2. Verify if e-mail is delivered;
3. Change template for e-mails;
4. Delete cache files (without modifying the dir structure);
5. Send an e-mail (using the new template);
6. Verify if e-mail is delivered and template has changed.

please let me know the outcome so we can look for another solution if
this doesn't fix your issue.

Fons

On 29 mrt, 06:30, "Krissy Masters"  wrote:
> I have not setup any caching specifically for the email process? Does it do
> it without me knowing possibly? Maybe the templates are cached by Cake for x
> amount of time? I cannot see that being forced upon us...
>
> I have not set any cache action or anything I can think of to cache the
> email.
>
> K
>
>
>
>
>
>
>
> -Original Message-
> From: cake-php@googlegroups.com [mailto:cake-php@googlegroups.com] On Behalf
> Of Ryan Schmidt
> Sent: Tuesday, March 29, 2011 1:57 AM
> To: cake-php@googlegroups.com
> Subject: Re: Email Question
>
> On Mar 28, 2011, at 23:23, Krissy Masters wrote:
>
> > Using just the Email Component, no add ons and something weird is going
> on. I get the email but the HTML template wrapping the email does not
> change. What I mean is I send myself an email , make a change to the
> template upload it. Send another email and the template does not chage. I
> have even hardcoded in "WHAT THE HELL" and it shows up maybe 10 emails later
> long after I have deleted WHAT THE HELL. I am timestamping the subject so I
> know at 12:30 this email was sent and add a note in the email message saying
> hardcoded what the hell, or this should be pink , text is blue.what not so I
> can tell whats going on.
>
> > But the changes and the rendering of the correct template are about 10
> emails back.
>
> > Ideas? Yes I wait till the template has uploaded before sending. Sure I
> might miss 1 or 2 but 10 emails not likely.
>
> Is there caching involved? Does CakePHP perhaps cache the template for
> awhile before re-reading it?
>
> --
> Our newest site for the community: CakePHP Video 
> Tutorialshttp://tv.cakephp.org
> Check out the new CakePHP Questions sitehttp://ask.cakephp.organd help
> others with their CakePHP related questions.
>
> To unsubscribe from this group, send email to
> cake-php+unsubscr...@googlegroups.com For more options, visit this group 
> athttp://groups.google.com/group/cake-php

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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


Re: Upload Multiple images in Cakephp

2011-03-29 Thread Fons Vandamme
Dear reader,

I've noticed this post and I have a similar issue concerning the use
of multiple file upload in CakePHP. I'm rather new to CakePHP
development but i'm familiar with programming and the MVC concept.

I'm developing on cakephp 1.3.7 and use MeioUpload as FileUpload
component (url: http://www.meiocodigo.com/projects/meioupload/). At
the moment everything is setup and I have a Album and Photo table in
my database. The models, views & controllers are set for them and i'm
able to upload photo's to an album and to view albums containing
photo's. To display my photo's i'm using a JQuery plugin called
'Galleria'.

All this stuff is implemented, tested and it works! My main issue now
is that uploading an album with for example 70 pictures in it take
time... It would force the admin to upload the 70 pictures manually...

I've tried to implement the Jquery Dynamic Form plugin so I could
dynamically add more FileUpload components to upload page. I've played
with the code for some time and came to the conclusion that this
plugin isn't working. Maybe i'm doing something wrong.

So my question basically: Is there anyone who implemented multiple
file upload in cakePHP  succesfully that can show me the right way to
do it (with MeioUpload or without).

I've searched the web for hours now so i'm pretty much depended on the
outcome of this post now.

greets & thanks in advance!

Fons

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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