Re: Sharing data/values across different controllers

2011-01-17 Thread LunarDraco
Sharing data between controllers is generally not a good practice and
is a good indicator of heading down the wrong path.

Data should all be manipulated at the model level.
Explain a little more about the data your sharing between the two
controllers and why the data is coming from a controller instead of
the model.

On Jan 17, 9:27 pm, zer0_gravity  wrote:
> it worked thanks i realised i did not setup the session component
> variable
>
> thanks alot
>
> On Jan 17, 11:11 pm, zer0_gravity  wrote:
>
>
>
>
>
>
>
> > Could briefly explain the other ways because it is not working for me.
>
> > On Jan 17, 10:49 pm, tnbrooks  wrote:
>
> > > You could write them into session using something like:
> > > $this->Session->write('the_value', $value);
> > > then to access it in your other controller you just use:
> > > $this->Session->read('the_value');
>
> > > This is just one way..there are many others
>
> > > On Jan 18, 2:27 pm, zer0_gravity  wrote:
>
> > > > How Do I share a variable or data that exist in a particular
> > > > controller but do not exist in other controller(s)?
>
> > > > 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


deployment, git hooks, migrations ... updating your app with command line

2011-01-17 Thread huoxito
I'd like to share some thoughts on how I'm updating a cakephp app I've been 
working on and I'd apprecciate to hear how you do it for your apps ...

I'm about to make some important changes on this website that is already in 
production mode and I wonder if there is any way to do it using only git 
hooks and the cake console.

In a couple of days I'll need to create a new table on the production 
database and change / add some fields in existing tables. So far to update 
this app I used only a pretty small script on a git post-receive hook of the 
bare repository on my server, like this ( it runs every time I use a  'git 
push origin master' from my local machine ):

cd ~/myapp/public_html/
env -i git reset --hard
env -i pull origin master

which already saved me from having to use any ftp client. But now with this 
lots of changes I have to do in my production database I'm not sure if cake 
console migrattions can do that automatically. Does schema update really 
only alter tables? I mean what do you do to update a database without having 
to create tables by hand? 

Besides creating and modifying tables with migrattions I guess I also have 
to write some kind of shell script to clear all cache on my application so 
that models are refreshed. Otherwise it won't recognize the recently added 
table fields, Am I right about that? Or there is any other way for models to 
be refreshed on production mode?

If I could add only two more lines to the git hook script mentioned above, 
one for updating the database, including creating new tables if necessary, 
something like "cake schema update" to run the last schema created. And 
other line to execute a shell script to clear all cache ...  Updating this 
app and others by this example would be so much faster and secure ...


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: Sharing data/values across different controllers

2011-01-17 Thread zer0_gravity
it worked thanks i realised i did not setup the session component
variable

thanks alot

On Jan 17, 11:11 pm, zer0_gravity  wrote:
> Could briefly explain the other ways because it is not working for me.
>
> On Jan 17, 10:49 pm, tnbrooks  wrote:
>
>
>
> > You could write them into session using something like:
> > $this->Session->write('the_value', $value);
> > then to access it in your other controller you just use:
> > $this->Session->read('the_value');
>
> > This is just one way..there are many others
>
> > On Jan 18, 2:27 pm, zer0_gravity  wrote:
>
> > > How Do I share a variable or data that exist in a particular
> > > controller but do not exist in other controller(s)?
>
> > > 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: Sharing data/values across different controllers

2011-01-17 Thread zer0_gravity
Could briefly explain the other ways because it is not working for me.

On Jan 17, 10:49 pm, tnbrooks  wrote:
> You could write them into session using something like:
> $this->Session->write('the_value', $value);
> then to access it in your other controller you just use:
> $this->Session->read('the_value');
>
> This is just one way..there are many others
>
> On Jan 18, 2:27 pm, zer0_gravity  wrote:
>
>
>
> > How Do I share a variable or data that exist in a particular
> > controller but do not exist in other controller(s)?
>
> > 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: Sharing data/values across different controllers

2011-01-17 Thread CrotchFrog
Have you considered writing your data to the session or passing it
through a redirect()?

$this->redirect(array('controller' => 'someController', 'action' =>
'edit', $data));
or
$this->Session->write('Some.data', $data);

On Jan 17, 10:27 pm, zer0_gravity  wrote:
> How Do I share a variable or data that exist in a particular
> controller but do not exist in other controller(s)?
>
> 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: Sharing data/values across different controllers

2011-01-17 Thread tnbrooks
You could write them into session using something like:
$this->Session->write('the_value', $value);
then to access it in your other controller you just use:
$this->Session->read('the_value');

This is just one way..there are many others


On Jan 18, 2:27 pm, zer0_gravity  wrote:
> How Do I share a variable or data that exist in a particular
> controller but do not exist in other controller(s)?
>
> 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


Yammer with OAuth Component

2011-01-17 Thread tnbrooks
Hi all,
Just wondering if anyone has been able to access the Yammer API using
the OAuth Consumer class created by CakeBaker http://code.42dh.com/oauth/

I keep getting a null value when trying to get the request token, just
wondering if anyone has come across this issue and worked out what was
going on?

Thanks
Trav

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


Sharing data/values across different controllers

2011-01-17 Thread zer0_gravity
How Do I share a variable or data that exist in a particular
controller but do not exist in other controller(s)?

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: Changing /webroot and /views directories

2011-01-17 Thread Dr. Loboto
http://book.cakephp.org/view/1568/Configuration-and-application-bootstrapping

On 17 янв, 23:17, DragonFlyEye  wrote:
> Because I am setting up a core web engine that will drive a number of
> different sites for my company, it makes sense to me to change the location
> of the /webroot and /views directories. That way I can keep those under
> separate version control and develop the front-end distinctly from the
> back-end. I see that these paths are defined by constants. Is there a
> vehicle for setting our own custom definitions for these constants, or no?
>
> I realize that I could probably just use a soft link to each directory
> wherever I want them to be, but my concern there is just that I'll have to
> redefine these links with every new project.

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: writing to SessionHelp inside the view

2011-01-17 Thread zer0_gravity
You are right I just realised what I needed to do...Thanks

On Jan 17, 7:51 pm, euromark  wrote:
> you got your logic all wrong then!
> all modifications to the session must (or "should" anyway) happen in
> the controller
>
> so, no. there is no reason to allow that.
>
> On 18 Jan., 00:44, zer0_gravity  wrote:
>
>
>
> > Can you write/store a value in the session helper inside the view? so
> > that this value can be accessed by any controller beside using a form
> > get/post method to do this.
>
> > Thank you

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: writing to SessionHelp inside the view

2011-01-17 Thread euromark
you got your logic all wrong then!
all modifications to the session must (or "should" anyway) happen in
the controller

so, no. there is no reason to allow that.


On 18 Jan., 00:44, zer0_gravity  wrote:
> Can you write/store a value in the session helper inside the view? so
> that this value can be accessed by any controller beside using a form
> get/post method to do this.
>
> Thank you

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


writing to SessionHelp inside the view

2011-01-17 Thread zer0_gravity
Can you write/store a value in the session helper inside the view? so
that this value can be accessed by any controller beside using a form
get/post method to do this.

Thank you

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: Setting up initialization values to components, AuthComponent

2011-01-17 Thread Santiago Basulto
Ok, i've found how to initialize parameters for the controller. It was
not difficult, actually, it's in the book. I paste my code here:

lass AppController extends Controller {

var $components = array(
'Auth' => array(
'authorize' => 'controller'
)
);

function beforeFilter(){
$this->Auth->allow('*');
}

function isAuthorized(){
return false;
}

}

The problem now is that i have to create a beforeFilter method in any
controller, even it's blank. I mean, if there's no beforeFilter in my
controller, Auth does not call to isAuthorized.

So, my custom controllers should all implement beforeFilter. It's a
litte frustrating. With this code, Auth doesn't check isAuthorized:

class CarsController extends AppController {
var $name = 'Cars';

function isAuthorized(){
debug(' Nobody will call me');
return false;
}
}


Do you know why is it?

On Jan 17, 6:39 pm, Santiago Basulto 
wrote:
> Hello people!
>
> I'm facing a problem with Auth component. I've a minor level of
> security in my site, that is checked in the isAuthorized() method of
> my AppController. I've there a simple switch that checks some options.
>
> The thing is that i need to declare a beforeFilter() in every
> controller and set inside that method the following statement
> "$this->Auth->authorize = 'controller'" to get Auth to call
> isAuthorized.
>
> I was wondering if there's some way of made that call "application
> wide". I mean, anyway to initialize the Auth component, where to do
> it, to make that (authorize = controller) the default. I tryied to do
> that in the method beforeFilter() of my AppController class, but it's
> not working.
>
> Altought i've found a way, that is to make this call on AppController
> beforeFilter() method:
> $this->Auth->isAuthorized('controller',$this);
>
> It works, but don't think it's a good way to do this. I've seen in the
> AuthComponent that there are some interesting methods that should be
> useful: initialize() and startup()
>
> Does anyone where to call them?
>
> Thanks everybody!
>
> --
> Santiago Basulto.-

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: How would you solve this problem?

2011-01-17 Thread Santiago Basulto
Should be very easy with Java and some office libs.

Write me, i can help: santiago.basu...@gmail.com

On Jan 15, 2:23 am, Adam  wrote:
> Disclaimer: I can't program.
>
> Every morning I gather the same information off the internet for my job. My
> organization insists on having this information in a powerpoint presentation
> form, but the hour a day spent compiling it is really killing me. I might as
> well be typing it out and sending everyone a telegraph for how backwards
> this process is.
>
> An example:
> San Diego International Airport METAR/TAFs must be gathered from
> aviationweather.gov
> It looks like this:
> KSAN 150351Z 18004KT 9SM SCT200 17/11 A3012 RMK AO2 SLP200 T01670111
>
> KSAN 150307Z 1503/1606 VRB03KT P6SM SCT200
> FM152000 29010KT P6SM SCT250
> FM160200 VRB03KT P6SM FEW200
>
> I have to copy and paste it into a powerpoint to make it look like this:
>
> KSAN
> 1951 Observation: 18004KT 9SM SCT200 Temp 17/ Dew point 11
>
> Prevailing Forecast 1900: VRB03KT P6SM SCT200
> FM 1200 Local 29010KT P6SM SCT250
> FM 1800 Local VRB03KT P6SM FEW200
>
> If you are familiar with METARS/TAFS, I basically have to copy and paste
> them into powerpoint, decode them, and change the times from zulu to local.
> Not a big job, I just hate doing it for 10 airports every morning, it's a
> total waste of time.  This information is in some sort of CGI accessed
> database on aviationweather.gov. There are iPhone aps and web plugins that
> access this data.
> My ideal solution:
> I write some code or have someone help me write the code that gets the info,
> converts it to local time, and displays it on a webpage with dynamic
> content. What programing language do I need to learn? I also need to be able
> to display radar images from that website, notams and TFRs from the FAA,
> bouy temp from NOAA, and a few other things. I'm not looking for help
> programing it yet, just some pointers to getting started. Even better would
> be putting it into google docs presentation automatically! Thanks for your
> help!

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


Setting up initialization values to components, AuthComponent

2011-01-17 Thread Santiago Basulto
Hello people!

I'm facing a problem with Auth component. I've a minor level of
security in my site, that is checked in the isAuthorized() method of
my AppController. I've there a simple switch that checks some options.

The thing is that i need to declare a beforeFilter() in every
controller and set inside that method the following statement
"$this->Auth->authorize = 'controller'" to get Auth to call
isAuthorized.

I was wondering if there's some way of made that call "application
wide". I mean, anyway to initialize the Auth component, where to do
it, to make that (authorize = controller) the default. I tryied to do
that in the method beforeFilter() of my AppController class, but it's
not working.

Altought i've found a way, that is to make this call on AppController
beforeFilter() method:
$this->Auth->isAuthorized('controller',$this);

It works, but don't think it's a good way to do this. I've seen in the
AuthComponent that there are some interesting methods that should be
useful: initialize() and startup()

Does anyone where to call them?

Thanks everybody!

-- 
Santiago Basulto.-

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


Check Box IDs not unique

2011-01-17 Thread Jeebs24
Hi,

The snippet of code below is taken from The Cookbook.

http://book.cakephp.org/view/1395/options-multiple

echo $this->Form->input('Model.field', array(
'type' => 'select',
'multiple' => 'checkbox',
'options' => array(
'Value 1' => 'Label 1',
'Value 2' => 'Label 2'
)
));

The problem is the output is not what is expected.  Rather then
getting:


   Field
   
   
  
  Label 1
   
   
  
  Label 2
   


I instead get:


  Field
  
  

Label 1
  
  

Label 2
  


The IDs for each Input are not unique.   Is this a bug or am I doing
something wrong?


Cheers.

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


Book?

2011-01-17 Thread estherM
I've only just started looking into working with CakePHP. I've gone
through the tutorials on the book.cakephp.org site, but they're
extremely basic. I've read about the existing books on this thread
(http://groups.google.com/group/cake-php/browse_thread/thread/
b33b85c9792a9d12#) but given that it's more than 2 years old, I'm
wondering how much has changed in Cake since the book was published.
Is the book still worth buying, or is the current version of Cake
(1.3) too different from what was used in the book?

Are there any more recent books, or online tutorials geared to
beginners (with Cake, not programming in general)? I was hoping to
find something like the Head-First books, which start creating an
application in the very early chapters and then build on them, getting
progressively more advanced with each chapter.

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


Problem with saveAll() not saving related model

2011-01-17 Thread kdubya
I realize I'm not the first person to have a problem with saveAll(). I
have searched this group for a solution to my problem, which is - I
can't get saveAll() to save related model data. I must be doing
something wrong but I cannot spot it.

My app is a sales/inventory system. Here are the pertinent relations:

Vendor hasMany Item
Item hasMany SalesTransaction

I am trying to, in one call to saveAll(), save both an updated
Item.quantity and insert a new SalesTransaction record

My Item model code for the relations is this:

  var $belongsTo = array(
  'Vendor' => array('counterCache' => true)
  );

  var $hasMany = array(
'SalesTransaction' => array(
  'className' => 'SalesTransaction',
  'foreignKey' => 'item_id'
)
  );

My SalesTransaction model code for the relation is this:

  var $belongsTo = array(
  'Item' => array('className' => 'Item',
'foreignKey' => 'item_id',
'fields' => array('id', 'quantity')
  )
);

For brevity, I am leaving out some other models that don't pertain to
this particular problem.

In my controller code, I construct the array ($items) to pass to
saveAll().

debug($items); output looks like this:

Array
(
[0] => Array
(
[id] => 1250
[price] => 14.29
[quantity] => 9
[Vendor] => Array
(
)

[SalesTransaction] => Array
(
[0] => Array
(
[sale_id] => 1404
[type_id] => 1
[item_id] => 1250
[old_qty] => 10
[new_qty] => 9
)

)

)

[1] => Array
(
[id] => 1251
[price] => 28.57
[quantity] => 9
[Vendor] => Array
(
)

[SalesTransaction] => Array
(
[0] => Array
(
[sale_id] => 1404
[type_id] => 1
[item_id] => 1251
[old_qty] => 10
[new_qty] => 9
)

)

)

[2] => Array
(
[id] => 1252
[price] => 42.86
[quantity] => 9
[Vendor] => Array
(
)

[SalesTransaction] => Array
(
[0] => Array
(
[sale_id] => 1404
[type_id] => 1
[item_id] => 1252
[old_qty] => 10
[new_qty] => 9
)

)

)

)

The code that does the saveAll() is:
$this->Item->saveAll($items, array('fieldList'=>array('quantity')))

The debug output looks like this:

START TRANSACTION   0   0
19  SELECT COUNT(*) AS `count` FROM `items` AS `Item` WHERE
`Item`.`id` = 12501 1 1
20  UPDATE `items` SET `quantity` = 9, `modified` = '2011-01-17
15:00:46' WHERE `items`.`id` = 1250   1   1
21  SELECT `Item`.`vendor_id` FROM `items` AS `Item` WHERE `Item`.`id`
= 1250 LIMIT 1   1 1 0
22  SELECT COUNT(*) AS `count` FROM `items` AS `Item` WHERE
`Item`.`vendor_id` = 2761 1 2
23  UPDATE `vendors` AS `Vendor` SET `Vendor`.`item_count` = 3 WHERE
`Vendor`.`id` = 2760   1
24  SELECT COUNT(*) AS `count` FROM `items` AS `Item` WHERE
`Item`.`id` = 12511 1 1
25  UPDATE `items` SET `quantity` = 9, `modified` = '2011-01-17
15:00:46' WHERE `items`.`id` = 1251   1   1
26  SELECT `Item`.`vendor_id` FROM `items` AS `Item` WHERE `Item`.`id`
= 1251 LIMIT 1   1 1 1
27  SELECT COUNT(*) AS `count` FROM `items` AS `Item` WHERE
`Item`.`vendor_id` = 2761 1 2
28  UPDATE `vendors` AS `Vendor` SET `Vendor`.`item_count` = 3 WHERE
`Vendor`.`id` = 2760   1
29  SELECT COUNT(*) AS `count` FROM `items` AS `Item` WHERE
`Item`.`id` = 12521 1 1
30  UPDATE `items` SET `quantity` = 9, `modified` = '2011-01-17
15:00:46' WHERE `items`.`id` = 1252   1   1
31  SELECT `Item`.`vendor_id` FROM `items` AS `Item` WHERE `Item`.`id`
= 1252 LIMIT 1   1 1 1
32  SELECT COUNT(*) AS `count` FROM `items` AS `Item` WHERE
`Item`.`vendor_id` = 2761 1 2
33  UPDATE `vendors` AS `Vendor` SET `Vendor`.`item_count` = 3 WHERE
`Vendor`.`id` = 2760   1
34  COMMIT

BTW, I have an afterSave() in Items that updates the item_count in
Vendors.

It updates the 3 Item.quantity values but does not insert new
SalesTransaction records.

I would appreciate any help you can give.

Ken

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 th

Re: CakePHP ACL [Failed ARO/ACO node lookup in permissions check]

2011-01-17 Thread DragonFlyEye
You actually want to reference the model then the aco in question. For 
example, if you have a Users model and you want to identify a user with an 
id of 1, you would actually write:
User.1

Not simply "1." That's very confusing and ambiguous in the documentation. 
Took me a while to figure it out. Also a heads up: you almost certainly will 
want to use the Console to do a lot of the initial setup for your ACLs. But 
take a careful look at the code, because the --help menus don't explain what 
comes first, the ACO or the ARO in the function call. I put in to have the 
help menu updated - even gave them a patch over at Lighthouse - but I 
haven't seen it yet. I would love to take some time and rewrite parts of the 
ACL documentation in the book but oh, man, is that a tall order.

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


CakePHP ACL [Failed ARO/ACO node lookup in permissions check]

2011-01-17 Thread DatacenterHellas
Hello.

I have create an application with CakePHP that uses the ACL.

In my database I have this data:

AROS:
=
|__ID__|__PARENT_ID__|__MODEL|__FOREIGN_KEY__|
__ALIAS__|_lft__|_rght_|
=
|__1___|__null_|__Group__|__1__|
__Administrators___|__1__|__4__|
|__2___|__1___|__User___|__1__|
__admin__|__2__|__3__|
|__3___|__null_|__Group__|__2__|
__Accountants |__5__|__6__|
|__4___|__null_|__Group__|__3__|__Database
Admins`|__7__|__8__|
|__5___|__null_|__Group__|__4__|
__Translators__|__9__|__14_|
|__6___|__5___|__User___|__2__|
__engtrans|__10_|__11_|
|__7___|__5___|__User___|__3__|
__esptrans|__12_|__13_|
=

ACOS
=
|__ID__|__PARENT_ID__|__MODEL|__FOREIGN_KEY__|
__ALIAS__|_lft__|_rght_|
=
|__1___|__null_|__null|__null|
__controllers__|__1__|__4__|
|__2___|__1___|__null|__null|
__Groups |__2__|__3__|
|__3___|__null_|__null|__null|
__Users__|__5__|__6__|
=

AROS_ACOS

|__ID__|__ARO_ID__|__ACO_ID__|___CREATE__|___READ__|___UPDATE__|
___DELETE__|

|__1__|__1|__1|__1_|__1___|__1_|
__1__|


and then in my Site I do that

$aco = ''controllers";
$aro = 1;
$this->AccessControll->getPermission($aco, $aros);

and I get this error :

Warning (512): DbAcl::check() - Failed ARO/ACO node lookup in
permissions check.  Node references:
Aro: 1
Aco: controllers [CORE\cake\libs\controller\components\acl.php, line
275]

[Warning -> code]
if (empty($aroPath) || empty($acoPath)) {
trigger_error(__("DbAcl::check() - Failed ARO/ACO node
lookup in permissions check.  Node references:\nAro: ", true) .
print_r($aro, true) . "\nAco: " . print_r($aco, true),
E_USER_WARNING);

[Warning -> context]
$aro=   "1"
$aco=   "controllers"
$action =   "create"
$permKeys   =   array(
"_create",
"_read",
"_update",
"_delete"
)
$aroPath=   false
$acoPath=   array(
array(
"Aco" => array()
)
)

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: Sorting feature

2011-01-17 Thread Jon Bennett
On 17 January 2011 13:00, earth  wrote:
> I have a cakePHP application with a properties table and a
> property_prices table. The price table holds property prices for
> different ranges.
>
> properties Table
> 
> id
> name
>
>
> property_prices Table
> -
> id
> property_id
> date_from
> date_to
> price
>
>
> I have another table property_shortlists which stores properties short
> listed by a user.
>
> property_shortlists Table
> ---
> id
> user_id
> property_id
>
>
> In a page it shows the list of shortlisted properties with a option to
> sort the list base on property price. Since there is no direct
> relation between the property_shortlists and property_prices table i
> am having difficulty in applying the sort feature. I have tried using
> unbind and bind but that did not helped.

You'll need to join the tables together so you can search them in a
single query, have a read of
http://book.cakephp.org/view/1047/Joining-tables Not that joins
interfere with the 'contain' params, ime it's best to set contain to
false and then add your fields manually to your find params.

hth

j

-- 
jon bennett - www.jben.net - blog.jben.net

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


Changing /webroot and /views directories

2011-01-17 Thread DragonFlyEye
Because I am setting up a core web engine that will drive a number of 
different sites for my company, it makes sense to me to change the location 
of the /webroot and /views directories. That way I can keep those under 
separate version control and develop the front-end distinctly from the 
back-end. I see that these paths are defined by constants. Is there a 
vehicle for setting our own custom definitions for these constants, or no?

I realize that I could probably just use a soft link to each directory 
wherever I want them to be, but my concern there is just that I'll have to 
redefine these links with every new project.

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: ACL Question

2011-01-17 Thread CrotchFrog
Hi John,

I do use a plugin to manage permissions and it seems to work quite
well
although I still prefer the shell interface for adding/removing aro/
aco
and creating permissions on the fly.

The grey area for me right now is authorizing CRUD vs. otherActions.
I know that I can use Auth->mapActions and treat otherActions as CRUD
but I assumed that Auth->authorize='actions' would allow me grant/
deny
permissions on that action regardless of what the action does in
relation
to CRUD.

I guess I'm still a bit confused here.

On Jan 15, 11:02 pm, John Maxim  wrote:
> Hi Ed,
>
> You can customise your users permission using ACL plugin. I suggest
> finding one on your own, the current one I use has a drawback when I
> have over 10 groups with different permission settings. The role
> permission setting stops working. However, it's still effective if I
> view users roles or users permission, and from there we can customise
> the users permission.
>
> You may want to refer to this:
>
> http://www.alaxos.net/blaxos/pages/view/7
>
> I'm not sure if you can find a better one or make one. The recommended
> ACL plugins can be found here:
>
> Mark Story's ACL extras and menu components.
>
> http://josediazgonzalez.com/2010/08/16/cakephp-plugins-a-biblical-ret...
>
> If anytime you managed to get one working better than any above, share
> with me.
>
> :-)
>
> Best regards,
> Maxim.
>
> On Jan 16, 9:59 am, Ed Propsner  wrote:
>
>
>
>
>
>
>
> > I've been plugging away with Cake for some time now with extremely few
> > issues. I recently decided that ACL was the right choice for my app ... now
> > I have issues :)
>
> > I've toyed with it long enough now that I understand the concept and
> > mechanics of it but the issue I'm having is this:
> > When granting access, it seems to be all or nothing. If I take the Group
> > users for example, access has to be at
> > CRUD 1 1 1 1 or sitewide access is denied. Changing it to CRUD 1 1 1 0
> > denies access not just to the controller or parts of it,
> > but the entire app. I was assuming that ultimately I would be able deny
> > access to any controller/action that I want but it
> > doesn't seem to be working out that way for me.
>
> > What I am overlooking here? I referenced the tutorial in the book when
> > putting the ACL together so the set-up is
> > very straightforward. I didn't try to do anything fancy or creative with it,
> > it's all by the book.

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: ApiGenerator plugin: Exclude plugins directory... and some other questions. --psybear

2011-01-17 Thread Joshua Muheim
Thanks, Mikek, this already helps a lot!

On Mon, Jan 17, 2011 at 4:46 PM,   wrote:
>> Isn't there anybody using ApiGenerator?
>
> there is.
>
> to exclude various stuff. make sure you have an [exclude] added to your
> api_config.ini in api_generator/config/
>
> mine is below:
>
> [exclude]
> properties = private
> methods = private
> directories = webroot, tmp, static, locale, vendors, .svn, plugins
> files = index.php, empty
>
> I dont know the answers to your other questions.
>
> regards
> mikek
>
>
>
>
>> On Thu, Jan 13, 2011 at 11:28 AM, Joshua Muheim 
>> wrote:
>>> Another one:
>>>
>>> I have constants in my classes like so:
>>>
>>>  /**
>>>   * Grenze, nach welchem Lebensjahr der Zivi höchstens noch 26
>>> Diensttage pro Folgejahr bis Dienstende aufweisen darf.
>>>   *
>>>   * @var int
>>>   */
>>>  const AUFRAEUM_ALTER_IN_JAHREN = 27;
>>>
>>> But they don't seem to be considered in the documentation. Is this
>>> normal? Aren't constants added to the API documentation?
>>>
>>> On Thu, Jan 13, 2011 at 10:22 AM, Joshua Muheim 
>>> wrote:
 And another question:

 I'd like to have code examples in my method descriptions. I know that
 I can put them into back ticks for inline code, but it seems I can't
 create blocks of code using 4 spaces?!

  /**
   * Constructor.
   *
   *    This should be code
   */

 Thanks for informations.

 On Thu, Jan 13, 2011 at 9:32 AM, psybear83  wrote:
> Hey everybody
>
> I'm trying to get the ApiGenerator plugin to do what I want. I have
> placed it in myapp/app/plugins, and built the index using
>
> cake api_index update
>
> Now I have some problems...
>
> 1) I don't want the ApiGenerator to generate the API for the myapp/
> plugins directory, because in there is the ApiGenerator itself, and I
> don't want my generated API to be cluttered up with ApiGenerator's
> API. I tried moving the plugin to myapp/plugins, but then when running
>
> cake api_index update
>
> it doesn't find the database configuration anymore. I guess I haven't
> really understood how myapp/plugins and myapp/app/plugins differ in
> what they really are meant to be...?
>
> 2) I'm writing a custom library in OOP PHP5 that is placed in myapp/
> app/libs. Some of these files are found by ApiGenerator, but others
> aren't, and I'm not able to find the reason.
>
> For example, Einsatz class is found:
>
> myapp/app/libs/einsatz.php
>  /**
>  * Einsatz File.
>  *
>  * PHP version 5
>  * CakePHP version 1.3
>  *
>  * @package    zivisim
>  * @subpackage zivisim.libs
>  */
>
> /**
>  * Included libs
>  */
> App::import('Lib', array('OptionsSetter'));
>
> /**
>  * Einsatz Class.
>  *
>  * @package    zivisim
>  * @subpackage zivisim.libs
>  */
> class Einsatz extends OptionsSetter {
>  ...
> }
> ?>
>
> But DiensttageCalculator isn't:
> myapp/app/libs/diensttage_calculator.php
>  /**
>  * DiensttageCalculator File.
>  *
>  * PHP version 5
>  * CakePHP version 1.3
>  *
>  * @package    zivisim
>  * @subpackage zivisim.libs
>  */
>
> /**
>  * Included libs
>  */
> App::import('Lib', array('OptionsSetter'));
>
> /**
>  * DiensttageCalculator Class.
>  *
>  * @package    zivisim
>  * @subpackage zivisim.libs
>  */
> abstract class DiensttageCalculator extends OptionsSetter {
>  ...
> }
> ?>
>
> I can't see any significant difference between the two files and their
> content. Maybe someone of you can point me into the right direction?
>
> Thanks
> Josh
>
> 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
>

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

Re: ApiGenerator plugin: Exclude plugins directory... and some other questions. --psybear

2011-01-17 Thread mikek
> Isn't there anybody using ApiGenerator?

there is.

to exclude various stuff. make sure you have an [exclude] added to your
api_config.ini in api_generator/config/

mine is below:

[exclude]
properties = private
methods = private
directories = webroot, tmp, static, locale, vendors, .svn, plugins
files = index.php, empty

I dont know the answers to your other questions.

regards
mikek




> On Thu, Jan 13, 2011 at 11:28 AM, Joshua Muheim 
> wrote:
>> Another one:
>>
>> I have constants in my classes like so:
>>
>>  /**
>>   * Grenze, nach welchem Lebensjahr der Zivi höchstens noch 26
>> Diensttage pro Folgejahr bis Dienstende aufweisen darf.
>>   *
>>   * @var int
>>   */
>>  const AUFRAEUM_ALTER_IN_JAHREN = 27;
>>
>> But they don't seem to be considered in the documentation. Is this
>> normal? Aren't constants added to the API documentation?
>>
>> On Thu, Jan 13, 2011 at 10:22 AM, Joshua Muheim 
>> wrote:
>>> And another question:
>>>
>>> I'd like to have code examples in my method descriptions. I know that
>>> I can put them into back ticks for inline code, but it seems I can't
>>> create blocks of code using 4 spaces?!
>>>
>>>  /**
>>>   * Constructor.
>>>   *
>>>   *    This should be code
>>>   */
>>>
>>> Thanks for informations.
>>>
>>> On Thu, Jan 13, 2011 at 9:32 AM, psybear83  wrote:
 Hey everybody

 I'm trying to get the ApiGenerator plugin to do what I want. I have
 placed it in myapp/app/plugins, and built the index using

 cake api_index update

 Now I have some problems...

 1) I don't want the ApiGenerator to generate the API for the myapp/
 plugins directory, because in there is the ApiGenerator itself, and I
 don't want my generated API to be cluttered up with ApiGenerator's
 API. I tried moving the plugin to myapp/plugins, but then when running

 cake api_index update

 it doesn't find the database configuration anymore. I guess I haven't
 really understood how myapp/plugins and myapp/app/plugins differ in
 what they really are meant to be...?

 2) I'm writing a custom library in OOP PHP5 that is placed in myapp/
 app/libs. Some of these files are found by ApiGenerator, but others
 aren't, and I'm not able to find the reason.

 For example, Einsatz class is found:

 myapp/app/libs/einsatz.php
 >>> /**
  * Einsatz File.
  *
  * PHP version 5
  * CakePHP version 1.3
  *
  * @package    zivisim
  * @subpackage zivisim.libs
  */

 /**
  * Included libs
  */
 App::import('Lib', array('OptionsSetter'));

 /**
  * Einsatz Class.
  *
  * @package    zivisim
  * @subpackage zivisim.libs
  */
 class Einsatz extends OptionsSetter {
  ...
 }
 ?>

 But DiensttageCalculator isn't:
 myapp/app/libs/diensttage_calculator.php
 >>> /**
  * DiensttageCalculator File.
  *
  * PHP version 5
  * CakePHP version 1.3
  *
  * @package    zivisim
  * @subpackage zivisim.libs
  */

 /**
  * Included libs
  */
 App::import('Lib', array('OptionsSetter'));

 /**
  * DiensttageCalculator Class.
  *
  * @package    zivisim
  * @subpackage zivisim.libs
  */
 abstract class DiensttageCalculator extends OptionsSetter {
  ...
 }
 ?>

 I can't see any significant difference between the two files and their
 content. Maybe someone of you can point me into the right direction?

 Thanks
 Josh

 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

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


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: ApiGenerator plugin: Exclude plugins directory... and some other questions. --psybear

2011-01-17 Thread Joshua Muheim
Isn't there anybody using ApiGenerator?

On Thu, Jan 13, 2011 at 11:28 AM, Joshua Muheim  wrote:
> Another one:
>
> I have constants in my classes like so:
>
>  /**
>   * Grenze, nach welchem Lebensjahr der Zivi höchstens noch 26
> Diensttage pro Folgejahr bis Dienstende aufweisen darf.
>   *
>   * @var int
>   */
>  const AUFRAEUM_ALTER_IN_JAHREN = 27;
>
> But they don't seem to be considered in the documentation. Is this
> normal? Aren't constants added to the API documentation?
>
> On Thu, Jan 13, 2011 at 10:22 AM, Joshua Muheim  wrote:
>> And another question:
>>
>> I'd like to have code examples in my method descriptions. I know that
>> I can put them into back ticks for inline code, but it seems I can't
>> create blocks of code using 4 spaces?!
>>
>>  /**
>>   * Constructor.
>>   *
>>   *    This should be code
>>   */
>>
>> Thanks for informations.
>>
>> On Thu, Jan 13, 2011 at 9:32 AM, psybear83  wrote:
>>> Hey everybody
>>>
>>> I'm trying to get the ApiGenerator plugin to do what I want. I have
>>> placed it in myapp/app/plugins, and built the index using
>>>
>>> cake api_index update
>>>
>>> Now I have some problems...
>>>
>>> 1) I don't want the ApiGenerator to generate the API for the myapp/
>>> plugins directory, because in there is the ApiGenerator itself, and I
>>> don't want my generated API to be cluttered up with ApiGenerator's
>>> API. I tried moving the plugin to myapp/plugins, but then when running
>>>
>>> cake api_index update
>>>
>>> it doesn't find the database configuration anymore. I guess I haven't
>>> really understood how myapp/plugins and myapp/app/plugins differ in
>>> what they really are meant to be...?
>>>
>>> 2) I'm writing a custom library in OOP PHP5 that is placed in myapp/
>>> app/libs. Some of these files are found by ApiGenerator, but others
>>> aren't, and I'm not able to find the reason.
>>>
>>> For example, Einsatz class is found:
>>>
>>> myapp/app/libs/einsatz.php
>>> >> /**
>>>  * Einsatz File.
>>>  *
>>>  * PHP version 5
>>>  * CakePHP version 1.3
>>>  *
>>>  * @package    zivisim
>>>  * @subpackage zivisim.libs
>>>  */
>>>
>>> /**
>>>  * Included libs
>>>  */
>>> App::import('Lib', array('OptionsSetter'));
>>>
>>> /**
>>>  * Einsatz Class.
>>>  *
>>>  * @package    zivisim
>>>  * @subpackage zivisim.libs
>>>  */
>>> class Einsatz extends OptionsSetter {
>>>  ...
>>> }
>>> ?>
>>>
>>> But DiensttageCalculator isn't:
>>> myapp/app/libs/diensttage_calculator.php
>>> >> /**
>>>  * DiensttageCalculator File.
>>>  *
>>>  * PHP version 5
>>>  * CakePHP version 1.3
>>>  *
>>>  * @package    zivisim
>>>  * @subpackage zivisim.libs
>>>  */
>>>
>>> /**
>>>  * Included libs
>>>  */
>>> App::import('Lib', array('OptionsSetter'));
>>>
>>> /**
>>>  * DiensttageCalculator Class.
>>>  *
>>>  * @package    zivisim
>>>  * @subpackage zivisim.libs
>>>  */
>>> abstract class DiensttageCalculator extends OptionsSetter {
>>>  ...
>>> }
>>> ?>
>>>
>>> I can't see any significant difference between the two files and their
>>> content. Maybe someone of you can point me into the right direction?
>>>
>>> Thanks
>>> Josh
>>>
>>> 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
>>>
>>
>

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: Plugins

2011-01-17 Thread Jeremy Burns | Class Outfit
Doh.  ^^ indeed.

Jeremy Burns
Class Outfit

jeremybu...@classoutfit.com
(t) +44 (0) 208 123 3822
(m) +44 (0) 7973 481949
Skype: jeremy_burns
http://www.classoutfit.com

On 17 Jan 2011, at 13:52, euromark wrote:

> i think you posted your component in the wrong thread, jeremy^^
> 
> On 17 Jan., 14:02, earth  wrote:
>> Thanks Jeremy
>> Please provide the link here once you post it.
>> 
>> On Jan 15, 8:17 pm, Jeremy Burns | Class Outfit
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>>  wrote:
>>> I wrote an Authorize.net component a while back...I'll drag a copy out and 
>>> post it.
>> 
>>> Jeremy Burns
>>> Class Outfit
>> 
>>> jeremybu...@classoutfit.comhttp://www.classoutfit.com
>> 
>>> On 15 Jan 2011, at 14:09, Larry E. Masters wrote:
>> 
 Write the plugin if you need it. Chances are if you have not found it 
 using a google search or on Github there is not one publicly available.
>> 
 --
 Larry E. Masters
>> 
 On Sat, Jan 15, 2011 at 12:52 AM, earth  wrote:
 Any update on the plugins for Authorize.net (AIM method) and iTransact
 payment gateways.
>> 
 On Jan 14, 7:34 pm, earth  wrote:
> Hello,
>> 
> Is their any cakePHP plugin for Authorize.net (AIM method) and
> iTransact payment gateways.
>> 
 Check out the new CakePHP Questions sitehttp://cakeqs.organdhelp 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 
 athttp://groups.google.com/group/cake-php?hl=en
>> 
 Check out the new CakePHP Questions sitehttp://cakeqs.organdhelp 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 
 athttp://groups.google.com/group/cake-php?hl=en
> 
> 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

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: Plugins

2011-01-17 Thread euromark
i think you posted your component in the wrong thread, jeremy^^

On 17 Jan., 14:02, earth  wrote:
> Thanks Jeremy
> Please provide the link here once you post it.
>
> On Jan 15, 8:17 pm, Jeremy Burns | Class Outfit
>
>
>
>
>
>
>
>  wrote:
> > I wrote an Authorize.net component a while back...I'll drag a copy out and 
> > post it.
>
> > Jeremy Burns
> > Class Outfit
>
> > jeremybu...@classoutfit.comhttp://www.classoutfit.com
>
> > On 15 Jan 2011, at 14:09, Larry E. Masters wrote:
>
> > > Write the plugin if you need it. Chances are if you have not found it 
> > > using a google search or on Github there is not one publicly available.
>
> > > --
> > > Larry E. Masters
>
> > > On Sat, Jan 15, 2011 at 12:52 AM, earth  wrote:
> > > Any update on the plugins for Authorize.net (AIM method) and iTransact
> > > payment gateways.
>
> > > On Jan 14, 7:34 pm, earth  wrote:
> > > > Hello,
>
> > > > Is their any cakePHP plugin for Authorize.net (AIM method) and
> > > > iTransact payment gateways.
>
> > > Check out the new CakePHP Questions sitehttp://cakeqs.organdhelp 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 
> > > athttp://groups.google.com/group/cake-php?hl=en
>
> > > Check out the new CakePHP Questions sitehttp://cakeqs.organdhelp 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 
> > > athttp://groups.google.com/group/cake-php?hl=en

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: Links

2011-01-17 Thread euromark
you probably looking for the text helper:
http://book.cakephp.org/view/216/Text

$linked_text = $text->autoLinkUrls($my_text);


On 17 Jan., 14:07, Jeremy Burns | Class Outfit
 wrote:
> There's one already in the 
> Bakery:http://bakery.cakephp.org/articles/gstoner/2008/03/12/authorize-net-a...
>
> Jeremy Burns
> Class Outfit
>
> jeremybu...@classoutfit.comhttp://www.classoutfit.com
>
> On 17 Jan 2011, at 13:03, Spha ps wrote:
>
>
>
>
>
>
>
> > Hi All,
>
> > Anyone know how to recognize links when a user adds a post so i can make 
> > the link active on the view page ?
>
> > Check out the new CakePHP Questions sitehttp://cakeqs.organd 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 
> > athttp://groups.google.com/group/cake-php?hl=en

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: Links

2011-01-17 Thread Jeremy Burns | Class Outfit
There's one already in the Bakery: 
http://bakery.cakephp.org/articles/gstoner/2008/03/12/authorize-net-aim-integration-component

Jeremy Burns
Class Outfit

jeremybu...@classoutfit.com
http://www.classoutfit.com

On 17 Jan 2011, at 13:03, Spha ps wrote:

> Hi All,
> 
> Anyone know how to recognize links when a user adds a post so i can make the 
> link active on the view page ?
> 
> 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

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


Links

2011-01-17 Thread Spha ps
Hi All,

Anyone know how to recognize links when a user adds a post so i can make the
link active on the view page ?

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: Plugins

2011-01-17 Thread earth
Thanks Jeremy
Please provide the link here once you post it.

On Jan 15, 8:17 pm, Jeremy Burns | Class Outfit
 wrote:
> I wrote an Authorize.net component a while back...I'll drag a copy out and 
> post it.
>
> Jeremy Burns
> Class Outfit
>
> jeremybu...@classoutfit.comhttp://www.classoutfit.com
>
> On 15 Jan 2011, at 14:09, Larry E. Masters wrote:
>
> > Write the plugin if you need it. Chances are if you have not found it using 
> > a google search or on Github there is not one publicly available.
>
> > --
> > Larry E. Masters
>
> > On Sat, Jan 15, 2011 at 12:52 AM, earth  wrote:
> > Any update on the plugins for Authorize.net (AIM method) and iTransact
> > payment gateways.
>
> > On Jan 14, 7:34 pm, earth  wrote:
> > > Hello,
>
> > > Is their any cakePHP plugin for Authorize.net (AIM method) and
> > > iTransact payment gateways.
>
> > Check out the new CakePHP Questions sitehttp://cakeqs.organd 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 
> > athttp://groups.google.com/group/cake-php?hl=en
>
> > Check out the new CakePHP Questions sitehttp://cakeqs.organd 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 
> > athttp://groups.google.com/group/cake-php?hl=en

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


Sorting feature

2011-01-17 Thread earth
I have a cakePHP application with a properties table and a
property_prices table. The price table holds property prices for
different ranges.

properties Table

id
name


property_prices Table
-
id
property_id
date_from
date_to
price


I have another table property_shortlists which stores properties short
listed by a user.

property_shortlists Table
---
id
user_id
property_id


In a page it shows the list of shortlisted properties with a option to
sort the list base on property price. Since there is no direct
relation between the property_shortlists and property_prices table i
am having difficulty in applying the sort feature. I have tried using
unbind and bind but that did not helped.

Please let me know how to do this.

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


CodeFest - Online Coding Festival by Department of Computer Engineering, IT-BHU

2011-01-17 Thread vishal kumar rai


Hello,
We are delighted to inform you that *CodeFest*
* *, the annual *International online 
coding festival* of *Computer Engineering Society, IT-BHU*, has been 
unveiled. 

 
CodeFest is a unique fest wherein concepts of mathematics, logic, artificial 
intelligence, algorithms, language syntax, etc. are required to be deployed 
in programming; these concepts manifest themselves in solving problems 
effectively and efficiently!

 

CodeFest was started last year. CodeFest'10 was a phenomenal success with 
participation from all over the globe.

 

CodeFest'11 is geared up with some new and pepped up events, while 
maintaining the integrity of its standards. 

*Here is a brief description of the constituent online events:*

   - *Mathmania* : **A 
   mathematical puzzle contest that puts mathematical and computational skills 
   to test.
   - *Manthan:*   An 
   algorithm intensive programming contest that would require coders to tailor 
   existing standard algorithms to solve real life computation problems.
   - *Virtual 
Combat:* 
   * *An 
   educational game wherein teams of programmed robotic tanks will fight the 
   battles for glory.* *Codes Do Fight! Watch* 
this
   * out.
   - *Perplexed:*  
   ** A programming 
   contest, aimed to test the knowledge of C, wherein codes will be rewarded 
   against syntactic constraints.
   - *Ratespiel:*   
**A 
   technical quiz covering different areas of Computer Science.


This year CodeFest, in association with 
*Technex'11*, 
brings onsite events:

   - *Eniac:*  An open 
   software exhibition where you get an opportunity to demonstrate your 
   software from any domain.
   
   - ** *Code 
Warrior*
   :  A multiple round contest to award the title of 'ultimate computer 
   geek'.

Visit our *website*  
*
*to get more details. 


*Few exciting statistics about CodeFest'10:*

   - 2354 registrations (including 128 professionals) from 680 different 
   institutions, across 59 countries.
   - Some participants were among the winners of Google Code Jam, Top Coder 
   SRMs and ACM ICPC.
   - Total prize money was a whopping amount of 260,000 INR!
   - CodeFest '10 was the largest online coding festival of the Indian 
   subcontinent in 2010 in terms of prize money!
   - CodeFest'10 was the second largest online coding festival of the Indian 
   subcontinent in 2010, next to Bitwise.
   - Gained recognition from several international organizations including 
   Codechef, Adobe, British Telecom, TCS and IEEE.   

 The *CodeFest'11 * team has set out to 
unleash a coding extravaganza. You can't afford to miss the chance to be a 
part of this fest!
 Still have any questions? Feel free to contact us at codef...@itbhu.ac.inor 
reach us personally at:

   - Mohit Bansalmohit.bansal.cs...@itbhu.ac.in
   - Saket Saurabh +91-9452-825-690 saket.saurabh.cs...@itbhu.ac.in 

We wish you all the best for CodeFest and for your future endeavors.

Be free and Happy Coding!
 
Team CodeFest
IT-BHU

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


CodeFest - Online Coding Festival by Computer Engineering Society, IT-BHU

2011-01-17 Thread vishal kumar rai
Hello,

We are delighted to inform you that *CodeFest*
* *, the annual *International online
coding festival* of *Computer Engineering Society, IT-BHU*, has been
unveiled.


CodeFest is a unique fest wherein concepts of mathematics, logic, artificial
intelligence, algorithms, language syntax, etc. are required to be deployed
in programming; these concepts manifest themselves in solving problems
effectively and efficiently!



CodeFest was started last year. CodeFest'10 was a phenomenal success with
participation from all over the globe.



CodeFest'11 is geared up with some new and pepped up events, while
maintaining the integrity of its standards.

*Here is a brief description of the constituent online events:*

   - *Mathmania* : **A
   mathematical puzzle contest that puts mathematical and computational skills
   to test.
   - *Manthan:*   An
   algorithm intensive programming contest that would require coders to tailor
   existing standard algorithms to solve real life computation problems.
   - *Virtual 
Combat:*
   * *An
   educational game wherein teams of programmed robotic tanks will fight the
   battles for glory.* *Codes Do Fight! Watch*
this
   * out.
   - *Perplexed:* 
   ** A programming
   contest, aimed to test the knowledge of C, wherein codes will be rewarded
   against syntactic constraints.
   - *Ratespiel:*

**A
   technical quiz covering different areas of Computer Science.


This year CodeFest, in association with
*Technex'11*,
brings onsite events:

   - *Eniac:*  An open
   software exhibition where you get an opportunity to demonstrate your
   software from any domain.
   
   - ** *Code
Warrior*
   :  A multiple round contest to award the title of 'ultimate computer
   geek'.

Visit our *website* 
*
*to get more details.


*Few exciting statistics about CodeFest'10:*

   - 2354 registrations (including 128 professionals) from 680 different
   institutions, across 59 countries.
   - Some participants were among the winners of Google Code Jam, Top Coder
   SRMs and ACM ICPC.
   - Total prize money was a whopping amount of 260,000 INR!
   - CodeFest '10 was the largest online coding festival of the Indian
   subcontinent in 2010 in terms of prize money!
   - CodeFest'10 was the second largest online coding festival of the Indian
   subcontinent in 2010, next to Bitwise.
   - Gained recognition from several international organizations including
   Codechef, Adobe, British Telecom, TCS and IEEE.

 The *CodeFest'11 * team has set out to
unleash a coding extravaganza. You can't afford to miss the chance to be a
part of this fest!
 Still have any questions? Feel free to contact us at
codef...@itbhu.ac.inor reach us personally at:

   - Mohit Bansalmohit.bansal.cs...@itbhu.ac.in
   - Saket Saurabh +91-9452-825-690 saket.saurabh.cs...@itbhu.ac.in

We wish you all the best for CodeFest and for your future endeavors.

Be free and Happy Coding!

Team CodeFest
IT-BHU

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