you set the validation rules in the Model of whatever your using (i'm
guessing users model) /app/models/user.php
search for cakephp validation in google and look in the cakephp
manual, it should be what you need.
On Jan 5, 6:53 pm, kicaj wrote:
> How validate field only we entered some value int
When I was learning php classes we made a model object for each type
of data we had. Each model would have crud from another class and then
model specific functions & attributes. For example i would have:
class Person extends Crud {
var $first_name;
var $last_name;
static function getpe
Hi Nancy:
Matt Curry wrote an HTML cacher helper that writes the entire view to
a file and saves it in the webroot. Check out his helper code -- it
seems to be doing exactly what you're after; writing the view to an
HTML file.
http://github.com/mcurry/html_cache
http://github.com/mcurry/html_cach
How validate field only we entered some value into input?
For example:
I have form with fields: username, password and email
I set 'value'=>'' in edit template for password input field
When I edit this fields, I want update filed password only when I
wrote some new password, but when I lost empty
Hi,
I create form for example with two fields: Client.name, User.email.
I send this form to Client model and validate 'name' field.
But how I can validate field 'email'?
Thanks!
Check out the new CakePHP Questions site http://cakeqs.org and help others with
their CakePHP related questions.
You
On Tue, Jan 5, 2010 at 5:59 PM, Fred Riley wrote:
> (..)
> I can't be the first person to have come across this issue. Is there
> not a FAQ somewhere?
Just include the directive
RewriteBase /~theusername
at the beginning of your .htaccess files.
Best regards.
--
MARCELO F ANDRADE
Belem, Amaz
Sorry, Kees, I saw the second line in your reply but as you preceded
it with "It might be that .htaccess files are not handled for user
directories" I presumed that it didn't apply in my case,
because .htaccess files plainly are handled in XAMPP. My mistake, and
thanks for the second reply. Ok, loo
San Jose!! it is silicon valley and I don't need to travel hahaha. San
Francisco would work better probably though! :)
On Jan 4, 9:47 am, drpark wrote:
> Hi all!
> Miami, Orlando, Wilmington NC, Las Vegas, Chicago, Seattle for the USA
> in order of preference
> Cancun for Mexico,
> Vancouver for
Notice: unserialize() [function.unserialize]: Error at offset 6 of
1051 bytes in C:\xampp\htdocs\projects\courses\cake\libs\cache
\file.php on line 189
anyone seen that before? I have 5 similar warnings all because the
same line. I am on a windows machine running xampp.
when i click notice the er
Fred,
As I wrote in my reply you have to make a small change in app/config/core.php
where you have to uncomment line 59 and remove the .htaccess files that are
listed just before that line.
All URLs should now be something like ../cake/index.php/page instead of
../cake/page
Check out the new
Thanks for the reply, Kees.
On Jan 5, 4:23 pm, Kees de Bruin wrote:
> Yes you can. Just put all inside your public_html directory (assuming that
> user directories are enabled) or a subdirectory of public_html.
Ok, that's useful to know. My immediate 'issue' is on localhost. I
could, as Adeola
Isn't it nice to have a descent data layer like we do in cake.
Granted it might be a few days work to switch from MySQL to something
like PostgreSQL for a decent sized project.
But you probably have a few years before we ever get to that point
where we are forced to do so.
Don't sweat the small stu
I know this is a really "green" question, but how does the
'{n}.State.id' section of your code work. I tried to look in my php
manual but was at a loss of where to find information on this "data
construct"/Placeholder/Whatever{n} is??? I have been at a loss as to
how to navigate the "complex" arra
Thanks John,
Good looking out! I will add that since its more cake-ish than my current
setup with the after method.
Thanks again for your time and sorry for the confusion :)
Dave
-Original Message-
From: cake-php@googlegroups.com [mailto:cake-...@googlegroups.com] On Behalf
Of John And
CakePHP manual reference is
http://book.cakephp.org/view/191/options-before-options-between-options-separator-a
Enjoy,
John
Check out the new CakePHP Questions site http://cakeqs.org and help others with
their CakePHP related questions.
You received this message because you are subscribed to t
Hi Dave,
I did understand that your hint was - a hint to the user - but I
assumed that you would find out how to include that together with the
form field definition :)
Using the form helper, I would just add the "after" option to include
something after the entry field. Using your hint code, I g
Thanks,
This works perfect.
error('User.password')){?> class='error'' >
After re-reading Johns email I think i gave the impression that the hint was
the error message. That is where I may have causeed some confusion. The hint
is always visible, its not an error message. Imagine a field called
Hello John,
Only because I have my hint class in there so in my forms there is a
little text beside each field. This is all wrapped inside the Sure I
can get the input text error to get an error class to hi-light the text
field, but looks rather dumb when the form has :
Form
[label] [field]
Yes you can. Just put all inside your public_html directory (assuming that user
directories are enabled) or a subdirectory of public_html.
It might be that .htaccess files are not handled for user directories. If so,
check the file app/config/core.php and enable rewriting by CakePHP.
On 4 jan 2
>
> Also as I said, MySQL isn't competition to
> them, both are targeted to different markets.
Five years ago, yes. But now, no. I worked both in finance and telecom
industry and felt MySQL heat. Just take a look at BI, ERP and CRM world, you
will see MySQL there already to some extent.
> Do yo
On Tue, Jan 5, 2010 at 9:15 AM, Dinh wrote:
> Is it trustworthy? Oracle is not friendly to open source at all. They can
> kill MySQL just by delaying to fix bugs. MySQL development is rather open.
> It is quite opposite to Oracle style.
>
AFAIK it was one of the conditions imposed by US and the E
One more issue that has deflated my initial euphoria...
The results don't paginate. How can I rectify that?
On Jan 2, 4:53 am, Jeremy Burns wrote:
> A success! Using your self created join code I arrived at this:
>
> $results = $this->LocationType->find(
> 'all',
> array(
Is it trustworthy? Oracle is not friendly to open source at all. They can
kill MySQL just by delaying to fix bugs. MySQL development is rather open.
It is quite opposite to Oracle style.
I think you are overreacting, have you read Oracle's public position
> on this ? I think not:
>
>
> http://www.
Isn't it open source?
Not the first time someone made a fork of it - including the original
author. :)
On Jan 4, 10:31 pm, Juan Luis Baptiste
wrote:
> On Mon, Jan 4, 2010 at 10:05 AM, hashmich wrote:
> > Oracle is going to take over Sun Microsystems - who are the owner of
> > the copyrights for
Hi Donnerbeil,
The problem is likely down to the fact that you're doing a read of the existing
Rating record expecting that to set the id before the save, but you're then
passing in a full data set (without and id set) to the save method.
Maybe try replacing:
> $this->Rating->read(null,$entry[
Hi Fred,
>From what I understand about XAMPP, the document root is in
/Applications/XAMPP/htdocs, so I would put the CakePHP files in there first
and try accessing it again. Also make sure that the default Apache is not
running or you are serving XAMPP from a different port.
HTH,
Adeola.
2010/1
It's easy, the only thing that you have to do is
$data = $this->State->find('all', array('fields' => 'State.id,
Provincia.state'));
$state_list = Set::combine($data, '{n}.State.id', '{n}.State.state');
$this->set('state_list', $state_list);
With this the select will show the state names and in
Maybe this will help: http://bakery.cakephp.org/articles/view/encrypting-urls
On Jan 1, 11:54 am, anka wrote:
> Hi @all,
>
> I have a (almost) simple question! Is it possible to make all cake php
> REST URLs unreadable? What I mean is, that a given REST URL like ".../
> user/delete/10" is very si
Hi all,
I have a simple rating controller, so users can rate each other. I
don't know the reason, but every few days the whole ratings table in
the database is empty. All ratings are lost. Here is my ratings
controller as I use it. There are no other methods or anything else. I
exactly use it this
This suggestion by Jeremy looks all right:
$states = $this->Employee->State->find('list');
$this->set(compact('states'));
My hint would be to change your database schema to state: id, name or
state: id, title as state: id, state is redundant anyway. The magic
that will appear is cake auto detectin
Hi again,
I am open to learn, so please tell me, whats the benefit of url
obscurity if not protecting against CSRF. A large german social
network uses that to protect against CSRF - though they do not use
UUIDs. Just links like domain.tld/long_random_looking_stuff_here, it
works against mining too
Well, now that I took a better look at your code, I don't understand
why you don't use the standard cake form field and error generation,
because that should be all you need :)
Example HTML from my own code where the field has an error - it is
mandatory:
[code]
print( $form->input( 'Reporter.emai
What you have here looks correct, except that your $belongsTo
definition in your State model looks wrong. Shouldn't that be a
$hasMany definition? That means that an Employee belongs to a State,
and a State has many Employees.
The drop down is displayed in a view and the contents of the drop down
Try this,
error('User.password')){?> class='error'' >
Check out the new CakePHP Questions site http://cakeqs.org and help others with
their CakePHP related questions.
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email t
Here you go - this covers the basics. Using the component is actually
quite simple:
http://www.jeremy-burns.co.uk/2009/12/cakephp-sending-email-using-the-email-component/
On Jan 5, 1:47 am, otisjs01 wrote:
> Hello,
>
> I am new to CakePHP and trying desperately to learn!
>
> My most recent stru
Thanks John,
I did set the 'error' => false so no message shows. But how do I get the
error class to end up inside the
I tried an assortment of attemps with
???
But nothing.
Ideas?
Thanks,
Dave
-Original Message-
From: cake-php@googlegroups.com [mailto:cake-...@googlegroups.com] On
Yes you can!
In the form field, add the option 'error' => false to disable the
automatic error message. Then use the form helpers error method for
the field and place it whereever you want.
See http://book.cakephp.org/view/721/error
Enjoy,
John
On Jan 5, 9:46 am, "Dave" wrote:
> Is it possible
37 matches
Mail list logo