HI
i have a form with dropdown for selecting the industry which i have
populated.
but in the modify form, i need to set the selected value which is come from
the database.
this is the code that i have written in the view
select('industry',array($industry),*$industry*,array(),'Select
Industry'); ?
no, but yes.
Have a model, but in it set
var $useTable = false;
On Jul 21, 3:55 pm, Binoy wrote:
> Is it possible to create a new functionlity without model ?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Cake
Thanks Issac for the reply..
Let me ask one more thing that, I need to use different tables (like user,
potentail user, and subscribed user ), for the functionality. Is it possible
with your solution ? If so how can i do it..
Can you give me an example (code) for that .?
On Tue, Jul 21, 2009 at 7:
Is it possible to create a new functionlity without model ?
--~--~-~--~~~---~--~~
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 grou
Been trying to make sense of HABTM relationship. Hope someone could
help throw some light on this.
I have the following models defined:
class TblCategory extends AppModel {
var $name = 'TblCategory';
var $hasAndBelongsToMany = array('TblDetail'=>array(
hi,
everyone!
I have use ($this->Auth->user()) to get the log in info in controller.
but now I want to get the info of user in a model.
because the method of model has been used in many controller,
change the method has became a big work,
can I get the info of user in a model.php?
thank you ver
thanks and i have to extend as object and it worked.
On Tue, Jul 21, 2009 at 12:07 AM, brian wrote:
>
> Make it public and use $this->Country->values; or create a public
> method to return it:
>
> public function getTheValues() { return $this->values; }
>
>
> On Mon, Jul 20, 2009 at 6:15 AM, Pra
Hi bino,
In your views , add this line
$paginator->options(array('url' => $this->passedArgs));
Thanks
Isaac
On Sat, Jul 18, 2009 at 11:06 PM, bino dev wrote:
> Hi Friends,
>
> Iam very new in cake php.
> I need a help on the pagination . Actually iam trying to make a search with
> the compan
Check whether you have mad an debug or echo statement in your code
On Tue, Jul 21, 2009 at 1:32 AM, Dave Maharaj :: WidePixels.com <
d...@widepixels.com> wrote:
> Ok,
>
> thanks for the tip. Will check it out.
>
> Dave
>
> --
> *From:* Pablo Viojo [mailto:pvi...@gmai
Hi bino dev,
since you are using a searches controller, and you are using a line like
this
$data = $this->Search->findAll($sql , NULL, $order, $limit, $page);
you need to create a Search model.(with searches table)
Actually it is not necessary to create searches controller and its view.
you n
Please mention what you are trying to achieve; we can find a better way to
do it.
Isaac
On Tue, Jul 21, 2009 at 2:49 AM, Marcelo Andrade wrote:
>
> On Mon, Jul 20, 2009 at 2:02 AM, liyakat Ali wrote:
> > i need to call function from .ctp file.
> > And function is defined in App Controller.
> >
Hi Broom,
In our case it was the custom PHP installation on that server, there
were a number of bugs in php 5.2.0 and below preg_replace function
which caused this error. We did not have the ability to install a
later version of PHP so had to fix the inflector::underscore()
function in order for
On Mon, Jul 20, 2009 at 2:02 AM, liyakat Ali wrote:
> i need to call function from .ctp file.
> And function is defined in App Controller.
> is it possible.
As Pixelastic and Rob both said, if you have to call
some method in your view, this method is best suited
to be placed in a helper and not i
Hi,
Please help me.
Friends i need to create one search page, its searching with company , first
name, lastname, email
i created the view , controller for the functionality. Do i need to create
any model for it. Iam getting the error if there is no model in it.If i need
to create the model , what
Ty so much brian.You have helped me a lot since i started to bake.You rock!
2009/7/16 brian
>
> You should get the value from $this->data['Destination']['place']
>
> On Thu, Jul 16, 2009 at 5:09 AM, Paulos23 wrote:
> >
> > Hi people,
> > i am facing a problem with my app.In particular i use http
Yes I try it. Because model category don't know model user i modify it
to:
this->Comment->Article->Category->find(
'all',
array(
'conditions' => array(
'Category.public' => 1
),
'contain' => array(
Ok,
thanks for the tip. Will check it out.
Dave
_
From: Pablo Viojo [mailto:pvi...@gmail.com]
Sent: July-20-09 5:07 PM
To: cake-php@googlegroups.com
Subject: Re: Cannot modify header information
Now what?
Try looking at /cake/basics.php:108 ... I found it belongs to function
debu
Now what?
Try looking at /cake/basics.php:108 ... I found it belongs to function
debug(), so maybe you're using debug(...) previously?
Take a look at your code.
Saludos,
Pablo Viojo
pvi...@gmail.com
http://pviojo.net
(#340 y creciendo!)
--
Yes.
Cannot modify header information - headers already sent by (output started
at /cake/basics.php:108) [CORE/cake/libs/controller/controller.php, line
640]
Now what?
From: Pablo Viojo [mailto:pvi...@gmail.com]
Sent: July-20-09 4:39 PM
To: cake-php@goog
Normally that error comes with something like:
Warning (2): Cannot modify header information - headers already sent by
(output started at file:line)
Regards,
Pablo Viojo
pvi...@gmail.com
http://pviojo.net
(#340 y creciendo!)
Ayudar nos
You should have the login() & logout() methods in UsersController. See here:
http://book.cakephp.org/view/172/Authentication
http://www.webdevelopment2.com/cakephp-auth-component-tutorial-1/
http://www.webdevelopment2.com/cakephp-auth-component-tutorial-2/
On Mon, Jul 20, 2009 at 3:19 AM, Dhilee
I have debug = 2 and I get
Cannot modify header information
turn debug to 0 and it works the way i want. Doing a redirect after login to
redirect a user to appropriate area.
No white space after closing ?>
$this->Auth->autoRedirect = false;
Ideas why this may be happeining?
Dave
--~--~-
Thanks for this; I think it could be useful to me. I forget that
there's a contain() method and this looks like a very good use of it.
On Mon, Jul 20, 2009 at 12:16 PM, MikeBates wrote:
>
>
> I figured this out, in case anyone else is wondering how to do this, the
> children call has some extra o
It's probably possible, but doing so would break the MVC conventions
that CakePHP is built around. Perhaps re-assess how you are solving
the problem and attempt to find a solution that follows MVC guidelines.
--~--~-~--~~~---~--~~
You received this message because y
Make it public and use $this->Country->values; or create a public
method to return it:
public function getTheValues() { return $this->values; }
On Mon, Jul 20, 2009 at 6:15 AM, Pradheep Ayyanar wrote:
> HI
>
> i have a class named Country which is a component and it has a variable
> named $valu
have you (or anyone else) figured this out?
On Jun 15, 2:26 am, kdubya wrote:
> I have recently switched from a plain text development style to using
> NetBeans 6.5. I figured I might like some of the niceties of a real
> IDE (I have used them before) but my main motivation was to get
> debuggin
If you have to call a controller method from a view, you're (very)
probably doing it wrong.
Can't you just pass the result of your function to the view using
$this->set() in your controller's action ?
On Jul 20, 7:02 am, liyakat Ali wrote:
> i need to call function from .ctp file.
>
> And funct
There's nothing in that query specifying that the Category should be
public. Anyway, did you try the statement I posted? If you need User
as well, change to:
$this->Comment->Article->Category->find(
'all',
'array(
'conditions' => array(
'Categor
I've never had problems with this but there's lots of info online:
http://www.google.com/search?source=ig&hl=en&rlz=1G1GGLQ_ENUS271&=&q=cakephp+change+password&aq=f&oq=&aqi=g2
On Mon, Jul 20, 2009 at 7:10 AM, Pascal Messana wrote:
>
> Hi!
>
> I am trying to make a page where users can change the
I am trying to customise my error views, and have copied the .ctp files from
the cake folder to my app/views/errors folder. But the .ctp files in
cake/lib/views/errors/ are still being used.
I don't want to delete (or change) anything in the cake folder, so how can I
get cake to use my errors vi
Hi Piotr,
Excellent that is just what i needed to know thank you. The only
thing that bothers me about it slightly is when i make my own
components public i will also need to include the utilities and
instructions on how to install them but thats only a slight pain
really.
Cheers, Q
--~--~-
I figured this out, in case anyone else is wondering how to do this, the
children call has some extra options:
function children(&$Model, $id = null, $direct = false, $fields = null,
$order = null, $limit = null, $page = 1, $recursive = null)
so I changed my code to this:
$Category->contain( 'Pr
It seems that I was a bit to quick in posting here. I just came across
Matt Curry's LazyLoader plugin., whicht might very well be the thing
I'm looking for :)
- Nejra
On Jul 20, 5:13 pm, Nejra wrote:
> Hi,
>
> I'm doing some profiling on a prototype that uses some extensive
> associations (the
Hi,
I'm doing some profiling on a prototype that uses some extensive
associations (the largest has 11 first level associations of different
kinds, which could become more).
When loading a model, Cake also loads all the associated models.
Normally this doesn't take too much time, but now it's the
HI
i have a class named Country which is a component and it has a variable
named $values which is an array.
class Country extends Enum {
protected $values = Array('', 'United States');
}
i have to get these array values in the controller. how to i access the
array?
--
Regards
Pradheep Ayyan
Mini updates at http://www.the-di-lab.com/?page_id=47.
On Jun 23, 9:25 pm, thedilab wrote:
> Thank you very much for your support.
>
> On Jun 23, 6:26 pm, harmonica wrote:
>
> > I think that it looks very good. I like this project.
> > And the free time I also participated.
>
> > Good Luck!
--
Hi
i have a component which is basically an enum which has the list of
countries
class Country extends Enum {
protected $values = Array(
'United States',
)}
i have a form which should load the country list and set the selected
country list
can anyone let me help in getting this solved
Pra
Thanks for posting the solution.
Well I've got the same problem! But it looks like you have the fix.
However I can't quite get my head around it because in your example
you refer to $category in
$category["CandidateItem"]["CandidateItem"][$count] = this->Category-
>CandidateItem->getLastInsertI
i need to call function from .ctp file.
And function is defined in App Controller.
is it possible.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to cake-php@googl
$form->create('User', array('action' => 'login'))
2009/7/20 Dhileepen Chakravarthy
> Thank you for your reply.
> But its not working.I dnt know where i did a mistake.
>
> I am using two tables one is posts and users.
>
> Login i use *'users' *table. inside i am using *'posts'* table for
> displa
h() is cake's wrapper for htmlspecialchars()
http://book.cakephp.org/view/121/Global-Functions#h-703
2009/7/20 Bs
>
> Hi,
>
> thanks for your answer. What do you mean by "h() function"?
>
>
>
> On 17 Jul., 19:13, "Dr. Loboto" wrote:
> > I personally validate data before save and output it on pa
Your verbiage describes clearly what structure you need to create.
I have a very similar structure with a few of my sites, because I
support more than one authentication via www.rpxnow.com which is a
service to support OpenID so my users can associate their account with
multiple login services (G
Any possible ideas anyone?
On Jul 17, 10:17 am, blake wrote:
> Hello,
>
> For one of my models, I have this (among other) validation
> requirements:
>
> 'fee' => array(
> 'gt_0' => array(
> 'rule' => array('comparison', '>=', 0),
> 'message' => 'Please e
Yep.. looks like your missing a dot there(before the kpi_colour_id') which
Piotr pointed out
2009/7/20 Piotr Kilczuk
>
> Hello,
>
> > echo $form->input('ChartsKpis.' . $kpi['Kpi']['id'] .
> > 'kpi_colour_id');
> >
> > However the resulting input has the format:
> >
> >
> >
> > It seems to have
Hello,
> echo $form->input('ChartsKpis.' . $kpi['Kpi']['id'] .
> 'kpi_colour_id');
>
> However the resulting input has the format:
>
>
>
> It seems to have got the id correct; but the name attribute hasn't
> been created in the same way as the documentation states.
>
> So which is right, the doc
Thanks a lot, grigri.
Your trick worked perfectly and I didn't know I can access the
parameters of a view in the same way I access the parameters of a
controller.
What a disaster!
Regards.
On 20 jul, 14:19, grigri wrote:
> How about
>
> $modelName = key($this->params['paging']);
>
> That shou
How about
$modelName = key($this->params['paging']);
That should do the trick.
hth
grigri
On Jul 20, 11:47 am, jordicakephp wrote:
> Hi again, my dear baker friends.
>
> Until now, when I've written this in a controller:
>
> $paginatedQuery = $this->paginate($this->modelClass);
>
> I've coded
Hi
I've a question (or five) about HABTM relationships in Cake
1.2.3.8166.
I had a very simple setup with a HABTM relationship:
A KPI can be displayed on many charts
A Chart can display many KPIs
So I've a HABTM relationship and a join table called charts_kpis. This
all worked very well until
Marcelo,
The $uses property in controller solved my problem !!!
Thanks for the help !!
Valeu Cara !
Thiago Elias.
2009/7/19 Marcelo Andrade
>
> On Fri, Jul 17, 2009 at 5:13 PM, Thiago Elias
> wrote:
> >
> > I'm new in cake, and I've been experiencing some problems with composed
> >
Thanks Issac,
This type of url only i tried in google :)
Regards,
Dhileep
--~--~-~--~~~---~--~~
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 unsubscrib
You're right.
I was wondering if I should add an ID key (maybe tables without ID
column are not supported by schemas) or submit a ticket (tag_id is not
declared as a key in mysql, so the schema generator should not write
it!)
On 20 juil, 03:11, brian wrote:
> There should be no Primary Key in t
Hi dhileep,
Here is where i learned authentication in cakephp
http://www.studiocanaria.com/articles/cakephp_auth_component_users_groups_permissions_revisited
It also tells how to create groups & permissions.
Thanks,
Isaac
On Mon, Jul 20, 2009 at 4:40 PM, Dhileepen Chakravarthy <
dhileepe
Hi!
I am trying to make a page where users can change their password.
The user has to insert the actual password and the new password in
form inputs, then submit the form.
Then, I want to compare the submitted password and the real password
(the one in the database).
I try to get the real passwo
Hi Jeff,
http://bakery.cakephp.org/articles/view/simple-form-authentication-in-1-2-x-x
I tried with this sample program but its not giving error or nothing. Simply
it gives blank page.
Other's are complecated wa of coding with Auth component and they wont give
complete.
Anyway i ll try to lear
Hi Dhileep,
Goto github or googlecode search for cakephp, you will find some opensource
cakephp applications,
check for the login authentication system there. it's easy.
Regards,
Isaac
On Mon, Jul 20, 2009 at 4:29 PM, jeff wrote:
> pha ..
>
> u never will learn,if u dont
Hi
I'm trying to use the model naming conventions, as documented in the
Book for version 1.2, to create multiple select elements for the same
fields in the same form. The why for this I'll put in another thread;
but this question is just about the naming conventions.
In the Book it states:
If y
pha ..
u never will learn,if u dont try to do it by urself.after reading
the docs
its a simple process
dont expect everthing to be done by others
..
this time am not helping you...
find it urself.
hint use this link
http://book.cak
Hi again, my dear baker friends.
Until now, when I've written this in a controller:
$paginatedQuery = $this->paginate($this->modelClass);
I've coded this in a view to access the information that it returns
(inside a foreach loop, of course):
$row['ModelName']['user_login']
That is, hard-c
Hi Everybody
Please refer good url for simple cakePHP login form
If any body wrote a code is very much appreciated.
Regards,
Dhileep
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this g
I know about that but I wonder if it can be done otherwise. The Cake
way with find method is more beautiful :-)
On 20 čnc, 12:26, jeff wrote:
> use
>
> $this->modelname->query(" SQL STAEMENT HERE ");
>
> OR
>
> use this link for further study
>
> http://book.cakephp.org/view/456/query
>
>
>
> On
use
$this->modelname->query(" SQL STAEMENT HERE ");
OR
use this link for further study
http://book.cakephp.org/view/456/query
On Mon, Jul 20, 2009 at 3:53 PM, eXistent wrote:
>
> I need it for report of new comments, but only from articles inside
> public category.
> In SQL way it looks lik
oh! that was too easy!
Thanks for this
--~--~-~--~~~---~--~~
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
Thanks a lot for your reply! :-)
I was writing:
class Forum extends AppController {
}
Instead of:
class ForumController extends AppController {
}
That's why I got the fatal error message...
On 20 jul, 12:10, majna wrote:
> App::import('Controller','Forum');
> class ForumCarController ext
I need it for report of new comments, but only from articles inside
public category.
In SQL way it looks like this:
SELECT * FROM
comments AS comment
LEFT JOIN articles AS article ON comment.article_id=article.id
LEFT JOIN categories AS category ON article.category_id=category.id
LEFT JOIN users
Hi,
thanks for your answer. What do you mean by "h() function"?
On 17 Jul., 19:13, "Dr. Loboto" wrote:
> I personally validate data before save and output it on pages through h
> () function. That's all. No modification of user data. With such
> approach I do not see use forSanitize::clean()
App::import('Controller','Forum');
class ForumCarController extends ForumController {
}
/app/controllers/forum_car_controller.php
On Jul 20, 11:26 am, jordicakephp wrote:
> Hi friends, from Barcelona.
>
> I've abstracted the functionality of a generic forum in the class
> ForumContoller beca
Hi friends, from Barcelona.
I've abstracted the functionality of a generic forum in the class
ForumContoller because I'm trying to build a hierarchy of controllers.
I do this in the next manner:
I program ForumController, the most generic controller, in /app/
controllers. Then, I extend this con
Hello,
> I find myself repeating myself with some simple code snippets i have
> functions for simple tasks that i tend to repeat often (like finding a
> unique filename from a directory and grabbing a files extension etc
> etc), I put these functions inside components that i have written as
> wel
Thank you for your reply.
But its not working.I dnt know where i did a mistake.
I am using two tables one is posts and users.
Login i use *'users' *table. inside i am using *'posts'* table for
displaying blog posts.
index.ctp for login screen with form fields. ( $form->create('Post',
array('acti
69 matches
Mail list logo