A solution, maybe not best, would be to remove the userScope and set
autoRedirect to false.
Once the user is logged, you can then check the active flag, if it's
not activated, you can logout the user and set a different message
before redirect.
On Jul 8, 4:12 am, DanielMedia [EMAIL PROTECTED]
ok, thanks for the explanaition and the hint :)
On 7 juil, 08:47, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
Hey!
The rules are indeed executed in order, but only the last validation
rule that didn't pass will be shown. If you want Cake to stop
validating if a condition isn't met, you can
Jonathan // Im sure that the directory is my local cakephp. But the
wierd thing is that with http://localhost/ i get a directory listing
and the index.php file is in that directory. That should point to
mod_rewrite not being enabled but when i fire up phpinfo it states
that mod_rewrite is one of
I try to build my site. I'm a newbie...
I used 1.1..version of cakephp..
I want to use prototype and scriptaculous effects.. more or less like
frontpage you have seen in CAKEPHP. It can be navigate by next or prev
buttons or by clicking the tab..
can anyone help me please
thanks in
Hi regz,
The frontpage of cakephp.org uses jquery javascript behaviours. You
can achieve the same results using prototype though.
The dynamic tabs are all javascript and have very little (if anything)
to do with cakephp. The helpers for javascript (and ajax) are a good
help but they have their
Hi there Stefano,
On the whole I would suggest you upgrade to CakePHP 1.2, currently at
rc2.
If you are coming back to a project you will benefit greatly from
doing the migration to 1.2 now. Most of the people here now develop on
1.2 and it is stable enough and have many many improvements over
hi,
i'm using the 1.2 rc2 version of cakephp framework.
if i use view cache with the file engine the file is correctly
generated into the tmp/cache/views folder.
i want to switch to memcache, so i've chanced my core.php:
Cache::config('default', array('engine' = 'Memcache'));
my problem is
thank you very much for the reply..
in short, it much better if im goin to build my on js library or just
an extension?
coz for now im using the prototype/scriptaculous library for now...
the problem there if im going to used jquery same time it goes out
with a problem... correct me if im wrong
The thing is: I actually want the parameter in my URL, since it is
significant to the user -- so storing it in the session is really not
an option. I'd rather not rely on sessions (and thus enabled Cookies)
for a critical part of the application anyway. (Of course, login/
logout is critical too
Overwrite url method in your app_helper.php. Here's what I've done for
keeping language in my urls:
class AppHelper extends Helper {
function url($url = null, $full = false) {
if (is_array($url)) {
$default =
Hi,
I'd want print out this html:
a class=dock-item2 href=#spanInserisci Ticket/spanimg src=/
CakePhp_Prova/img/dock/portfolio.png alt=portfolio //a
using this cakephp code on view:
echo $html-link(Inserisci Ticket . $html-image('dock/
portfolio.png',array(alt = portfolio)), #,array( class =
Martin,
thank you for your tips.
Unfortunately upgrading to 1.2 is not an option now... I can't decide
it myself...
I already had done the check you suggest, now I re-done... but
everythings looks right...
The IN part is probably not the problem. It looks ok and is basically
shorthand for
Set the last parameter of $html-link() to false to disable escaping
your link title:
http://api.cakephp.org/class_html_helper.html#71ff7f331b08318bc867a4d9057b7d9f
On Jul 8, 11:13 am, Valerio [EMAIL PROTECTED] wrote:
Hi,
I'd want print out this html:
a class=dock-item2 href=#spanInserisci
I would use in a model the function of CAKE core that translates a
condition like for example
array('Model.field'='LIKE %value%');
in the SQL's format WHERE condition
`Model`.`field` LIKE 'value'
Can somebody tell me what is this function and hoe can I use it inside
my model if it is
Ok, so I have to add the user id to every row right?
On 7 Lug, 23:43, francky06l [EMAIL PROTECTED] wrote:
This is exactly ACL. User/creator will be an ARO and the row will be
an ACO, the rest is permissions on CRUD operations.
Now if it's just to limit the user/creator to edit the record AND
It's like this:
array('Model.field LIKE' = '%'.$yourValue.'%')
On Jul 8, 12:37 pm, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
I would use in a model the function of CAKE core that translates a
condition like for example
array('Model.field'='LIKE %value%');
in the SQL's format WHERE
Ok
but what is the function to translate a condition in a piece of SQL's
query?
On 8 Lug, 12:51, dr. Hannibal Lecter [EMAIL PROTECTED] wrote:
It's like this:
array('Model.field LIKE' = '%'.$yourValue.'%')
On Jul 8, 12:37 pm, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
I would use in a
Hello everyone,
I have some strange problems with my IE 7 or 8:
My ctp Template looks like this: http://bin.cakephp.org/view/1170637606
So in the Browser it looks like this: http://pastie.org/229070
(ok, the text inside the div is different, but i think that doesn't
count)
When the request-URL
Did the .htaccess files get copied properly?
Jonathan // Im sure that the directory is my local cakephp. But the
wierd thing is that with http://localhost/ i get a directory listing
and the index.php file is in that directory. That should point to
mod_rewrite not being enabled but when i
I'm not sure I understand..? You want to get the SQL instead of
executing it via Model::find(...) ?
On Jul 8, 12:58 pm, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
Ok
but what is the function to translate a condition in a piece of SQL's
query?
On 8 Lug, 12:51, dr. Hannibal Lecter [EMAIL
On Mon, Jul 7, 2008 at 11:52 PM, Jonathan Snook
[EMAIL PROTECTED] wrote:
1) add a behaviour
2) add a field to your table
It seems to be built into CakePHP now:
http://book.cakephp.org/view/490/countercache-cache-your-count
That's cool and all, but still...which solution is better in this
I think they are. Just to be sure...there are .htaccess files in:
C:/Program Files/Apache Group/Apache2/htdocs/cakePHP (the root folder
of cakePHP). Content:
IfModule mod_rewrite.c
RewriteEngine on
RewriteRule^$ app/webroot/[L]
RewriteRule(.*) app/webroot/$1 [L]
/IfModule
On Jul 8, 11:58 am, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
Ok
but what is the function to translate a condition in a piece of SQL's
query?
Not sure why you'd want to do this, but...
$db = ConnectionManager::getDataSource($this-useDbConfig);
$conditionsString = $db-conditions(...);
It is my product Model
class product extends AppModel
{
var $name = 'Product';
var $primaryKey = 'productId';
var $validate = array(
'productName' = VALID_NOT_EMPTY,
);
var $belongsTo = array(
'Category' = array(
'className' = 'category',
I want to integrate fckeditor in one of cakephp page. How do it? where
I have to place the editor folder and how to integrate it?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
CakePHP group.
To post to this group,
On Tue, Jul 8, 2008 at 8:47 AM, kaushik [EMAIL PROTECTED] wrote:
I want to integrate fckeditor in one of cakephp page. How do it? where
I have to place the editor folder and how to integrate it?
--~--~-~--~~~---~--~~
Perhaps Google is not working for you where
That's cool and all, but still...which solution is better in this case?
I'd probably use the counterCache since it'd simplify queries and it's
handled for you.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
First, you need to change find('all', ...) to find('list', ...)
Also change the view code to:
?php echo $form-select('Product.categoryId', array('options' =
$categories)); ?
Make sure you're using the 1.2 branch of cake.
On Jul 8, 2:45 pm, kaushik [EMAIL PROTECTED] wrote:
It is my product
This is why sub-domains exist. abstract.paintersgallery.com,
impressionist.paintersgallery.com - making separate urls creates a
problem that doesn't need to exist.
On Jul 8, 5:54 am, mwcbrent [EMAIL PROTECTED] wrote:
Thanks in advance to anybody who expresses their ideas in response,
I'm sorta
Thank you biesbjerg, 100% the answer is was hoping for.
--~--~-~--~~~---~--~~
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,
Hello to everybody!
Im new to CakePhp, so my doubt is very simple. Hope you have patience
and help me.
I started create a plugin. I made all the structure and some methods.
But I dont know how to call a plugin method in the
appcontroller::beforefilter function. How do I make reference to the
You could also do something like this in your AppController:
if (env('SERVER_NAME') == 'abstractpaints.com') {
$this-layout = 'abstract';
}
Or even simplify it like,
$this-layout = str_replace('.', env(SERVER_NAME));
(although my syntax is probably a little off there)
On Tue, Jul 8, 2008
hi,
i have 2 models in HABTM relation: Users HABTM Books
the trick is that i have an extra column in the users_books table
called relation_type
this is my relation definition from my User model:
var $hasAndBelongsToMany = array(
UserBookshelf = array('className'= 'Book',
Hi,
I'm testing ACL in CakePHP 1.2. I build ACOs and AROs like this:
Aro tree:
---
[1]Users
[2]Moderators
[3]Administrators
[4]admin
[6]mod
[5]user
[7]Guests
View caching is only supported with files. You can use other engines
for the core, model, and custom caching, but view caching always needs
to create files. This is due to the way files are rendered and
included where other caching mechanisms would require different
approach. For now, we have
Hey,
A better search function for the cookbook would be nice.
It was tested for some time on the dev book and know it's live :)
plus some other goodies.
--
Marcin Domanski
http://kabturek.info
--~--~-~--~~~---~--~~
You received this message because you are
i have installed WAMP on an XP Pro server, and now cake (twice),
followed some example code in the cake docs on login scripting, but
cannot get my app to resolve, i.e., http://localhost/users
the cake default screen says mysql is running and connects to my db
for this app, and i am not using
I have a statement like:
echo $ajax-remoteTimer(array('url'='refresh/10',
'update'='refresh_response', 'frequency'=120));
If the client cannot reach the specified url (because the server is
down), is it possible to update a different div or do nothing at all?
I don't want to update the specified
I'm having a heck of a time trying to get CakeAMFPHP 0.6 working with
a cake 1.2 site. We had been working with cake 1.1 and CakeAMFPHP,
which was doing fine. I've spent the past week upgrading our site for
1.2 and everything is working extremely well -- except our flash bits
have ceased to work.
On Jul 8, 2008, at 9:29 AM, morris wrote:
I'm having a heck of a time trying to get CakeAMFPHP 0.6 working with
a cake 1.2 site. We had been working with cake 1.1 and CakeAMFPHP,
which was doing fine. I've spent the past week upgrading our site for
1.2 and everything is working extremely
This topic has to have at least 100 threads in this group. I wonder
why dont you just search before starting a new one. It would be faster
for you, and better for the quality of the group...
Anyway, I´m going to answer you. There are some things that you can do
with ACL, but it´s not the best
As far as I know there's nothing out of the box that's going to help
you do this. The ACL check function is designed to check one CRUD
value on one ACO path at a time. It's a pretty basic implementation
designed for performing a single check on a per-page basis (as opposed
to dozens of checks on
I think it might be most useful if perhaps the legacy example Blog
application was ditched/augmented by something like maintaining a simple
product list/inventory.
This has the advantage of clearly allowing straightforward CRUD operations
on records, simple (non ajax) pagination, simple model
Do I correctly understand that if the url cannot be reached, the DIV
is updated with an error-page, and you want to avoid that? I thought
there would already happen nothing at all when it comes to a timeout.
Not sure, but maybe the 'failure' ajax option could help. Another try
could be to check
Best option would be to enable mod_rewrite on your box, because then
cakephp will work right after setting the MySQL connection details in
the config file.
On Jul 8, 8:43 am, BlueRidgeCliff [EMAIL PROTECTED] wrote:
i have installed WAMP on an XP Pro server, and now cake (twice),
followed some
So you're suggesting I move the following lines from /webroot/
cake_gateway.php
-- loadController (null); see below
-- vendor('cakeamfphp'.DS.'amf-core'.DS.'app'.DS.CakeGateway); see
below
into /webroot/index.php as
-- App::import('Controller', null);
-- App::import('Vendor', 'CakeGateway',
I am new at this also, but have you tried something like
http://localhost/cakedir/users where cakedir is the name that you
copied all you cake file to under your webroot
On Jul 8, 10:43 am, BlueRidgeCliff [EMAIL PROTECTED] wrote:
i have installed WAMP on an XP Pro server, and now cake (twice),
I think you're using even an older version of Cakeamf than I am.
I'd suggest getting the latest goodness from SVN, and following the
instructions here:
https://trac.cakefoundation.org/amf/
-- John
On Jul 8, 2008, at 10:48 AM, morris wrote:
So you're suggesting I move the following lines
Hey,
If you want to write it - go for it! :)
Just suggest a new section and im sure _psychic_ will apreciate all the help.
thanks,
--
Marcin Domanski
http://kabturek.info
On Tue, Jul 8, 2008 at 6:34 PM, Howard Glynn [EMAIL PROTECTED] wrote:
I think it might be most useful if perhaps the
No, it replaces the div with nothing at all but that isn't exactly
what I want.
For example, I have a weather element that is updated every 30
minutes. If it can't retrieve the information from the web server, the
element is blank and the weather information that was there,
disappears. The next
I've been trying, yet again, to get mod_rewrite to work. Now i've gome
accros something that is to me (begin a apache AND mod_rewrite noob)
quite strange:
I have the following file:
C:/Program Files/Apache Group/Apache2/htdocs/cakePHP/app/
webroot/.htaccess with the following content:
IfModule
sorry, guess I should have clarified. We are still using the old
cakeamfphp project (.6) .. not the new cakeamf project.
The reason we are doing this is because I don't have access to the
flash source at this time, and I'm unsure if I will need to be making
any edits to the flash/as if we are to
Well try with smaller images. Also what is your memory_limit set in
php.ini ?
Maybe try an ini_set('memory_limit', xxMb), before calling the
resizing ..
On Jul 8, 3:29 pm, clrockwell [EMAIL PROTECTED] wrote:
Thanks francky06l - I am actually using rc2, sorry for the typo.
The images were
I just had this same problem this morning. Try this
$this-Employee-save($this-data)
instead of this
$this-Employee-save($this-data['Employee'])
--
View this message in context:
http://www.nabble.com/Full-HABTM-example-tp17692422p18345635.html
Sent from the CakePHP mailing list archive at
Ok now I understand. I am not sure, but I think there is no way but
checking the request-content.
The only way i found, is to not set the 'update'-option but instead
using the 'success'-option like this:
'success' = 'if (request.responseText != ) {$
(refresh_response).innerHTML =
I forgot, if you want to update another DIV on empty content, this
could look like:
If you want to update the DIV with some remote content:
'success' = 'if (request.responseText != ) {$
(refresh_response).innerHTML = request.responseText;} else {'.$ajax-
remoteFunction(array('url' = 'error_url',
Thanks for the help. I'll give that a try and see how it goes.
On Jul 8, 12:37 pm, schneimi [EMAIL PROTECTED] wrote:
I forgot, if you want to update another DIV on empty content, this
could look like:
If you want to update the DIV with some remote content:
'success' = 'if
I did some non-sientific performance tests on my G4 laptop and this
release performes almost 2 times as fast!
I did the tests on a standard scaffolded list-view, the first number
is the php execution time, and the second number is the time per
request with an ab test.
RC1: 0.5947s | ab: Time
On 2 Juli, 12:08, keymaster [EMAIL PROTECTED] wrote:
Don't use $uses, ever, it slaughters performance.
So, what are we supposed to use instead?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
CakePHP group.
To
So, what are we supposed to use instead?
app::import
2008/7/8 gurkzor [EMAIL PROTECTED]:
On 2 Juli, 12:08, keymaster [EMAIL PROTECTED] wrote:
Don't use $uses, ever, it slaughters performance.
So, what are we supposed to use instead?
App::import doesn't replace Controller::uses. It replaces uses(). But
$uses loads all models specified whether used or not. If your
relationships are defined well, it's usually unnecessary to specify
anything for Controller::uses.
On Tue, Jul 8, 2008 at 4:26 PM, Sam Sherlock [EMAIL PROTECTED]
Two simple questions, with hopefully easy answers:
1) The render() function and it's paramaters
---
I've been reading forums, snippets of code, this group and the API,
and I still get confused by the use of the render() function used by
cakephp 1.2 question (I'm full of them!): Trying to do pagination
sorting in an index view where one of the columns is from an HABTM
join table. Here is my code: http://bin.cakephp.org/view/223029171.
Not sure what is missing here except for if maybe the syntax for
specifying the model in the
Just throwing it out there
but what if the helper was modified to use ImageMagick from the
commandline, instead of GD? In my experience, ImageMagick is a lot
more capable in handling large images (not to mention, it uses its own
memory space, instead of PHP's). Also, it can handle pretty
Hi.
Is there anyway to call query() from a controller that has no 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
Debug mode level 2 just show de mysql dump (with no errors) and a
Cannot set header information.
On 8 jul, 00:24, Jonathan Snook [EMAIL PROTECTED] wrote:
Do you get anything if debug mode is set to 2? any error messages?
On Mon, Jul 7, 2008 at 10:25 PM, MauroEC04 [EMAIL PROTECTED] wrote:
Hello,
I am having an issue with memory loss, hoping someone can point me in
the right direction. I initially thought it was the image helper, but
that only partially fixed the issue.
Say I click on a link that brings up an article and that article is
pulled from a db. I use this
$conditions
I have a comments table with a unique id, and a reply_id (which will hold
point to the unique id and serve as reply-to messages to the original
comment). How would I model this? Can I have a $var belongs_to that points
back to itself?
thanks
--~--~-~--~~~---~--~~
Hello, I am associating a couple of models and have hit a snag on how
to associate the last piece. I have a users model, a tournaments
model, a signups model. Signups is a HABTM association of the users
and tournaments using with. So far everything works great. The
signups model has id,
Seems like there might be a page with some extra whitespace. Check to
make sure there's no files with extra space after the closing ?.
On Tue, Jul 8, 2008 at 6:29 PM, MauroEC04 [EMAIL PROTECTED] wrote:
Debug mode level 2 just show de mysql dump (with no errors) and a
Cannot set header
$db = ConnectionManager::getDataSource('default');
$result = $db-query('SELECT * FROM ...');
On Jul 9, 8:38 am, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
Hi.
Is there anyway to call query() from a controller that has no model?
--~--~-~--~~~---~--~~
You
On Tue, Jul 8, 2008 at 6:38 PM, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
Hi.
Is there anyway to call query() from a controller that has no model?
Not every controller has to have a model associated with it. In fact,
you will sometimes find that you are calling multiple models from one
Hi.
I'm trying to fetch some data from the DB from a statistics controller
that doesn't have any particular model associated with it. I just need
to collect some info from the DB with some custom queries.
Thanks Grant Cox
On 9 Jul, 02:22, Chris Hartjes [EMAIL PROTECTED] wrote:
On Tue, Jul 8,
Hi,
Using 1.2 and I'm doing a simple model saving page then $this-
redirect(), I get the header error telling:
Warning (2): Cannot modify header information - headers already sent
by (output started at C:\Program Files\Apache Group\Apache2\htdocs\eco
\app\controllers\shippers_controller.php:1)
On Tue, Jul 8, 2008 at 9:53 PM, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
Hi.
I'm trying to fetch some data from the DB from a statistics controller
that doesn't have any particular model associated with it. I just need
to collect some info from the DB with some custom queries.
Again, you
Great idea, but no, it doesn't. (Simple Pie, btw, is a news feed
aggregator)
On Jun 5, 6:23 pm, francky06l [EMAIL PROTECTED] wrote:
Are you sure the Simplepie(I do not know it, probably as a
vendors ?) hasn't got a sessionstart ? If so try to comment it.
On Jun 5, 8:25 pm, Adam Friedman
I've been given a live site that was built on an older version of
cake. I don't know the exact version, but I suspect it was back from
around 2006.
First question: is there any way to determine exactly what version of
Cake it was based on the files in the install?
From that, I may have
Hi All,
This seems like a real n00b question, but here goes. I'm working on an
app which has articles - in my case news - and users who create/modify
the news articles. Now I found this nifty little behaviour -
Wow! I didn't knew about whitespaces after ?...
Fixed. Thankyou =]
On 8 jul, 21:26, Jonathan Snook [EMAIL PROTECTED] wrote:
Seems like there might be a page with some extra whitespace. Check to
make sure there's no files with extra space after the closing ?.
On Tue, Jul 8, 2008 at 6:29 PM,
Hi,
I have been started using CakePHP for small web sites.. Can I use it
to develop such social networking portal
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
CakePHP group.
To post to this group, send email to
On Jun 5, 8:25 pm, Adam Friedman [EMAIL PROTECTED] wrote:
Hi folks
I was trying to get Simplepie component working (http://
bakery.cakephp.org/articles/view/simplepie-cakephp-component), and it
worked fine. Here's what I did:
- First I added the component 'Simplepie' to the controller:
On Wed, Jul 9, 2008 at 9:30 AM, loguKK [EMAIL PROTECTED] wrote:
I have been started using CakePHP for small web sites.. Can I use it
to develop such social networking portal
Yes, do you feel that anything will stop you?
Cheers
Tarique
--
Hi,
thanks for the reply.
I wanted to know how far it is popular and big applications built in
it. i am planning to apply, http://andhimazhai.com/ ... basically it
is done in lesser way of code, so i want to use CakePHP to develop the
same portal now again..
please suggest me how can I
83 matches
Mail list logo