Re: IIS7 + CakePhp

2012-09-07 Thread nutty
Hi Guys, been struggling to configure cakephp in iis7.5. I've tried importing the rules using url rewrite to no avail. If I use the wiki web.config file it will just simply display the iis logo. Does anyone encountered same problem with me and had resolved it? Happy to hear from the group. Than

Re: Events - how do I attach additional callbacks to the HelperCollection

2012-09-07 Thread rchavik
On Friday, September 7, 2012 10:23:06 PM UTC+7, Greg wrote: > > Hi, > > I've got a case where I want one helper to raise events on other helpers. > The concept is that plugins can manipulate the output of a MenuHelper by > returning additional menu items at runtime. > > Is there a way that I can

Re: How to call a function from another controlle?

2012-09-07 Thread datgs
Can this work for Cake 1.3? On Thursday, September 6, 2012 12:23:39 PM UTC+7, andrewperk wrote: > > I do this: > > // Loads in the TestController from the Test plugin Controller package > App::uses('TestController', 'Test.Controller'); > > class AppController extends Controller { > > public f

Re: Can I have a plugin inside another plugin?

2012-09-07 Thread majna
Hi, You can append another path for plugins, something like this: app/Config/bootstrap.php: CakePlugin::load(array('Logger' => array('bootstrap' => true))); app/Plugin/Logger/bootstrap.php: App::build('Plugin' => array(CakePlugin::path('Logger') . 'Plugin')); After that you can load Recaptcha p

Nested models help (which methods to use?)

2012-09-07 Thread scotth25
Hello. I am looking for a simple solution for binding model to another model. I'm using CakePHP 2.2. I am building a JSON rest api. I currently have a simple User model with a hasOne Profile association. I want to nest the "Profile" model in the Users array, without using any views. What is th

Re: How to call a function from another controlle?

2012-09-07 Thread Chris Thompson
If it's logic used by multiple Controllers it should go in a Component. -- 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..

Re: Cakephp sql

2012-09-07 Thread Zordon
I already fixed this issue, it has something to do with the encoding format, I had do change explicitly CAST(`HitsLog`.`region_id` as CHAR) to CAST(`HitsLog`.`region_id` as CHAR CARACTER SET latin1), I knew that both tables had different encodings utf8 and latin1. On Thursday, September 6, 20

Re: Saving Multiple Models at the Same Time (MeioUpload Plugin)

2012-09-07 Thread Biswajit Ghosh
I think problem should be here in " $this->Form->create('News') ", when you worte this line, the News Model is loaded and create a form as you wish but you don't declare Upload model in anywhere.(you did not say about your controller..) On Fri, Sep 7, 2012 at 4:18 AM, andrewperk wrote: > Well it

XML->to_array() no longer works with html

2012-09-07 Thread Chris Thompson
Somewhere between 2.0.1 and 2.2.2 the Utility/Xml class lost the ability to consume and html string and output it as an array. Obviously this is an Xml class and I was asking it to work with HTML, but does anyone know if CakePHP has a class to do this still (turn html to array)? -- You receiv

do database sessions still use cookies?

2012-09-07 Thread John Moses
I'm trying to save data via the session in an iframe using the database defaults. Is there anyway to store sessions to the database bypassing cookies? I tried ini_set use_cookies to 0 and that didn't work. Thanks. -- You received this message because you are subscribed to the Google Groups "C

Re: Multiple Cron jobs & CakePHP.

2012-09-07 Thread thatsgreat2345
Well I would actually write your shell and then create whatever data fetching/caching done in your model. In your shell just do $uses = array('YourModel');. I imagine you have some sort of function in your model that grabs data and such, and then caches it. So in your shell you can do just a call

Re: Multiple Cron jobs & CakePHP.

2012-09-07 Thread Salines
OK, I need clarification! Normally in my controller or action, I use cache to save the query. as described here http://book.cakephp.org/2.0/en/core-libraries/caching.html#using-cache-store-to-common-query-results This works nicely when the user visits the page, which takes data from its own da

Re: Upload a flat file into related tables

2012-09-07 Thread Tilen Majerle
if you need to call from model, than use Model::find() method in your controller probably you will need to use "find" associated with "count" type, so check this: http://book.cakephp.org/2.0/en/models/retrieving-your-data.html#find-count -- Lep pozdrav, Tilen Majerle http://majerle.eu 2012/9/7

Re: Upload a flat file into related tables

2012-09-07 Thread Tim
I decided to to create an Uploads Controller and associated model and views. The upload form is in the index view. The form calls the upload method which puts the file into the array $rows. The upload view is only a pr($rows); at this point. So far so good. So now I want to start loading my 3

Can I have a plugin inside another plugin?

2012-09-07 Thread andrewperk
For instance I have a plugin called Logger. And inside of my Logger plugin, I want to use the Recaptcha plugin but I want it contained inside of the Logger plugin. When I try to load the plugin from within my Loggers bootstrap though it's not looking inside my /app/Plugin/Logger/Plugin directo

Re: Multiple Cron jobs & CakePHP.

2012-09-07 Thread thatsgreat2345
Create shells, http://book.cakephp.org/2.0/en/console-and-shells.html And then run them using CakePHP. Be forewarned that you can use $uses to import models, but to use components you'll need to import Controller/Component from the core, ComponentCollections, etc. I'm not an expert with shells an

Multiple Cron jobs & CakePHP.

2012-09-07 Thread Salines
Hi. Web project on which I am currently working has eight external data sources. I implemented OAuth authorization for them, etc. Next, I want to use cron for the following tasks: every minute, refresh data from twitter, facebook and mail server ( 5 different actions); Every ten minutes, refres

Events - how do I attach additional callbacks to the HelperCollection

2012-09-07 Thread Greg Skerman
Hi, I've got a case where I want one helper to raise events on other helpers. The concept is that plugins can manipulate the output of a MenuHelper by returning additional menu items at runtime. Is there a way that I can access an instance of the helper collection and attach additional callbacks

Re: cake.po: Mixed up translations for "timeAgoInWords"

2012-09-07 Thread Johannes N
thx ad7six! didn't know that there even exists a msg_id_plural. now that i know, searching the web for this problem is a lot easier. but it turned out that it doesn't work at all - although i'm using po edit now: msgid "" msgstr "" "Plural-Forms: nplurals=2; plural=(n != 1)\n" "Project-Id-Versi

Re: Cakephp sql

2012-09-07 Thread Nikhil Agrawal
I am not exactly sure, but i think there should not be such problems. Please check you database config to chk. You can give the sample of config here, On Thu, Sep 6, 2012 at 10:35 PM, Zordon wrote: > Hello everyone, after spending a lot of time trying to find out why cake > php executes queries

Re: cake.po: Mixed up translations for "timeAgoInWords"

2012-09-07 Thread AD7six
On Friday, 7 September 2012 10:24:58 UTC+2, Johannes N wrote: > > Hi guys! > > I searched the whole web, but didn't found anything about this one. > > In my latest project I use following code to inform the user, when a > sweepstake is going to end: > > Time->timeAgoInWords($challenge["Challeng

cake.po: Mixed up translations for "timeAgoInWords"

2012-09-07 Thread Johannes N
Hi guys! I searched the whole web, but didn't found anything about this one. In my latest project I use following code to inform the user, when a sweepstake is going to end: Time->timeAgoInWords($challenge["Challenge"]["end"], array("end" => "+1 year"))?> Code itself works like a charme, but

Restricting number of created records

2012-09-07 Thread DiabloGeto
Hi all, I am having a hasmany associated model to users, which i want that user can create only three records and no more, after that he can only edit them. I have implemented it in controller , by finding count , and using If condition in the add action. But it seems is it unnecessary over

Re: CakePHP 2.2.2 release

2012-09-07 Thread AD7six
On Wednesday, 5 September 2012 01:01:28 UTC+2, Shih Oon Liong wrote: > > Can we assume that upgrading from CakePHP 2.2.1 to 2.2.2 is relatively > straightforward? Cake uses semantic version numbers (http://semver.org) As such, being a patch release there are only BC compatible bugfixes inc