I'm trying to integrate a vendor class into my app, and the vendor
class needs the link resource of MySQL connection to operate the
database. Is it possible to get the link resource of MySQL connection?
I have googled awhile but I have not found anything helpful. Anyone
knows?
--~--~-~--~
more: I put this immediately inside add()
die(debug($this->data));
Debugger::dump($this->data);
This dumps the data--intact--onto the page. When I comment out the
die() line, I get:
array(
"Record" => array(),
"Discipline" => array()
)
I can't see how this possibly could be a P
[update] - problem is with the 'AND NOT' syntax it seems - looking
around for alternative method now, if anybody can think of alternative
syntax that is more globaly compatible with later versions of mysql
then that would be great. this looks like its going to require
modification to the core of
More on this: I put this in the controller:
function beforeFilter()
{
die(debug($this->data));
}
So, when I submitted the form, all the data was right where it should
be. (Obviously, I commented it to get the form to display). So, its
disappearing act comes somewhere between beforeFilter() a
Thanks, that's where I'll put it.
On Jan 11, 11:14 pm, "Amit Badkas" wrote:
> I think, AppController::beforeFilter() is proper place to put your timezone
> setting code
>
> 2009/1/12, fly2279 :
>
>
>
> > I would like to set the timezone based on a value stored in a user
> > profile. The function
Hello,
using Cake 1.2 release, counterCache variable seems to not working.
Counter field just is not updating.
I have model Topic:
var $belongsTo = array(
'Project' => array('className' => 'Project',
'foreignKey' => 'project_id',
'conditions' => '',
'fields' => '',
Hi,
I have a problem with the tree behaviour:
Warning (512): SQL Error: 1064: You have an error in your SQL syntax;
check the manual that corresponds to your MySQL server version for the
right syntax to use near 'AND NOT (`Category`.`id` = 3)' at line 1
[COREcake/libs/model/datasources/dbo_sourc
It's user-specific, so store it in the user's session.
On Mon, Jan 12, 2009 at 12:14 AM, Amit Badkas wrote:
> I think, AppController::beforeFilter() is proper place to put your timezone
> setting code
>
> 2009/1/12, fly2279 :
>>
>> I would like to set the timezone based on a value stored in a us
If you look at the code on line number specified in error message then you
may find problem's cause. You can also try by removing end PHP tag
2009/1/10, mona :
>
>
> I m getting this warning when i m adding a
> record
> Cannot modify header information - headers already sent by (output
> started a
Try adding an isAuthorized method to your AppController:
/**
* Function to return whether you are authorized or not.
*
* @return
*/
function isAuthorized() {
return true;
}
On Jan 9, 7:31 am, volka wrote:
> Hi there,
> i have
> $this->Auth->allow(array('
I think, AppController::beforeFilter() is proper place to put your timezone
setting code
2009/1/12, fly2279 :
>
>
> I would like to set the timezone based on a value stored in a user
> profile. The function will get the timezone value based on which user
> is logged in and use php's date_default_t
As long as everything is set up properly for your app, you can just cd
to the app directory and run the following from a command prompt:
cake schema run create DbAcl
If you don't have Cake in your path, you may need to change it to be
something like:
/console/cake schema run create DbAcl
I'm g
I think the idea is that they're only required for this one action and
so putting them all in $uses would entail far too much overhead.
On Mon, Jan 12, 2009 at 12:03 AM, Webweave wrote:
>
> I'm confused by your question, why wouldn't you just add the model to
> your $uses: http://book.cakephp.or
I'm confused by your question, why wouldn't you just add the model to
your $uses: http://book.cakephp.org/view/53/components-helpers-and-uses
That's the standard way of including a model in your controller.
On Jan 10, 10:56 pm, Miles J wrote:
> Der... I could call $this->loadModel().
--~--~
I'm trying to debug a problem with one of my controllers where
$this->data is (almost) empty (more on that in a sec) and so tossed a
bunch of Debugger::log statements in the action. When I checked the
debug.log I found that the entries are being repeated.
The action starts out like this. I put se
I would like to set the timezone based on a value stored in a user
profile. The function will get the timezone value based on which user
is logged in and use php's date_default_timezone_set() function to set
the script timezone. The whole application should be using the
timezone that is set, not j
It seems as though AppController is not included when there is an
error. Is there any way to change this behavior? Most notably, I need
the Auth component to be included.
I'm trying to add my own AppError class, but it needs to extend
ErrorHandler, so I don't know how to get it to include AppCont
Routing 'pages/christmas_specials' should work.
On Jan 11, 4:00 pm, the_woodsman wrote:
> Hi Bakers,
>
> I need to do a permanent redirect from one of my static pages, for
> example /pages/christmas_specials
>
> Normally I'd do this in my controller, but I can't because there's no
> christmas_sp
Thanks, Nate. That works. I'd actually gotten it to work with:
Router::connect('/ASK',
array(
'controller' => 'pages',
'action' => 'display',
'ask/index'
)
);
... and this in my PagesController:
public function display($path = null
Just a question: are you testing with IE7?
There have been a couple of posts recently where people were having
problems with IE7 and Auth (you can search the group and find the
posts).
My app_controller has the following setup in the beforeFilter:
/*
* Set up the Auth component so that we get
First, you really don't want to read the session from the view, it
should be done from the controller.
Second, the error you are getting sounds like the value wasn't set in
the session, so either you are referencing what you set incorrectly,
or you need to query for it.
The last inserted ID will
You should NOT allow the login action.
--~--~-~--~~~---~--~~
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
cak
I am 99.9% sure that mod_rewrite is working. I haven't ever had
trouble with it before and would it work when allow all was on if
htaccess wasn't working. It is only the users/login that is not
mapped or mapping correctly.
Chad
On Sun, Jan 11, 2009 at 3:19 PM, Webweave wrote:
>
> Sounds like
$this->Auth->allowedActions = array('*');
Is how I allow all.
Chad
On Sun, Jan 11, 2009 at 12:44 PM, Pascal Messana wrote:
>
> Hi,
>
> When you say " If I tell Auth to allow all ", why do you do exactly
> (paste the code) ? Do you use the * or do you specify each action ?
>
> On 11 jan, 17:17,
Thanks alot buddy, thats definatly tightened things up but im still
getting the odd error. Might just be me. Thanks for your help matey!
On Jan 8, 8:16 pm, "Mark (Germany)"
wrote:
> always make sure that you check on or cast to whatever you need,
> especially reading from session!
> especially a
Something like this?
function beforeFilter() {
if ($this->params['action'] == 'christmas_specials') {
$this->redirect();
}
}
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, sen
Hi Bakers,
I need to do a permanent redirect from one of my static pages, for
example /pages/christmas_specials
Normally I'd do this in my controller, but I can't because there's no
christmas_specials action in the pages controller.
I tried to keep the .ctp file and redirect at the top of it, b
The 'pass' key only applies to parameters that actually come out of
the URL. Try this one:
Router::connect('/ASK',
array(
'controller' => 'pages',
'action' => 'display',
'ask', 'index'
)
);
On Jan 10, 6:32 pm, brian wrote:
> A section of my site is
I seemed to have gotten it working, not sure what I did though -_-
On Jan 11, 1:59 pm, nurvzy wrote:
> Either SQL statement works for me directly typing it into an SQL
> query, Don't know why it's not working for you, what database are you
> using and what version? You might need to submit a bu
Either SQL statement works for me directly typing it into an SQL
query, Don't know why it's not working for you, what database are you
using and what version? You might need to submit a bug report.
On Jan 9, 3:01 pm, Miles J wrote:
> My id is in the table and everything is correct, the problem
No I cant use saveAll since I use some of the stuff from one of the
save as input to another save. So a lot of funky stuff going on.
saveAll is not an option :(
On Jan 9, 6:48 pm, SiscoJ WEB wrote:
> Can't u use saveAll() ?
>
> Transactions are default when using this method.
>
> best regards...
Sounds like you may have a problem with your .htaccess or routing.
Are you using the default .htaccess files ?
Is mod_rewrite enabled ?
On Jan 10, 5:35 pm, "Chad Casselman" wrote:
> I have been developing my first cake app locally for the past few
> days. I uploaded the files to my dedicated
Hello everyone,
I need to write something to collect payment for a website via mobile
phones.
I was just wondering if any of you knew of any good companies and also
if there is a component to do the job already out there.
Any help helps
many thanks in advance
Marcus Silva
--~--~-~--~-
Thanks for the help but that didn't seem to work. I ended up just
hacking it by writing a custom function:
sortKey() == $sort_field){
return ' class="' . $paginator->sortDir() . '"';
}
}
?>
>sort('Time of Trade', 'Trade.time_of_trade'); ?>
>sort('
Hi,
When you say " If I tell Auth to allow all ", why do you do exactly
(paste the code) ? Do you use the * or do you specify each action ?
On 11 jan, 17:17, TheChad7 wrote:
> Am I the only one that has had this issue?
>
> Any suggestions?
>
> Chad
>
> On Jan 10, 8:35 pm, "Chad Casselman" wrot
I have two dropdown boxes if value of one dropdown changes then
according to that value of second dropdown changes i doing that using
ajax my problem is that in my edit view only one dropdown box is
displaying value from database not second one it is displaying blank
my controller code is as follo
Am I the only one that has had this issue?
Any suggestions?
Chad
On Jan 10, 8:35 pm, "Chad Casselman" wrote:
> I have been developing my first cake app locally for the past few
> days. I uploaded the files to my dedicated server as following:
>
> .htaccess
> index.php
> /app
> /cake
> /vendor
Hey folks,
I'm begining with CakePHP and I'm thinking that it's a awesome
framework and I'm trying to imagine ways to do most any web
application with it.
But, as beginners are just beginners, I'm having some problems with
it.
This time, I'm trying to upload an image with a form. I was googling
Have you looked at the book? http://book.cakephp.org/view/349/Methods
Best way is to read the class yourself and understand what it does.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to th
39 matches
Mail list logo