You can do something like this:
if ($this-Session-check('Message.flash')):
$message = this-Session-read('Message.flash')
$this-Session-delete('Message.flash');
endif;
...and then process $message as you like. A bit long winded, but...
Jeremy Burns
Class Outfit
My Model:
urlComentario.php
?php
class UrlComentario extends AppModel
{
var $name = 'UrlComentario';
var $useTable = 'url_comentario';
var $primaryKey = 'id_comentario';
}
?
My Controller:
urlComentarios_controller.php
?php
class UrlComentariosController extends
Hi,
I'm trying to integrate a CakePHP website to PagSeguro (brazilian's Paypal)
and when PagSeguro sends a POST containing the payment data, CakePHP don't
show the POST, even if I put in the controller a debug($_POST); die();.
I have checked the network tab of Firebug and the POST is being sent
Hello,
I did it but to no avail. I'm using wamp.
I removed the comment that line: LoadModule rewrite_module modules/
mod_rewrite.so
I observed the following lines:
Directory /
Options FollowSymLinks
AllowOverride All
#Order deny,allow
#Deny from all
/Directory
Continues to
Hi,
I have just uploaded my local version to my webserver.
Always a challange :-)
I get these 2 errors which I don't understand..
Missing Component File
Error: The component file was not found.
Error: Create the class P28nComponent in file: app/controllers/
components/p28n.php
I used this
Hi all:
I´m using CakePHP Wizard Component from
https://github.com/jaredhoyt/cakephp-wizard
It works well but I don´t know how to set a back link in view and
I can´t find how to do it in the wiki
https://github.com/jaredhoyt/cakephp-wizard/wiki.
How do I do in the view? How do I
this is because of some filename coventions...model class is UrlComentario
and model filename is url_comentario.php
class filename is url_comentarios_controller.php and classname is
UrlComentariosController
url is in your case: maybesubdirectory/url_comentarios/index
--
Lep pozdrav, Tilen
Model:
class Availability extends AppModel {
var $name = 'Availability';
var $useTable = 'bform';
function something() {
return $this-find('list', array ('fields' = array ('row1',
'row2_E')));
}
}
In controller:
function index() {
$this-set('bform',
I have written automation test cases for my application.Below is the
sample code i have used for web testing.
class UserWebTestcase extends CakeWebTestCase{
var $name='UserWebTestcase';
function testLogin001()
{
//Test if new user registration form works
Interesting. What would happen if you put the validation in the model
for the join table?
On Jun 14, 3:17 pm, Shaz shazam...@gmail.com wrote:
I can - but in that arises another situation:
I also have Location HABT Language - and I don't want any restrictions
there. So a location can have more
Im trying to get data from DB.
I have table post: title, body etc from tutorial
http://book.cakephp.org/view/1528/Blog
but i have add there some columns like: link, media
Now when im geting data in posts_controller:
$this-set('posts', $this-Post-find('all', array('order' = 'id
DESC', 'limit' =
I haven't actually made models for the Join table - I don't think you
need to for a HABTM relationship
On Jun 15, 1:41 pm, Rob Maurer robmau...@gmail.com wrote:
Interesting. What would happen if you put the validation in the model
for the join table?
On Jun 14, 3:17 pm, Shaz
Double check the URL you're sending the POST request to - and ensure
the controller action is setup to receive it; especially if you're
using Auth / ACL.
Also post date in cake should be available in $this-params.
On Jun 14, 3:53 pm, Ivan Rocha ivan.cr.n...@gmail.com wrote:
Hi,
I'm trying to
http://book.cakephp.org/view/1545/Preparing-to-Add-Auth
At the bottom it explains how to allow actions currently not
initialised as ACO's.
On Jun 13, 7:21 pm, taq taqman...@gmail.com wrote:
now I use acl component in my webapp
when I add new action I got you unauthorize to access this location
Try the threaded find? But list with fields specified correctly
should do the job. Read the documentation carefully:
http://book.cakephp.org/view/1022/find-list
On Jun 11, 3:33 am, cake-learner sh.koiz...@gmail.com wrote:
Can I get the search result so that it returns the id as key?
so if you
Use pure javascript vs the JS helper for jQuery - should sort it.
On Jun 9, 8:48 am, OldWest ja...@jasonwydro.com wrote:
I could be missing something severely here, but this is just not adding up.
I built an ajax form which is working perfectly fine with ProtoType and
Scriptaculous.
I am
Any help? I am really helpless :-(
--
Our newest site for the community: CakePHP Video Tutorials
http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others
with their CakePHP related questions.
To unsubscribe from this group, send email to
Perhaps the model has been cached. Check for files in the folders under
/tmp/cache/. Delete anything (except the folders) there and try again.
Jeremy Burns
Class Outfit
jeremybu...@classoutfit.com
http://www.classoutfit.com
On 15 Jun 2011, at 13:06, KooT wrote:
Im trying to get data from DB.
yes, it was it.
Thank You for Your help!
On 15 Cze, 15:01, Jeremy Burns | Class Outfit
jeremybu...@classoutfit.com wrote:
Perhaps the model has been cached. Check for files in the folders under
/tmp/cache/. Delete anything (except the folders) there and try again.
Jeremy Burns
Class Outfit
Ok, I found it!
There is nothing special to do, simply write in view:
echo $this-Form-submit('Previous', array('name' = 'Previous',
'div' = false));
On 15 jun, 11:07, nomen gaston...@gmail.com wrote:
Hi all:
I´m using CakePHP Wizard Component
If you want to save your data before previous (so user wont lose typed
data):
function _beforeCancel() {
// if user click on Cancel button:
$this-Model-save($this-data);
}
function _beforePrevious() {
// if user click on Back/Previous button:
I have a similar problem and wondering if this is a problem with
1.3.10
On May 18, 3:11 pm, Michael Gaiser mjgai...@gmail.com wrote:
This line no longer seems to output a message nor does any other use of
setFlash.
$this-Session-setFlash('Cookie created. It will expire
Or instead of reinventing the wheel just using it the way it is
supposed to be used in the first place?
http://www.jamesfairhurst.co.uk/posts/view/custom_cakephp_flash_messages_updated/
On 15 jun, 09:38, Jeremy Burns | Class Outfit
jeremybu...@classoutfit.com wrote:
You can do something like
Hi,
when I have a failed validation, my form reloads and I see the old
captcha code in my text field.
How can I have this field empty again, in case I have to reload after
a failed validation?
Thanks!!
--
Our newest site for the community: CakePHP Video Tutorials
http://tv.cakephp.org
Check
Hi !
How get the database name from a Model?
Because the $useDbConfig returns only the name of config..
thanks,
celso
--
Our newest site for the community: CakePHP Video Tutorials
http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others
with
$useTable
--
Lep pozdrav, Tilen Majerle
http://majerle.eu
2011/6/15 Celso cels...@gmail.com
Hi !
How get the database name from a Model?
Because the $useDbConfig returns only the name of config..
thanks,
celso
--
Our newest site for the community: CakePHP Video Tutorials
Seems like this should be easy, and maybe I'm just missing how to do
it, but I want to execute the following query. [preferrably using
find('list')]
SELECT `Contact`.`id`, `Contact`.`name` FROM `contacts` AS `Contact`,
`contact_companies` AS `ContactCompany` WHERE `Contact`.`id` =
You should check this:
http://bakery.cakephp.org/articles/nachopitt/2010/07/01/habtm-validatable-behavior
On 15 jun, 08:24, Shaz shazam...@gmail.com wrote:
I haven't actually made models for the Join table - I don't think you
need to for a HABTM relationship
On Jun 15, 1:41 pm, Rob Maurer
Are you trying to do an inner join where you only pull back contacts who belong
to a company?
Jeremy Burns
Class Outfit
jeremybu...@classoutfit.com
http://www.classoutfit.com
On 15 Jun 2011, at 17:44, Zuha wrote:
Seems like this should be easy, and maybe I'm just missing how to do
it, but I
Hi,
I have tables that are created on the fly and I'd like to access it
thru Model. Since those tables are dynamically created, I don't have
the model .php files for them. The tables are created conforming to
Cake's naming convention. I tried to use loadModel() to load them but
Cake still
Close... select where we only pull back contacts where the company
belongsTo contact
On Jun 15, 3:00 pm, Jeremy Burns | Class Outfit
jeremybu...@classoutfit.com wrote:
Are you trying to do an inner join where you only pull back contacts who
belong to a company?
Jeremy Burns
Class Outfit
INNER was the word I needed to remember to get an alternative to
work.
For other people here's what the end query (which returns the same as
the above query) turned out to be.
SELECT `Contact`.`id`, `Contact`.`name` FROM `contacts` AS `Contact`
INNER JOIN contact_companies AS `ContactCompany`
Currently the default behavior of any cake site if the database goes
down is simply to function normally - without the data of course.
this causes a lot of confusion among the users.
they see all the static content of the page, the dynamic database
loaded content is gone.
they try to login but
i would go for
$this-tablePrefix.$this-table
prefix you would need if you used in your config
tip: use a proper IDE which auto-completion
this will show you the available names/fields inside your model
On 15 Jun., 19:07, Tilen Majerle tilen.maje...@gmail.com wrote:
$useTable
--
Lep
$databaseName = $this-getDataSource()-config['database'];
On 16 июн, 00:06, Celso cels...@gmail.com wrote:
Hi !
How get the database name from a Model?
Because the $useDbConfig returns only the name of config..
thanks,
celso
--
Our newest site for the community: CakePHP Video Tutorials
I'm just trying to run a quick and dirty test on my site and I thought
it would be best to use pages for it.
I've created a page called test.ctp in the views/pages folder and a
new action called test in the pages controller.
But I keep getting a page not found error.
Am I missing anything?
--
I create the Article and New and comment for both in my project
and I try to search for example I found blog tutorial but example
without session
when add comment I need to add username avartar such as genaral
website
what should I do
--
Our newest site for the community: CakePHP Video
Make stub model with $useTable = false, load it, then call $this-
setSource('table_name') on it.
Or list all static models in AppModel, overwrite __construct() there
and set $useTable to false there for any not listed name.
On 16 июн, 02:49, qua...@gmail.com qua...@gmail.com wrote:
Hi,
I have
38 matches
Mail list logo