How to Manage Multidimensional Array in Cakephp

2009-02-06 Thread Maulik
hi i m going to develop an application in which i have to manage each items one bye one even i have to make total of each items how do i manage --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post

ACL/AUTH redirecting.

2009-02-06 Thread maestro777
With the ACL/Auth set up, is there a way to redirect to a specific view in the event of a user who is logged in but does not have permission to a particular action? I believe by default, it redirects to the login page. What I would like to accomplish are: 1. If the user is not logged in and trie

How to clear element cache?

2009-02-06 Thread nurvzy
So I've been reading documentation and looking through source and API and I thought I'm doing the clearing of cache correctly but I'm a little stumped as to why my element cache is not being cleared. I have a blog controller and whenever I add or edit a blog I want the element->latest_news to be

Re: DebugKit plugin: not available for Windows users?

2009-02-06 Thread Gwoo
You can download the Debug Kit from: http://thechaw.com/debug_kit/versions Comments about Chaw can be posted on: http://groups.google.com/group/chaw --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. T

Re: Collecting data from array depending on Association

2009-02-06 Thread mscdex
On Feb 6, 7:57 pm, "abergs.and...@gmail.com" wrote: > Hello! > > Im been at this for hours and hanging in the IRC channel, without > getting the final solution. > I want to share events between users... > > **I have these relations: > User hasmany Event > Event HABTM User > > **I have these table

Re: Help with linked image swap

2009-02-06 Thread Simz
use the html helper : http://book.cakephp.org/view/206/Inserting-Well-Formatted-elements image(string $path, array $htmlAttributes = array()) in your view (inside a php block) echo $html->image( "menu1.jpg", array( "onmouseover"=­>"yourJsRollOverFunc()", "onclick"=>"jsF

Re: Collecting data from array depending on Association

2009-02-06 Thread Simz
in case you don't find the "good" way ti do it i suggest you to create a custom model method using $this-­>query('your custom query') On Feb 6, 7:57 pm, "abergs.and...@gmail.com" wrote: > Hello! > > Im been at this for hours and hanging in the IRC channel, without > getting the final solut

Re: Output is not showing, but database is updated

2009-02-06 Thread Andras Kende
try to debug something like: controller: $tasks = $this->Task->find('all'); print_r($tasks); $this->set('tasks', $tasks); view: Andras On Feb 6, 2009, at 11:39 PM, abhishek wrote: > > I am writing a simple TASK application: with 1 model, 1 controller,and > 2 views. > In the application, y

Re: Output is not showing, but database is updated

2009-02-06 Thread Amit Badkas
What is the debug level? Set it to 2 if not and then look at SQL query 2009/2/7 abhishek > > I am writing a simple TASK application: with 1 model, 1 controller,and > 2 views. > In the application, you can add a task and it shows a list of all the > tasks. > > my problem is I am not getting the o

Output is not showing, but database is updated

2009-02-06 Thread abhishek
I am writing a simple TASK application: with 1 model, 1 controller,and 2 views. In the application, you can add a task and it shows a list of all the tasks. my problem is I am not getting the output shown in the index view. Database is being updated fine, which means it is working I don't know wh

Re: DebugKit plugin: not available for Windows users?

2009-02-06 Thread RichardAtHome
Another vote here for Chaw needing a download link! On Feb 6, 7:43 pm, Matt Curry wrote: > The Git link Brandon referenced does work once you get everything > setup.  I did it yesterday so I could download the API Plugin.  It > would be nice if TheChaw had a download link like GitHub.  I assume

Help with linked image swap

2009-02-06 Thread Zolthar
Learning cake/programming for the first time so please excuse me if this is a very noob question. I have tried to search this board without much success - as the responses were either too complicated or possibly I searching with the wrong keywords. What I am after is how do I get a linked image t

Collecting data from array depending on Association

2009-02-06 Thread abergs.and...@gmail.com
Hello! Im been at this for hours and hanging in the IRC channel, without getting the final solution. I want to share events between users... **I have these relations: User hasmany Event Event HABTM User **I have these tables [events] -id -user_id -title [users] -id -email -and some other colum

How to use the Security Component in unit tests

2009-02-06 Thread Fall_Line
Hi guys this is my first post here, and I've not been using Cake for long. I am writing some unit tests for the models a new application. For the most part it works well, however in my User model I use the cake security component to do some custom validation of a password confirmation. When I run

Re: IIS and isapi_rewrite 3

2009-02-06 Thread Son Dat Giang
I found it via google http://markmail.org/message/mjpds44riiet3kvr#query:iis_rewrite%20cakePHP+page:1+mid:5fopqo6gcvnyxkjn+state:results may it be helpful for you :)... - Best regards ! Giang Son Dat On vacation Mobile: +84 988114164 Email giangson...@gmail.com, gi

Re: Need help with the Improved Captcha Component

2009-02-06 Thread amarradi
Which lines of Code should i change now, i found me bug,(I changed the incorrect if-condition) but there is no code verification. How i can get it? unction add(){ $this->Captcha->case = true; if(!empty($this->data)) { $this->Translate->create(); if($this->T

Re: Filter empty Textfields

2009-02-06 Thread amarradi
On 6 Feb., 16:45, amarradi wrote: > Hello together, > > i have a form with the inputfield and a button, the input ist named > 'q' How can i filter if the form will loaded(when i klick on the view > with the forn) And the Textfield is empty? I don't know how i get the > values of the iput area?

Need help with the Improved Captcha Component

2009-02-06 Thread amarradi
Hello i've tried this Captcha Components http://bakery.cakephp.org/articles/view/improved-captcha-component Great the captcha is show in my browser :) Yeah. But no captcha checking. How do i get it, that the captcha will checked This are my directories and files first /cakePHP/app/controlle

Re: DebugKit plugin: not available for Windows users?

2009-02-06 Thread Miles J
I downloaded it without having to use git. Let me see if I can find the link. On Feb 6, 11:44 am, Matt Curry wrote: > And by "Brandon" I mean "Brendon"... > > On Feb 6, 2:43 pm, Matt Curry wrote: > > > The Git link Brandon referenced does work once you get everything > > setup.  I did it yester

Re: Linking three tables?

2009-02-06 Thread mscdex
There is also this link, which I forgot to add to my previous post: http://jbenner.net/blog/understanding-cakephp-associations --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, se

Re: Linking three tables?

2009-02-06 Thread mscdex
On Feb 6, 1:42 am, geoff wrote: > I sometimes have issues trying to lock down the types of relationships > that need to be enforced between Models. Do you have any helpful ideas/ > hints that you found helped you? I'm not sure if you've seen it previously or not, but maybe this link will help so

Re: New Paypal NVP Component in the Bakery

2009-02-06 Thread Gwoo
Please, do not post both to the bakery and the google group, it is just noise. I am sure that you are proud of the work you did, but a better approach has already been posted. http://bakery.cakephp.org/articles/view/paypal-datasource --~--~-~--~~~---~--~~ You recei

IIS and isapi_rewrite 3

2009-02-06 Thread Joos
Hello, I'm new at Cake. Unfortunately I have to work with IIS. I have installed Isapi_Rewrite 3 (from Helicon) but I don't know how to get it working. Does anybody know the settings for the combination cake + iis + isapi_rewrite 3? My app's url is http://servername/cake - Joos --~--~

Re: Router::parseExtensions case

2009-02-06 Thread mscdex
On Feb 5, 5:46 pm, Damon wrote: > Why does parseExtensions all the sudden care about case? > Router::parseExtensions('rss') won't load the proper layout file (app/ > views/layouts/rss/default.ctp), but Router::parseExtensions('RSS') > does. I don't remember it doing so in earlier versions (I'm on

Re: Database question, How do I represent a zero in a zero to one relationship?

2009-02-06 Thread mscdex
You should use a null value in the foreign key field to represent that that row doesn't participate in a relationship with the other model. On Feb 6, 12:54 pm, TonyP wrote: > I need to create a zero to one relationship for my cakephp app. I > would like to have a foreign key constraint, cascade

Re: Help with TCPDF and Auth

2009-02-06 Thread Petr Vytlačil
Nobody can help? On 4 Ún, 21:56, Petr Vytlačil wrote: > Hi I want create PDF file with lib. TCPDF. When i dont use Auth > component all is ok and call url return PDF file, but wheh I use Auth > componet in app_controller, call url dont return PDF file, sure im > login. Please help me, i dont kno

Re: How to call validation in a form that doesn't use save()?

2009-02-06 Thread Simz
In your model use "message" inside your validation rules http://book.cakephp.org/view/125/Data-Validation by default a red message will be displayed under the invalid field. you can access the error info from your controller using $errors = $this->ModelName->invalidFields(); http://book.cakephp.

Re: DebugKit plugin: not available for Windows users?

2009-02-06 Thread Matt Curry
And by "Brandon" I mean "Brendon"... On Feb 6, 2:43 pm, Matt Curry wrote: > The Git link Brandon referenced does work once you get everything > setup.  I did it yesterday so I could download the API Plugin.  It > would be nice if TheChaw had a download link like GitHub.  I assume > it's forthcom

Re: DebugKit plugin: not available for Windows users?

2009-02-06 Thread Matt Curry
The Git link Brandon referenced does work once you get everything setup. I did it yesterday so I could download the API Plugin. It would be nice if TheChaw had a download link like GitHub. I assume it's forthcoming. Most of the changes from my forked version have been merged back into the offi

Re: How to call validation in a form that doesn't use save()?

2009-02-06 Thread libard...@gmail.com
Here's what I finally did, and it is working now: function search() { if (empty($this->data)) { // just render the view } else { $this->Book->set($this->data); // sends $data to the model for validation purposes. if ($this->Book->validates()) { $results

Re: DebugKit plugin: not available for Windows users?

2009-02-06 Thread BrendonKoz
Git installer for Windows: http://code.google.com/p/msysgit/ Allows you to run Git from the Windows' command line. There's probably another way to get access to it as well, but I'm not really familiar with Git or TheChaw. Matt Curry's forked version (pseudocoder.com) is on GitHub which offers a

Re: cakeError

2009-02-06 Thread teknoid
What errors do you want to display to the user, while running in production mode? That being asked, you might take a look here on how to handle this situation: http://teknoid.wordpress.com/2008/08/29/dealing-with-errors-in-cakephp/ On Feb 6, 11:54 am, maxmil wrote: > I have found the same pro

Re: Lightwindow support with cakephp

2009-02-06 Thread ChicagoPlanesTrains
It's not pretty, but here's how I was able to make lightwindow work (after the $html->css('lightwindow')) in my view: image(IMAGE_SMALL_DISPLAY . $image['Image'] ['filename'], array('class'=>'thumb_view')); ?> MAGE_MED_DISPLAY and IMAGE_SMALL_DISPLAY are constants in my bootstrap.php file. This

DebugKit plugin: not available for Windows users?

2009-02-06 Thread rcurzon
I guess it would work fine in Windows... but you can't get it without "git"... which isn't ready for Windows? Let me know if I missed something please! -R --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" g

Database question, How do I represent a zero in a zero to one relationship?

2009-02-06 Thread TonyP
I need to create a zero to one relationship for my cakephp app. I would like to have a foreign key constraint, cascade on update. The problem is, when I use zero as the default value for the field, I get a foreign key constraint error when trying to add the constraint. This is because there is no

Re: cakeError

2009-02-06 Thread maxmil
I have found the same problem. Is this really deliberate? It takes quite a bit of power away from the cakephp errorHandling mechanism if it is and is very naughty not to mention it in the error handling pages of the manual! My solution has been to use: $this->render('/errors/custom_error'); i

Filter empty Textfields

2009-02-06 Thread amarradi
Hello together, i have a form with the inputfield and a button, the input ist named 'q' How can i filter if the form will loaded(when i klick on the view with the forn) And the Textfield is empty? I don't know how i get the values of the iput area? many greetings Marcusa Radisch --~--~-

Re: Customized View for each User

2009-02-06 Thread Webweave
You get the currently authenticated user information from the Auth object, so in your controller, you reference: $userId = $this->Auth->user('id'); You can then use the value in your find to restrict the data. On Feb 3, 7:47 pm, psa wrote: > Hello. > > I'm new to cakePHP. > I have this problem

Re: howto build an form where the Textfield and buttons are side by side

2009-02-06 Thread amarradi
On 5 Feb., 20:55, John Andersen wrote: > On Feb 4, 10:28 pm, amarradi wrote: > > > Hello together, > > > i tried it since my start with cakePHP. How get i my forms in an > > "normal" view. Textfield and the button, all what can in this time is > > to build an form where the textfield is over t

Re: total html separation in views

2009-02-06 Thread TheIdeaMan
I'd have to agree with Tobiasz. I don't know how I missed this conversation, but I wished I'd seen it five months ago. I just found Tobiasz site and was overjoyed as I was on the cusp of building my own similar solution. Reasons for using this over other strait PHP would be: security, separation

Using Configure class in custom AppError

2009-02-06 Thread oleonav
Hi there, I have some variables set using the Configure class in the beforeFunction of the main AppController. I use for multiple things, for example to set the title of the page. I need a custom 404 error page, so I made a custom AppError class containing the function error404, which overrides

Cookie->write not working with localhost

2009-02-06 Thread Ramsalt
I tried to set som cookies today on my development domain(localhost), and for strange reasons it didn't work as expected. The cookie didn't live as expected and after digging into the problem I found that setting $this->Cookie->domain to false made things better. The problems seems to be that if d

Re: (how) can cake do nested applications

2009-02-06 Thread Martin Westin
Hi, I handle something similar using plugins. Each plugin can be an independent application if you like. What I went for was an application "core" that handles the main layout, users and a few global things. Then each plugin just taps into the part of the core it needs or keeps to itself. I just h

Re: Doing a NOW() in save().

2009-02-06 Thread Jorge Horacio Cué Cantú
Hello, I use: *date('Y-m-d H:i:s', time())* instead 'NOW()' and it works fine. Regards. 2009/2/5 Miles J > > I have this method that updates login information on a user. It all > works, except I cant figure out how to get the mysql NOW() to work. > Any ideas? > > function updateLogin($user,

want to know about changing layout look

2009-02-06 Thread vikas
Hello all.. I read layout tutorial from http://book.cakephp.org/view/96/Layouts I got the point about how to create default.ctp and $title_for_layout, $content_for_layout.. but I want a look of my website as like our cakephp group page where right side has a menus.. so is there need to change

Re: New Paypal NVP Component in the Bakery

2009-02-06 Thread Parris
Well not yet! It is still pending approval haha. On Feb 6, 3:10 am, Parris wrote: > Enjoy:http://bakery.cakephp.org/articles/view/paypal-direct-payment-compone... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cak

New Paypal NVP Component in the Bakery

2009-02-06 Thread Parris
Enjoy: http://bakery.cakephp.org/articles/view/paypal-direct-payment-component-using-curl --~--~-~--~~~---~--~~ 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

Curious problem with img, css, and js in plugin

2009-02-06 Thread nomen
Hello everyone: I am developing a plugin and i have a curious problem. In my first version I've got all the img, js and css in webroot. Rereading the doc I have seen that they go in plugins/mi_plugin/ vendors. So I've decided to put it there and everything is perfect. I mean: it loads

Re: Can a variable defined in one view file be used in another ?

2009-02-06 Thread WebbedIT
Is it wrong to use $this->data? I am currently doing this and any value in this array is automatically available within views AND elements. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to

Re: Router::parseExtensions case

2009-02-06 Thread hellfish
Router should automatically support any extension type right? I'm adding a ics extention for a customised calendar and CakePHP is completely ignoring that. On Feb 6, 12:14 am, brian wrote: > I think it's RequestHandler that's responsible for that, not > Router::parseExtensions(). > > Anyhoo,

Re: How to perform Add cart using bake

2009-02-06 Thread p...@otaqui.com
Hi Maulik, that's a really huge question and I don't think you're going to get a very good response. My advice would be to try and read a lot about the basics of building with cake, to try and build your shopping cart and to come back if you have a specific question about any smaller problem you

Re: How to perform Add cart using bake

2009-02-06 Thread Rimoe
bake only can help you to add to car and updataing the price detailed qty must to write code by yourself if you have the table about cart, 1. cd the directory cake/cake/console, 2. ./cake bake model 3. ./cake bake console 4. ./cake bake view 5 http://www.yoursite.com/yourtablename/ 2009

I blocked the cookies, let the 'Session.cookie' to transfer in my parameter.(but can't use)

2009-02-06 Thread Rimoe
Hi, everyone, thank you for your read this topic. I blocked the cookies. I don't want to save the 'Session.cookie' in cookies. only let the 'Session.cookie' to transfer in my parameter. I have let the function of redirect like this: function redirect($url, $status = null, $exit = true) { {

Re: need Help on Internationalization in CakePHP

2009-02-06 Thread exo_duz
Elianora, This is a French tutorial for Internationalization, have a read of this. This should help you with the basics http://www.formation-cakephp.com/41/multilingue-18n-l10n As for database content, I wouldn't suggest using the I18n in CakePHP with database queries as it is quite difficult t

Re: need Help on Internationalization in CakePHP

2009-02-06 Thread Miles J
Try placing this in your bootstrap.php or your AppController beforeFilter(): App::import('Core', 'l10n'); $l10n = new L10n(); $l10n->get('fre'); --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To pos

Re: Call to undefined method IniAcl::allow()

2009-02-06 Thread fain182
On Thu, Feb 5, 2009 at 10:18 PM, Gwoo wrote: > > try Configure::write('Acl.classname', 'INI_ACL'); i tried it, it's the same... Fatal error: Call to undefined method IniAcl::allow() in /home/fain182/workspace/cake/libs/controller/components/acl.php on line 101 > > > --~--~-~--~~--

Re: need Help on Internationalization in CakePHP

2009-02-06 Thread Elianora
here is my test file, located in "app/locale/fre/LC_MESSAGES/ default.po" : msgid "welcome_text" msgstr "Bienvenue sur le site de test de" msgid "test_by" msgstr "Les tests ici présents sont réalisés par" msgid "user_mgt" msgstr "Gestion des utilisateurs" I tried to name the language dir "fr",