SaveAll not saving multiple model data when first oine is blank!

2010-08-05 Thread Affinity
Hi

I am completely confused...

I have several hasMany relationships in a model. I have a page that
allows the user to add multiple rows of data to each of these hasMany
tables. If the first hasMany data is entered, then any subsequent data
is saved using SaveAll too. BUT if the first hasMany data is not
completed and left blank, and only the other ones entered, they are
not entered into the database.

So basically leaving the first hasMany data fileds blank means the
rest wont get added either!

I know my $this->data array has all the data, I have debuged it.

I read that my tables need to be innodb for SaveAll so converted them
but still does not work.

Anyone know why this?

Thanks

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

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: What's best way to create the Admin area?

2009-06-07 Thread Affinity

"I didn't realise you were considering having admin"

Sometimes I wont be but sometimes I will. For example, a customer
profile page allows them to edit everything, but maybe not username
like most other sites/forums people register on. But Admin on the
other hand when editing a customer detail will see the exact same page
as the customer, but have the ability to change username.

So in this case having the same view would be easiest with just a
check to see if the user is admin and if so make the username
editable. So in a situation like this no need to have a separate admin
app or use admin router. I want to avoind having 2 views for this in
case I add some fields one day, then I have to add them twice.

On the other hand admin will also see admin pages, like settings and
things that the customer wont see. So in this case a separate view is
fine.

So its trying to build the best admin area to consider all the above.

I read somewhere else about rendering a view file for this. $this-
>render(’view_file_name’);

Does this mean I can use the admin routing to create the admin area,
then for the views that require the same view file with a few admin
checks I can just call this? That sounds the best. So i can create
admin views for admin views, customer views for customer views and
"joint" views where the code is the same and just render these in the
appropriate customer/admin views. Not so familar with rendering it
(still a cake newbie) but this principle sounds good.
--~--~-~--~~~---~--~~
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: CakePHP or Symfony Which is the Best?

2009-05-08 Thread affinity


I tried to learn Zend, Symfony and Cake and found CakePHp the easiest to pick
up. So I thinkfor newbies its the best. But from what I read if you're an
expert maybe Zend is although probably wont know for a while. 
-- 
View this message in context: 
http://n2.nabble.com/CakePHP-or-Symfony-Which-is-the-Best--tp2845212p2846991.html
Sent from the CakePHP mailing list archive at Nabble.com.


--~--~-~--~~~---~--~~
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: Poll: what do you hate about CakePHP?

2009-05-08 Thread Affinity

Lack of good userguides and tutorials. The ones that exist cover a few
basics but thats about it, I struggle with more advanced stuff.

Lack of a good, proper support forum.

Apart from that Iove it and am persevering as I found it a lot easier
to learn than Zend.
--~--~-~--~~~---~--~~
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: Why is it so hard to find answers on cakephp trouble?

2009-03-27 Thread Affinity

Reply to Ad7six (sorry topic has moved on but wanted to answer)
regarding support forums

"What forums?"

I have also posted on http://www.cakephpforum.net/. I couldnt find any
others apart from this Nabble/Google Group.

"When you say forum what do you mean? Google groups allows users to
pick and choose how they see/recieve info/participate - and it's
primarily a mailing list (with typically awesome search for those oft-
asked questions). "

Well firstly this site Google Groups and Nabble LOOK pretty awful and
dont have much functionality. There's no highlighting of code, text,
quotes, etc. i.e. BB code. Search is really basic. If anyone is
familiar with online forums that use software like phpBB3, vBulletin
etc. then thats what I mean by forum. A proper discussion forum. Using
this group/nabble for community support, development, discussion etc.
is pretty bad. So http://www.cakephpforum.net/ has the right forum
system (invision power board). Forums are low cost (phpbb3 is free)
and easy to setup, so you would have thought CakePHP would have a
proper one rather than direct people to Google Groups. But as stated I
posted on http://www.cakephpforum.net/.

So I think a proper "official" forum system should be introduced to
improve the support experience, or more people move to 
http://www.cakephpforum.net/
to make it worthwhile. I couldnt find any other ones. Although we dont
want loads!
--~--~-~--~~~---~--~~
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: Why is it so hard to find answers on cakephp trouble?

2009-03-26 Thread Affinity

I find support not great... I have asked a few questions on various
forums and got no reply to any, so I have had to struggle through on
my own. Its not a great way to get people into it. Although I started
trying to learn Zend and did find CakePHP documentation/examples
better.

I'm also surprised Google groups is the primary forum... the google
forum is rubbish compared to leading forum systems these days so I
have no idea why we're all on here!
--~--~-~--~~~---~--~~
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: What do you develop in (ide, text editor, etc.)?

2009-03-01 Thread Affinity

Tried using Netbeans et al but not got into it big time yet, so still
use Notepadd++ which is an excellent text editor.
--~--~-~--~~~---~--~~
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: Cannot get aros_acos to populate, so cannot access anything

2009-02-16 Thread Affinity

Just to update this post... I just could not get the ACL to work even
following all tutorials, I think they must miss a few things somewhere
that newbies will overlook.

So I found Authake which seems to work great 
http://conseil-recherche-innovation.net/authake.
Tried a couple of others but this seems to be the best so far.
--~--~-~--~~~---~--~~
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: how to set css for internet explorer

2009-02-16 Thread Affinity

Oh, and then dont forget to get Mulitple IEs, an excellent tool to
install many versions of IE on your windows http://tredosoft.com/Multiple_IE.
This is another thing many designers forget... to check the design on
all the IE's as it may be different in each one. If you design in
Firefox it may be OK in IE7, but from IE7 to IE6 you may see big
changes. I dont bother checking in IE5 or less.
--~--~-~--~~~---~--~~
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: how to set css for internet explorer

2009-02-16 Thread Affinity

I agree with conditional CSS. I started using is a few years ago and
have found nothing that is better.

Add in your main CSS first that covers everything, and the CSS works
for say Firefox. Then add in a IE6 and IE7 CSS that only includes the
changes you need to the main CSS (i.e. no need to have a full CSS for
each browser).

This is the code:-







then you have 3 stylesheets:-
stylesheet.css
stylesheet_ie6.css
stylesheet_ie7.css

Also, due to IE8 now rendering different to IE7 (sigh) which is
different to IE6 (sigh), instead of creating a IE8 stylesheet you can
add the following code at the top of all your wbesites (so still more
work :( ) to tell IE8 to render like IE7. This is quicker than making
your website work for IE8 if it already works for IE7.



Also, in the conditional statements you can add IE6 specific files,
for example, I also put a javascript file in the conditional statement
for IE6 that I only need for IE6 (to make PNG files work for IE6).
--~--~-~--~~~---~--~~
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: Cannot get aros_acos to populate, so cannot access anything

2009-02-02 Thread Affinity

I have discovered (with difficulty) the initDb and buildAcl functions
are called by going to them in the URLs, which is not documented in
any tutorials:

http://localhost/yourproject/users/initDB
http://localhost/yourproject/users/buildAcl

I get an error when running initDB but at least the permissions now
work

--~--~-~--~~~---~--~~
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: Cannot get aros_acos to populate, so cannot access anything

2009-02-02 Thread Affinity

Oh I just realised the above code where it says $aroAlias, $acoAlias I
assume you should replace it with the right arcoAlias and $acoAlias I
think?? Anyway, still doesnt work if I enter:-

cake acl grant Administrators Users all
cake acl grant 1 Users all

still get same error whatever I try, and the following exists in the
initDB in users_controller.php

function initDB()
{
$group =& $this->User->Group;

$group->id = 1;
$this->Acl->allow($group, 'controllers');

$group->id = 2;
$this->Acl->deny($group, 'controllers');
$this->Acl->allow($group, 'controllers/Posts');
$this->Acl->allow($group, 'controllers/Widgets');

$group->id = 3;
$this->Acl->deny($group, 'controllers');
$this->Acl->allow($group, 'controllers/Posts/add');
$this->Acl->allow($group, 'controllers/Posts/edit');
$this->Acl->allow($group, 'controllers/Widgets/add');
$this->Acl->allow($group, 'controllers/Widgets/edit');
}


--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Cannot get aros_acos to populate, so cannot access anything

2009-02-01 Thread Affinity

Hi
Am new to Cake so am following some tutorials. I have been following
this tutorial which is more or less same as others I have seen:
http://mark-story.com/posts/view/auth-and-acl-an-end-to-end-tutorial-pt-1

But the aros_acos table is not being populated at all. So when my
Admin user logs in I cant access pages I should be able to access like
Users and Groups.

I wonder if it is to do with he following which I cannot get to work:-

To allow ARO’s access to ACO’s from the shell interface use
cake acl grant $aroAlias $acoAlias
[I actually added all on the end else it wont work, and I get an error
Warning: DbAcl::allow() - Invalid node]

to allow with the AclComponent do the following:
$this->Acl->allow($aroAlias, $acoAlias);
[i dont know where this goes?]

Any help appreciated, thanks.

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Mail Component Not Working

2008-02-24 Thread Affinity Skateboards

I am trying to use the mail component on my contact page (
http://www.theskateparkdirectory.com/contact/ ) and I get the
following message:

Missing Component File

You are seeing this error because the component file can't be found or
doesn't exist.

Notice: If you want to customize this error message, create app/views/
errors/missing_component_file.thtml.

Fatal: Create the class below in file : app/controllers/components/
email.php



My contact_controller looks like this:



Am I doing something wrong? I thought that Email was a built in
component of cakephp. Any help would be most appreciated.


--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Email Component not working..

2008-02-24 Thread Affinity Skateboards

I am trying to use the email component on my contact page, but when
trying to add the component in my controller I get:


Missing Component File

You are seeing this error because the component file can't be found or
doesn't exist.

Notice: If you want to customize this error message, create app/views/
errors/missing_component_file.thtml.

Fatal: Create the class below in file : app/controllers/components/
email.php



this is what my contact_controller looks like:



Is there something I am missing? I thought that the email component
was a "built-in" component of cakePHP. Thanks for the help.

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---