Hi..I am always facing the problem in setting up my document root,
whenever I tried to create a new project in Cake. I have got solved
the problem many times, automatically, after few times struggle..but i
could not catch for which modifications, that i have made in the
application that it make wo
hi,this is reeta.I m new to cakephp.can anyone tell me that how can i
set multiple action
using javascript on more than one buttion.Suppose I hv 2 submit
buttons,first one is save and another one having name goback.I want to
give action on these buttons, and they are on a single form.If anybody
kn
If you are using 1.2 then its because of validates() call you are issuing
(sending a parameter to validates() is deprecated). Even though, and whether
you are using 1.1 or 1.2, change:
if ( $this->User->validates($this->data) ) {
to:
if ( $this->User->create($this->data) && $this->User->validat
Alright, I got it to work, when I removed the line of code from my
default layout, $scripts_for_layout.
Can someone please tell me what $scripts_for_layout is used for? Thank
you.
On Jul 1, 7:51 pm, Geoff Ford <[EMAIL PROTECTED]> wrote:
> All javascript files need to be placed in app/webroot/js
I found out the problem.
I am new to web programming and didn't know the error window was for
javascript in IE, thought I had copied and pasted correctly.
So now I know. Everything is working just fine.
Thanks,
Jay
--~--~-~--~~~---~--~~
You received this message
Hey,
I'm using Cake 1.2 with phpgacl for CakePHP 1.0.2b and I've been
having a problem adding permissions. I have fixed a lot of the 1.1 to
1.2 conversion errors, but it's obviously not liking something in
either the plugin or the vendor lib itself and is failing to update
the database, so it thr
beforeValidate() is being invoked through the normal flow, i.e. I am
not calling it arbitrarily. Here's my Controller code. Thanks.
function register() {
if ( !empty($this->data) ) {
if ( $this->User->validates($this->data) ) {
Geoff,
Yes, am I aware of this, and this is what I have done, not only have I
included the javascript helpers in my controllers, I also included
them into my AppController so my layout would have access to the
javascript helper when calling $this->javascript('file') in the header
of my default la
Sounds to me like a javascript error. Havethe downloaded js files
actually got the right code in them, or are they blank or 404 error
messages?
Some actual code might help as well.
Geoff
--
http://lemoncake.wordpress.com
On Jul 2, 10:45 am, minglee <[EMAIL PROTECTED]> wrote:
> Thanks, francky0
All javascript files need to be placed in app/webroot/js and you need
to include the javascript helper.
http://manual.cakephp.org/chapter/helpers about 3/4 down is the
javascript helper documentation
Geoff
--
http://lemoncake.wordpress.com
On Jul 2, 10:28 am, Jim Newfer <[EMAIL PROTECTED]> wrot
I have been using jquery for about a month now, and I love it to say
that least. Although, I cannot seem to figure out the best way to
incorporate it into my cakephp project, or even to incorporate it at
all!
When I used jquery before, I just loaded the jquery.js library in the
header, and then w
Thanks, francky061.
Sorry, that's a mistake in my message. I did use $javascript->('.js')
to load .js files, but it doesn't work. And I checked the generated
html page source, there is .js file included in the header, but when I
call the js functions, 'not difined' errors appear. What is more
stra
$this->data[$this->name] will be set with that model's data in the
beforeValidate.
If this is not happening for you, there is some other error in your
application. How is beforeValidate being called - just through Model-
>save()? How are you setting the data to be saved, through Model-
>set($da
Except that what you write in a controller action is only one part of
what Cake does with a request, and calling exit() is the quickest way
to skip all of that. Setting autoRender to false will stop the view
from being rendered, but I'm not sure what else would need to be done
to end the whole re
I was hoping someone could explain why $this->data['ModelName'] or
$this->data is empty when I try to use it in the beforeValidate()
callback function. Isn't the point of this function so I can perform
additional validation on the form data? Thanks.
--~--~-~--~~~---~-
To use an Alias with CakePHP, you need to add
RewriteBase /your_alias_name
to the app/webroot/.htaccess file (right after the RewriteEngine On
line). And you need to have
define ('WEBROOT_DIR', 'your_alias_name');
in your app/webroot/index.php
--~--~-~--~~~---~--~---
The reason for the hidden field is so that you always get something on
form submission. Without the hidden field, if a user does not select
the checkbox you will not get anything within the data array at all.
With the hidden form field you will get it there.
Geoff
--
http://lemoncake.wordpress.c
Nop it wasnt a mod_rewrite problem. Maybe stupid but it requires the
database table to be made in order to let the linking work. Which I
don't really get since db has nothing to do with how path's are made.
On 1 jul, 18:54, francky06l <[EMAIL PROTECTED]> wrote:
> mod-rewrite problem I guess. Make
A bit off topic, but I was taught to always structure your code so
that execution terminates by falling out the bottom of you routines
(i.e. no early exit points). For one, it makes more logical sense in
execution flow and is typically easier to maintain. So if you have any
clean-up code at the en
Umm no i did not read cause it was posted just before i was writing my
message :) but why does it create the hidden field?
On Jul 1, 8:23 pm, Walker Hamilton <[EMAIL PROTECTED]> wrote:
> everything for form will be an option on input from now on (for the
> most part.)
>
> why would it come back..
everything for form will be an option on input from now on (for the
most part.)
why would it come back
most of those options are just wrappers. do you know how to read php
code?
do you know how to read the english language? Did you not read what I
wrote regarding the API?
--~--~-~
Ok adding it as option works.. so i suppose checkbox is not comming
back in 1.2 as the htmlhelpers?
But it still creates a hidden form also? Is there any reason for this
and is there a way to turn it off..
input('publish', array('type' => 'checkbox', 'value'
=> 'yes')); ?>
makes:
Publish
Mech7: use form->input('published', array('type'=>'checkbox'));
As for the hidden hidden input, as of the currently live API docs
here: api.cakephp.org/1.2, there is no way to turn off the hidden
field.
--~--~-~--~~~---~--~~
You received this message because you
Umm look where? i have looked in the API and code but it is not
there..
http://api.cakephp.org/1.2/class_form_helper.html
On Jul 1, 5:27 pm, gwoo <[EMAIL PROTECTED]> wrote:
> did you look?
--~--~-~--~~~---~--~~
You received this message because you are subscribe
Hi everyone,
I've tried to make CakePHP working using Alias configuration, but
the only thing works its index.php ( /app/webroot/index.php).
The controller give me 404 error using /alias/posts/index, but
using /alias/?url=posts works.
I think its a mod_rewrite issue.
I have updat
On 7/1/07, Andreas <[EMAIL PROTECTED]> wrote:
>
>
> I'm using CakePHP 1.1 with phpGACL. I've only tried out Cake for the
> last days and now I've finally got an sign up form to work as
> expected. But how do I update the corresponding phpGACL tables when a
> new user signs up?
[..snip..]
phpGACL
phpGACL comes with an extensive API. Look at the functions available in the
PhpGacl component. To save a user, for example, you would do:
$this->PhpGacl->saveUser($userId, $userName);
For example if you just created a User with ID #15, then you can do:
$this->PhpGacl->saveUser(15, 'User #15');
mod-rewrite problem I guess. Make a search in this group on
"mod_rewrite", you'll probably find the solution
On Jul 1, 12:56 pm, "[EMAIL PROTECTED]"
<[EMAIL PROTECTED]> wrote:
> Hi everyone,
>
> I just started finding my way in cakephp and I stumbled upon a little
> problem:http://www.laomusic.be
gwoo: it's http://manual.cakephp.org/chapter/view_cache I think
On 7/1/07, gwoo <[EMAIL PROTECTED]> wrote:
>
>
> http://manual.cakephp.org/chapters/caching
>
>
> >
>
--
(the old fart) the advice is free, the lack of crankiness will cost you
- its a fine line between a real question and an idi
With AD7six suggestion I found out some extra space on bootstrap that
cause the error log and now it goes back to the original problem of
just having a blank page.
I really love to be able to get to the bottom of this puzzle.
Thanks
On Jun 29, 10:15 pm, "chanh.ong" <[EMAIL PROTECTED]> wrote:
>
In the views, the way you would call the helper should $javascript-
>() NOT $this->javascript
Hope this help
On Jul 1, 12:17 pm, minglee <[EMAIL PROTECTED]> wrote:
> I am new to phpCake. My phpCake routing is set to 'development'. And I
> put all .js files into ./cake/app/webroot/js/, and set h
did you look?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more
http://manual.cakephp.org/chapters/caching
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email
please search for things like this. Configure::write('debug', 0);
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from
Never mind, I figured it out.
On Jul 1, 3:03 pm, Grant Cox <[EMAIL PROTECTED]> wrote:
> You want to use $this->redirect("/users/startpage"), not requestAction.
If I use $this->redirect(), the whole view will be rendered.
The following function (placed in app_controller.php) would work
*nearly*
I am new to phpCake. My phpCake routing is set to 'development'. And I
put all .js files into ./cake/app/webroot/js/, and set helper, called
'$this->javascript', ect.., did everything as told in the manual, but
it does not work. I've tried my other none-cake applications on the
same server, they a
Hi!
I'll try to be as descriptive as I can.
I have the following problem that apears when I drag the comment on
the trash div more than once in IE7 I get a javascript error that
looks like this:
Line: 3082
Char: 7
Error: Unspecified error
Code: 0
So, if I refresh the page, I can drag the first c
Hi everyone,
I just started finding my way in cakephp and I stumbled upon a little
problem:
http://www.laomusic.be/cake/ (dont mind "Missing Database Table"
errors, thats not the problem).
The links work perfectly on this page, its the root for the whole
application(which uses the pagescontrolle
Hello,
I am using 1.15 and am trying to call a function from a .js file but
am receiving an Object expected error from IE.
my codes are as following:
echo $javascript->link('compose');
input('Message/allrecipients',
array('type'=>'text',
'size'=>'8
I have a problem with drag and drop in IE7.
I have a dragged div and a dropRemote div, both inside the same view.
In IE7 the most strangest thing happens. I am able to drag and drop an
element, but when I try to drag the second one an error occurs. This
is the notification from IE7:
Line: 3082
I made a mistake in the above post. Actually the code is:
$this->setAction('index');
$this->render('index', 'ajax');
Sorry for that
On Jul 1, 11:04 am, citrus <[EMAIL PROTECTED]> wrote:
> Hello,
>
> Currently I'm using Cake 1.2 and I have a small problem. Basically I
> want to redirect the user
I'm using CakePHP 1.1 with phpGACL. I've only tried out Cake for the
last days and now I've finally got an sign up form to work as
expected. But how do I update the corresponding phpGACL tables when a
new user signs up?
My users table looks like:
CREATE TABLE `users` (
`id` int(10) unsigned NOT
UnbindModel does also not seem to work :(
// Remove HABTM on tags and categories
$this->Article->unbindModel(array('hasAndBelongsToMany' =>
array('Tag', 'Category')));
// Find all articles
$this->set('articles', $this->paginate('Ar
Why the order doesn't work if I have in my view
sort('Nombre', 'nombre',
array('model'=>'Producto')) ?>
sort('Tipo', 'nombre', array('model'=>'Tipo'))
And in my controller
$productos = $this->paginate('Producto');
$this->set('productos', $productos );
Tipo hasMany Producto
How can I make
On 7/1/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
>
> I use typical function:
[..snip..]
>
> Interesting: one host, 4 copy of code (different folders, DB). But in
> one copy does'nt work validation.
> When I type: /posts/add I see message: "Post was added" and get empty
> record in table
I use typical function:
function add()
{
if (empty($this->params['data']))
{
$this->render();
}
else
{
if ($this->Post->save($this->params['data']))
My Problem is that the php json_decode() does not work when remotely
calling a cake controller method which just returns a json string.
The problem seems to be in the last lines of the webroot/index.php,
which append the execution time to every output:
if (Configure::read() > 0) {
You want to use $this->redirect("/users/startpage"), not requestAction.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe
for information I use curl to call all action
On 18 juin, 11:05, wluigi <[EMAIL PROTECTED]> wrote:
> no one know how to handle this ?
>
> On 15 juin, 14:31, wluigi <[EMAIL PROTECTED]> wrote:
>
> > I want to do this in only 1 call
>
> > On 15 juin, 14:27, wluigi <[EMAIL PROTECTED]> wrote:
>
> > >
49 matches
Mail list logo