Cakephp 3 and custom datasources

2015-05-31 Thread Martin
doing this at the moment? I think it is strange to make a component for receiving data. Greetings, Martin -- Like Us on FaceBook https://www.facebook.com/CakePHP Find us on Twitter http://twitter.com/CakePHP --- You received this message because you are subscribed to the Google Groups "C

CakePHP 2.5 and ACL Groups Permissions not working

2014-07-31 Thread Martin Halla
) ), 'authorize' => array( 'Actions' => array( 'actionPath' => 'controllers' ) ), /* 'authorize' => array( 'Actions', 'Contro

Initiating a 'DELETE' or 'POST' in a folder inside webroot

2013-12-22 Thread Charles Martin Mendez
Hi, I am using the fileupload jquery library. I was able to get everything working and migrated some functions to the controllers to make it compatible. The problem I am encountering is that fileupload is creating a 'Delete' button which goes to the link below: http://localhost/homsite/app/web

POST and PUT problems on add action

2013-04-26 Thread Martin Aguilar
I'm new to cakephp and I'm start loving it but today I had a problem on adding new data (action add). After baking users table the result was public function add() { if ( $this->request->is('post') ) { I had add some validation on my model to names and more fields. The first push on submit bu

Re: Update from Cakephp 2.3.0 to 2.3.1

2013-03-27 Thread Martin Aguilar
Yes, replacing the lib folder should be enough. what I do, is to organize the cake version I use on one folder. Then I make a junction from my app directory to the lib folder. Junction it's like a symlink on *nix. So upgrade or downgrade from a different version of cake, only takes a second. On

Re: how to implement Smarty 3?

2013-02-12 Thread Martin Aguilar
e it). What it this "simple vendor layer"? Thanks a lot El jueves, 29 de noviembre de 2012 08:18:43 UTC-3, lorenzoshake escribió: > > > > Il giorno sabato 17 novembre 2012 15:21:56 UTC+1, Martin Aguilar ha > scritto: >> >> For years I've been work

Re: Cake 2.2 Auth login failure

2013-01-06 Thread Martin Halla
>Group->find('list'); $this->set(compact('groups')); } /** * admin_delete method * * @throws MethodNotAllowedException * @throws NotFoundException * @param string $id * @return void */ public function admin_delete($id = null) { if (!$this->request->is('p

Cake 2.2 Auth login failure

2012-12-31 Thread Martin Halla
Hi, I have this app that uses the Auth component for login Everything works on the local machine, but fails big time live at : http://ncln.halladesign.com Can you tell me why ? Here are more details : user : t...@test.com password : password acl plugin by alexo Thanks! -- Like Us on FaceB

Re: how to implement Smarty 3?

2012-11-19 Thread Martin Aguilar
2012 22:05:19 UTC-3, romel javier gomez herrera escribió: > > hi, > > for cool views can use this framework http://twitter.github.com/bootstrap/ > and cakephp views. > > And check this to http://angularjs.org/ > > regards > > 2012/11/17 Martin Aguilar > > &

how to implement Smarty 3?

2012-11-18 Thread Martin Aguilar
For years I've been working on my own framework but now I wan't to migrate to cakephp. On my framework I used smarty for themes and to separate code from views. I always find smarty clean, nice and with a very good performance. Now I want to use it on cake but I found people saying that it has n

Are Custom find types limited for my use case?

2012-03-20 Thread martin frances
led.. Am I correct in concluding I can not longer kill the actual find while using custom find types.. this seems limiting.. Martin -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help o

Why are file names now CamelCased?

2011-11-03 Thread Martin Bean
Having been a long-time user of CakePHP 1.3, I was wondering why file and folder names are now CamelCased rather than just being lowercase and underscored? Personally, I'm a fan of using lowercase and underscores in filenames (then CamelCase in my actual class declarations) so this change is pr

cakedc search plugin - slash disapears in search

2011-03-11 Thread martin
what do i have to change please, to get the whole string to the query? Regards Martin -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related quest

Re: cakedc search plugin - two queriy types in $filterArgs

2011-03-05 Thread martin
i solved it up to now with one query, where i put everything inside what i need. but it's not a perfect solution, but it works. On 5 Mrz., 19:13, martin wrote: > cakedc is a great plugin. > i need two query types in $filterArgs > > -code- >

cakedc search plugin - two queriy types in $filterArgs

2011-03-05 Thread martin
$data, $field = null){... } public function zeitSpanneJahr ( $data, $field = null){ ... } --code-end--- the problem is, that only the second query is included in the total search query. what do i have to do please, to get both queries. i want to

Re: cakedc search plugin -

2011-03-05 Thread martin
resolved! i forgot to place the field in the $presetVars array array('field' => 'mes', 'type' => 'value'), now it works perfect. On 5 Mrz., 18:28, martin wrote: > this question belongs tu the cakedc search plugin: > > i want to populate

cakedc search plugin -

2011-03-05 Thread martin
this question belongs tu the cakedc search plugin: i want to populate a "query method" search field dropdown with the last selected value, when a search query is fired and the form and list shows again. regards from spain martin -- Our newest site for the community: CakePHP Video

Re: how to all a function from a controller action

2011-03-05 Thread martin
thank you very much! On 4 Mrz., 19:01, cricket wrote: > On Fri, Mar 4, 2011 at 11:24 AM, martin wrote: > > hi > > i'm new to cakephp, but i know about php. > > i didn't get the mvc concept 100% up to now, sorry. > > > where do i have to place a function

how to all a function from a controller action

2011-03-04 Thread martin
here i can undertand with examples, how to create own behaviors, components and helpers. i was reading the cakebook, but o would prefer more concrete examples. regards, martin -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP

$this->Html->link with javascript back()

2011-02-25 Thread martin
can't find out how to resolve: go back with: $this->Html->link -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from t

Re: file upload with miles johnsons upload plugin - without model

2011-02-25 Thread martin
r = 'files/uploads/'; > >         $this->Uploader->enableUpload = true; > >         $this->Uploader->maxFileSize = '8M'; // 8 Megabytes > >         $this->Uploader->maxNameLength = 40; > >         //$this->Uploader->mime('image', &#x

Re: I am getting an error like this after i submit an action.

2011-01-10 Thread Martin Duris
Hello, you are put something on output - write something on document (maybe something in controller ..) and than you are trying to redirect - this cause error, becose you can redirect after you put something on document as i see, you have problem in model file ... sometimes hapens to me too (and

Re: Login Redirect Problem

2011-01-08 Thread Martin Duris
rray('controller' => 'users', 'action' > => 'index'); > else > $this->Auth->loginRedirect = array('controller' => 'tenants', 'action' > => 'tenantview'); > } > } > > This produces a mu

Re: Login Redirect Problem

2011-01-07 Thread Martin Duris
i guess, problem might be here : in app_controller you define login redirect (according to standart use of Auth from tutorial) $this->Auth->loginRedirect = array('controller' => 'projects', 'action' => 'index'); you should take care of login redirect here (maybe edit it or bypass) 2011/1/7 eldor

Route question

2010-08-30 Thread Harald Martin Bråttbåkk
Hello, i simply want to change the default routing pattern "http:// example.com/controller/action/param1/param2/param3" into "http:// example.com/param1/controller/action/param2/param3". Is there a simple way to do this? Regards Harald Check out the new CakePHP Questions site http://cakeqs.org

Re: CakePHP 1.3 setup on Ubuntu

2010-08-25 Thread The Brian Martin
What does your .htaccess look like? On Aug 24, 12:22 pm, david wrote: > First, let me say I have CakePHP up and running perfectly on windows > with a wampserver instance running, so I'm familiar with the process. > I know how to get mod_rewrite setup, and set the permissions > appropriately, e

Re: compleax query

2010-06-21 Thread Martin Radosta
If you fallow the naming convetion, conditions should be: 'cp.id = CampaignStoreDate.campaign_id' AND 'Store.id = CampaignStoreDate.store_id' Can you send us the resulting SQL? (debug level 2) Thanks MARTIN On 06/21/2010 09:21 AM, rakeshyadav rakeshyadav wrote:

Re: Display Blob from db

2010-05-12 Thread Martin Radosta
); //assume jpg image echo $data['Model']['blob_file']; your view: echo $html->tag('img', array( 'src' => Router::url(array('controller' => 'your_controller', 'action' => 'show_image', $userInf

Re: how to add a relationship whit other key different to the PK

2010-05-12 Thread Martin Westin
mple, the HasMany query should be: > > SELECT `Mirror`.`id`,  FROM `mirrors` AS `Mirror` WHERE > `Mirror`.`software_id` = (6) > > But how i can put in the query, or in the conditions value add the id of > software_id?? > > Thanks in advance > > On Wed, Apr 28,

Re: Limitations to plugins for app modularity - are there any left in cake 1.3?

2010-05-11 Thread Martin Westin
I think you are reading two posts as one. I only mentioned using plugins for all visible features except a very few... nothing about paths. And to clarify about the app I refer to: The app is made up of many plugins.. not one common plugin. There is a lot of common functionality in the main app..

Cookie::delete() spits error on one server but not the other

2010-05-11 Thread Martin Westin
I have been scratching my head a bit here and can't find the problem. $this->Cookie->delete('Auth.User'); ...is called on login and logout. When sometimes the "Auth" key does not exist in the cookie __values I get a notice from PHP... but only on my production server. php.ini is a likely candidat

Re: Shared SSL and .htaccess

2010-05-11 Thread Martin Westin
Classic problem. being inside a aliased folder, like ~myuser you need to edit your .htaccess file adding a rewrite base. Search and find tons of threads discussing it in detail. (searching is easy once you know the right keywords) Once you got that done Cake should work fine. On May 10, 6:31 am,

Re: Limitations to plugins for app modularity - are there any left in cake 1.3?

2010-05-11 Thread Martin Westin
My experience tells me that almost all of your limitations did not exist even before 1.3 - plugins couldn't access or extend app's models They could. I did it regularly. - code in the app couldn't access a plugin's models They could. But I would not recommend doing it. (IMHO an app should not br

cakephp v2.0

2010-05-07 Thread Martin Neuman
Hi all, does anybody knows something about this project? After the launch of 1.3 stable the core team will move to the v2? Any beta date? or updated roadmap? Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions. You received this message

Ajax - Select - On change

2010-05-04 Thread Martin
hellou, i got little problem. I have simple form, for example : form->create('form'); $options[0] = //options for array $selected[0] = //selected thing $form->select('profiles',$options,$selected); and some ajax button : $ajax->submit('Choose', array( 'update' => 'content')); just simple, afte

Re: how to add a relationship whit other key different to the PK

2010-04-28 Thread Martin Westin
You can set foreign_key to false and instead use the condition of the relationship. This is usually used for things like User.active => true and simple things like that but I think it can be used for your purpose. COme to think of it, I may be wrong. I vaguely recall an RC for Cake1.2 causing prob

Re: Datasource CouchDB

2010-04-28 Thread Martin Westin
This is not an answer as such, only an idea if there is no datasource already. If you feel a bit adventurous you might be able to sneak a peek at the MongoDB datasource and make a similar one for CouchDB. The two databases are not identical but I think significant parts of the datasource would be s

Re: virtual fields in conditions

2010-04-26 Thread Martin Radosta
2 others work around: - create a view - select from a subquery instead quering directly to the table. Hope this helps. MARTIN On 04/26/2010 01:05 PM, jharris wrote: Okay, so I figured out why I can't reference the alias in the WHERE conditions: it's just a MySQL restriction. As

Re: Bakery...arrogance or plain lack of attention

2010-04-26 Thread Martin Westin
t that the people involved are NOT the problem... the rest of us, not involved, are so to speak. I am sure that with more insight one could see ways of improving the software that would streamline the work of moderators. /Martin On Apr 26, 3:10 am, Graham Weldon wrote: > Most definitely.

1.3rc4 and saveAll, strange return values

2010-04-21 Thread Martin Westin
just some confusion in the way I have read the docs? thanks Martin 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

Re: composite keys to identify a record

2010-04-19 Thread Martin Westin
he classic HABTM joining table would haven been more worthy of support, seeing as there are so many of them in any given app. But I feel the topic has been discussed to death before. I don't want to start another discussion about database-religion. /Martin On Apr 18, 12:07 pm, Jeremy Burns wr

Re: mac users, which ide are you using to develop cakephp?

2010-04-18 Thread Martin Westin
No ide, just Textmate for me. On Apr 19, 6:14 am, Bryan Lim wrote: > Hi all, > > mac users, which ide are you using to develop cakephp? to compile and > to debug? > > I search the group here and realised this discussion is dated back to > 2009. So, I want to know if there's any changes? > > tha

Re: the plugins dont work at all

2010-04-16 Thread Martin Westin
be 100% how plugins react to being in a subfolder. (as in localhost/apname/) Those are all long-shots but they are all I can think of that might be the cause. Good luck. /Martin On Apr 16, 5:28 pm, islam4hak wrote: > hi > why i cant accses any plugin i create ? > > i make the manual

Tip: MongoDB-Datasource undocumented feature

2010-04-16 Thread Martin Westin
I did not know the datasource could do this and almost didn't try it as a result. Don't make the same mistake. Yasushi Ichikaway has developed a very nice datasource for MongoDB. http://github.com/ichikaway/mongoDB-Datasource/ Mars Story wrote a very nice intro post about it. http://mark-story.co

Re: CouchDB as a datasource

2010-04-15 Thread Martin Kirchgessner
Thanks Jon! Although it's young Lithium sounds very good. Martin On Apr 14, 10:39 pm, Jon Bennett wrote: > Hi Martin, > > > If you're interested here is my current try > > :http://bin.cakephp.org/view/1461894980 > > > it's not complete and doesn't

Re: CouchDB as a datasource

2010-04-14 Thread Martin Kirchgessner
If you're interested here is my current try : http://bin.cakephp.org/view/1461894980 it's not complete and doesn't work... Martin On Apr 14, 10:56 am, Martin Kirchgessner wrote: > Hi everyone, > > As a year-old CakePHP user (by the way : huge congrats to the core >

CouchDB as a datasource

2010-04-14 Thread Martin Kirchgessner
del but then it won't save anything. So I'm stuck between a normal CouchDB use (a single DB for my whole app + calls to views in mind) which doesn't seem cake-friendly and a working datasource that puts some constraints on DB design. That's why I would like to discuss it here

Timezone management advice

2010-04-12 Thread Martin Westin
business. I don't want that. :) Please fire away with your advice and experience on this topic. /Martin 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: UTF-8 website problem (database encoding works)

2010-04-07 Thread Martin Radosta
code('Mitarbeiter Test Strange_Character') . ''; give us feedback Regards MARTIN On 04/07/2010 03:35 PM, sebb86 wrote: Martin, cricket Hello, Assume you are using mysql --> yes 1) Make sure you have add this to database.php default array config:'encoding'

Re: UTF-8 website problem (database encoding works)

2010-04-07 Thread Martin Radosta
dback if it does not work for each step. Regards MARTIN On 04/07/2010 12:34 PM, sebb86 wrote: Martin Thank you for helping me! When i do what you suggest, i see the special chars. ("echo 'áéíóúñ£ €';") But, in your message, i dont see this characters. i only see it

Re: UTF-8 website problem (database encoding works)

2010-04-06 Thread Martin Radosta
file: and inside of: [code] charset(utf-8); ?> [/code] In the layout do something like this "echo 'áéíóúñ£€';" and send us the feedback. Regards MARTIN On 04/06/2010 09:35 AM, sebb86 wrote: Hello, instead of umlauts, i see only signs on my website. I think the proble

Re: How can Schema Shell create new tables?

2010-03-30 Thread Martin Westin
Also, I can't get the reverse to work either. I.e. update does not notice that a table should be dropped. I'd love some help on that also. On Mar 30, 7:51 am, Martin Westin wrote: > Hi, > "cake schema run update -f" always creates an ALTER TABLE statement. > So how

How can Schema Shell create new tables?

2010-03-29 Thread Martin Westin
e right way since it would not work at all in a deployment situation. Can it? thanks for any info you can provide. /Martin 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

Re: DataTables, cakePHP, and Pagination through Ajax

2010-03-29 Thread Martin
en doing a sort, but I am not sure how to tie in iTotalRecords and iTotalDispalyRecords. Any help, is appreciated. Martin On Mar 29, 12:07 am, Jeremy Burns wrote: > Ajax pagination is quite simple - here's a good link using MooTools (I do > exactly the same but using JQuery). Also, see

Re: Broken search on http://book.cakephp.org/

2010-03-29 Thread Martin
Fixed! Thanks guys!! On Mar 25, 2:25 pm, Martin wrote: > Have others noticed that the search option onhttp://book.cakephp.org/ > is broken? It no longer returns snippets of text with the search > results, just basic and repeating titles. > > Martin Check out the new CakePHP Ques

DataTables, cakePHP, and Pagination through Ajax

2010-03-28 Thread Martin
o pass the values iTotalRecords iTotalDispalyRecords. Any examples? Thanks, Martin 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" gr

Re: How to search - A very strange find

2010-03-26 Thread Martin Radosta
|Your question is not clear, I guess you need this: $this->Model1->Behaviors->attach('Containable'); | $this->Model1->find('first', array( 'conditions' => array('Model1.id' => $id), 'contain' => array('Model2' => array('fields' => array('Model2.title

Re: How to search - A very strange find

2010-03-26 Thread Martin Radosta
try 'recursive' => -1 On 03/26/2010 05:23 PM, amarradi wrote: I have to correct it because in the that have to be an other value $this->set('variable', $this->Model1->find('first',array( 'conditions' => array('Model1.id' => $id), 'recursive' =>

Re: non-interactive Schema Shell for deployment?

2010-03-26 Thread Martin Westin
Found a shell-based way to automatically answer the question. http://www.unix.com/shell-programming-scripting/30246-how-give-variable-command-shell-script.html On Mar 26, 3:41 pm, Martin Westin wrote: > I am almost there with the Schema Shell. Now just one thing remains. > Being able

non-interactive Schema Shell for deployment?

2010-03-26 Thread Martin Westin
I am almost there with the Schema Shell. Now just one thing remains. Being able to do "run update -f" without answering y or n to the questions. Is there a non-interactive mode for the Schema Shell? I can't see any option to do it. /Martin Check out the new CakePHP Ques

Re: cake schema run update gone crazy

2010-03-26 Thread Martin Westin
It can also be used to force update to ignore the Model classes in the same way as generate and therefore update a schema generated using the option. So, Schema Shell appear to do all the important stuff I need... more testing will confirm. On Mar 25, 4:59 pm, Martin Westin wrote: > Ah. Than

Re: CakeFest IV - America - Help us pick a location!

2010-03-25 Thread Martin
USA West Coast, please. :) 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 T

Broken search on http://book.cakephp.org/

2010-03-25 Thread Martin
Have others noticed that the search option on http://book.cakephp.org/ is broken? It no longer returns snippets of text with the search results, just basic and repeating titles. Martin Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related

Re: cake schema run update gone crazy

2010-03-25 Thread Martin Westin
Git do the versioning feel just right next to the rails-type schema files. So I guess I will have to start plowing the source to see if I can make it behave with my schema after a reasonable amount of work. /Martin On Mar 25, 2:07 pm, "Ian M. Jones" wrote: > Hi Martin, > > Have y

cake schema run update gone crazy

2010-03-25 Thread Martin Westin
I thought I'd give schema migrations a try. But something small must be horribly wrong with how I am trying to use the schema shell. I run "cake schema run update" on the database that just generated the schema and the shell wants to add all the columns to the tables again. That can't be right? Wh

Re: Basic ACL question; Why have all users in the ARO?

2010-03-23 Thread Martin Duris
try this : http://book.cakephp.org/view/465/Understanding-How-ACL-Works sometimes, maybe you will need to create groups for users but in those groups there will must be some users, who have special - premium acces ... 2010/3/23 xtraorange : > Howdy all, > > Maybe someone can explain this to me, be

Re: Class 'AppController' not found.

2010-03-23 Thread Martin Duris
check, if you you have AppController in "C:\xampp\htdocs\cakephp\app\ ..." maybe you have deleted it ... 2010/3/23 Sean : > Hey, guys.  I'm a newbie here.  I encountered this problem when trying > to run a simple controller starting with the following lines: > > class UsersController extends AppC

Re: different types of Users

2010-03-17 Thread Martin Duris
one of the key to understand is to know how ACL works - tree structure - than its just question of time, to get everything work 2010/3/17 Alejandro Gomez Fernandez : > I'm new usign cake, but not designing information systems in different > platforms, even web. > I think the solution to your dilem

Re: different types of Users

2010-03-17 Thread Martin Duris
Using ACL can be very confusing, but it also can be usied to create simple accesing rules - you have 3 groups (maybe 4 when couting even visitors - ACL should work fine with that - its just point of view) but i didnt understand completly your problem - you vae problem with that, you dont know what

Re: I have an ORM problem

2010-03-12 Thread Martin Duris
dont put echo debug($this->Book->Author->find('all')); just into class controller - you need to put in some function (for exampplne into index fuction) 2010/3/12 Mónico Briseño : > Hi, all.  Paul, I did your suggestion. I got the following: > > > class BooksController extends AppController { > e

Re: I have an ORM problem

2010-03-11 Thread Martin Duris
in index.ctp try to write or at least - print_r($books); - so we will know, is in fields - array 2010/3/11 Mónico Briseño : > Paul, Structure of two tables > > CREATE TABLE `authors` ( >     `id` int( 11 ) NOT NULL AUTO_INCREMENT PRIMARY KEY , >     `name` varchar( 127 ) NOT NULL , >     `email`

Re: cake php XML parser timing out after 30 seconds (not max_execution_time or max_input_time limit)

2010-03-10 Thread Martin Duris
dont know exact answer...but maybe i can help you or point you to some good way if i understand...you want to parse some xml from web -> mean, download xml and parse it ... so, maybe u should try to "avoid" using cakephp defined functions (create some component to download and parse zml - witch you

Re: I have an ORM problem

2010-03-10 Thread Martin Duris
yeah, debug yout $book variable is good point (or just use print_r($book)) even that, i still think problem is Author - Name (acording to the your error log ...) 2010/3/10 WebbedIT : > Before you move to your view, make sure your controller is sending the > right data to the view. > > In your con

Re: I have an ORM problem

2010-03-09 Thread Martin Duris
> Undefined index: Author [APP/views/books/index.ctp, line 9] problem line : > i think, problem is in parsed array - you are trying to echo something that not exist - in array ($book['Author'] dosnt exist or $book['Author']['name'] dosnt exist ) 2010/3/9 monicob : > Hi, all. I have the foll

Re: After the Cake is baked...

2010-02-22 Thread Martin Westin
Avoid getting sued? Stop being an american work like a charm. ;) (sorry, I could not resist) On Feb 22, 8:39 am, Johnny Cupcake wrote: > OK, so after we have successfully built our modern, interactive > CakePHP website...where can we learn how to actually /run/ the > website?  Can you recommend

Re: Complex find() using Oracle

2010-02-18 Thread Martin Radosta
I would only change: $this->find('all', array('fields' => $fields,...etc, etc.) Would be great if you post the test case (or even better, a patch) to avoid other people waste time with the same issue. Bye MARTIN On 02/18/2010 05:39 PM, Tony Fugere wrote: It do

Re: Complex find() using Oracle

2010-02-18 Thread Martin Radosta
ollow what you mean by "Try using expression for fields." Can you clarify or give me an example? On Feb 18, 11:12 am, Martin Radosta wrote: CakePhp is not correctly parsing the alias for the decode fields, thats why you see decode... on array keys. Try using expression for fields

Re: Complex find() using Oracle

2010-02-18 Thread Martin Radosta
CakePhp is not correctly parsing the alias for the decode fields, thats why you see decode... on array keys. Try using expression for fields. If that works, should also fix the data missmatch. Regards MARTIN On 02/18/2010 02:38 PM, TonyFugere wrote: I've search this group and Google

Re: 1.2.6 strtotime error

2010-02-18 Thread Martin Westin
timezones you can set that PHP doesn't actually support :) /Martin On Feb 17, 8:56 pm, Selino wrote: > :PHP Warning:  strtotime(): It is not safe to rely on the system's > timezone settings. You are *required* to use the date.timezone setting > or the date_default_timezone_set(

Re: Query to compare items of two users

2010-02-15 Thread Martin Radosta
better than buildStatement for this case I suggest to use expressions. This also works with pagination Hope this helps MARTIN On 02/15/2010 02:51 PM, blake wrote: First, I brief table structure overview: titles (id, name, etc) users (id, name, etc) titles_users (id, title_id, user_id

Re: sql expression in CAKE?

2010-02-11 Thread Martin Radosta
. Hope this helps. MARTIN On 02/11/2010 06:19 AM, toka...@gmail.com wrote: Hi, how can I pass a MATH operation into SQL via cake?? I try to do this..but cake always quotes the '+ 1' as well, and sql then treat it as a string... array('Section.rght' => 'Sect

Re: Access Global Function in CakePHP

2010-02-10 Thread Martin Westin
I can not imagine why you would use a localized variable variable. Anyway... $temp_var = __('String',true); echo "{${$temp_var}}"; On Feb 11, 8:14 am, Mukhamad Ikhsan wrote: > global function like __() is break the OOP concept, in some cases i need the > function bind to an object > > case:

Re: inflector - class methods - slug ????

2010-02-10 Thread Martin Westin
!!! > > I used the patch you gave, and used mb_* functions to set string to > > lowercase ( i was having problems with chars like Ó and Á ) > > > Martin what do you mean by: > > "I will let you post the ticket though." > > Sorry im not a expert on CAKEPHP , y

Re: inflector - class methods - slug ????

2010-02-10 Thread Martin Westin
Cake only supports conversion of a specified list of characters to their "root" a or o. You need to patch the Inflector class (and post it back to the tracker). line 496 of inflector.php is where the action starts. It is quite obvious where to add your additional characters. Actually I added those

Re: About CakePHP and DB2

2010-02-10 Thread Martin Westin
Can you be more specific. Do you have a problem with CakePHPs db2 driver? What specifically is not working? I haven't used many drivers (MySQL and Sqlite) but I would expect them all to work just by choosing to use them. >From the manual var $default = array('driver' => 'db2',

Mongo without a schema?

2010-02-09 Thread Martin Westin
Hi, I thought I'd see if any user or contributor to the MongoDB datasource can answer this question. The datasource is this one by ichikaway: http://github.com/ichikaway/mongoDB-Datasource The datasource strangely requires each model to define $_schema in the class definition. I say strangely sin

Re: Create association with a join table.

2010-02-08 Thread Martin Radosta
l'=>false, 'type'=>'hidden')); echo $form->input('MenuRecipe.menu_id'); $form->end('Add to Menu'); ?> Regards, MARTIN On 02/05/2010 05:33 PM, RhythmicDevil wrote: Hi, having some problems understanding

Re: Release: CakePHP 1.2.6

2010-02-01 Thread Martin Westin
I want to add my thanks to everyone contributing. @Mark Did you forget to make this topic a "sticky"? On the first page in the google group the 1.2.5 announcement is still pinned at the top but this one is not. Check out the new CakePHP Questions site http://cakeqs.org and help others with their

Re: now Using Session on my model

2010-01-28 Thread Martin Radosta
A callback in the controller avoid a broken the MVC pattern. On 01/28/2010 02:20 PM, Jamie wrote: Well, it's certainly better than importing the component... If you want to be strict about it (and I'm not exactly sure how the method I suggests falls outside of the MVC pattern, since session i

select with link

2010-01-20 Thread martin
hi, I need that when is onChange, redirect me to the view page of the product (this is on views/layouts/default ) select('Producto.Id',$this->requestAction('/ productos/findAllProductos'), null, array('onchange'=>*, 'class'=>'select')); ?> how can I do it? thanks Check out the new CakePHP Qu

Re: adding/updating additional fields in HABTM's join table

2010-01-18 Thread Martin Westin
Of-course there is :) The trick to getting some control over the join table is the "with" key. http://book.cakephp.org/view/83/hasAndBelongsToMany-HABTM This tells Cake to use your class file for the join model and any methods and settings in it. Mariano also has a good write-up of how to get th

Re: My Cake app presented at CES keynote

2010-01-18 Thread Martin Westin
@John Thanks. @Chad "I can't tell what it is exactly" Boy, do I know that phrase! It is so nice to have it out so I don't have to mask my code and questions as much. Let me know when you can tell me more. Your app sounds intriguing. Martin On Jan 18, 2:07 pm, Chad Smith

My Cake app presented at CES keynote

2010-01-18 Thread Martin Westin
I have been working on the same Cake app for the past two years. A lot of it has been a bit hush hush but last week we were truly "outed" by Qualcomm. Check out our 3 min segment from the Keynote: http://www.greatconnection.se/en/ces The system transmits medical images from echo machines (ultraso

Re: coding practices with models

2009-12-29 Thread Martin Westin
uld recommend following John's advice. /Martin On Dec 28, 1:39 pm, John Andersen wrote: > I use the model class as the maintainer of the individual record and > the provider of a collection of records. > > So in your banana example, my model would know what to do when a >

Re: Delete confirm

2009-12-03 Thread Martin Westin
thread but since you both (ionas and AD) seem to have done a fair bit of work on these things I imagine you have some technique you might be willing to share. /Martin On Dec 3, 1:40 pm, AD7six wrote: > On 2 dic, 17:27, "j0n4s.h4rtm...@googlemail.com" > > wrote: > >

Re: download API documentation and book

2009-12-03 Thread Martin Westin
which means I also get a quick index of the methods in a class just by opening the source file. I imagine other editors have similar features. /Martin On Dec 3, 11:42 am, Lorenzo Bettini wrote: > Hi > > is there a version of APIs and book documentation to be downloaded for > of

Re: HABTM questions

2009-12-03 Thread Martin Westin
About the pagination: http://book.cakephp.org/view/83/hasAndBelongsToMany-HABTM Look at the bottom. The last examples abut binding can be used to let paginator deal with your habtm. When it comes to finding related data find is better than read. But probably find('first') in this case since it doe

Re: Containable query

2009-12-03 Thread Martin Westin
least it contains some examples of using the joins key. A quick googling gave me this page detailing some variations of joins that might help you figure out which type of join you need. http://www.wellho.net/solutions/mysql-mysql-joins-using-left-join-and-right-join-to-find-orphan-rows.html /Martin

Re: TreeBehavior fails to set lft and rght correctly

2009-12-03 Thread Martin Kirchgessner
On 3 déc, 10:27, AD7six wrote: > How many fails to the tree test case give you. Well, i've found out what happens. The tree test is OK - my problem came from an overloaded updateAll in my AppModel. Sorry for spam. Check out the new CakePHP Questions site http://cakeqs.org and help others with

Re: TreeBehavior fails to set lft and rght correctly

2009-12-02 Thread Martin Kirchgessner
te on all my integer column types that store > id values but the TreeBehavior fails without any warnings or errors if the > integer column values are in the format of 0001 instead of just 1. > > On Wed, Dec 2, 2009 at 7:00 PM, Dave wrote: > > Can you paste y

  1   2   3   4   5   6   7   8   >