Hey,
we can't unless you provide us more details.
Aivaras
On Wed, Oct 21, 2009 at 16:09, Amit Rawat wrote:
> Hello friends,
>
> I am having a problem my before render function in app controller is being
> called twice. can anyone tell me why
Hey,
App::import('Controller', 'PostsController');
$this->Posts = new PostsController();
$this->Posts->add($this->data);
Cheers,
Aivaras
On Fri, Oct 9, 2009 at 15:37, toneee wrote:
>
> Hi Guys,
>
> I wonder if anyone can help?
>
> How would I
Hey, take a look at this:
http://voveris.eu/2009/09/05/left-join-with-cakephp/ I am sure you find this
handy.
On Mon, Sep 28, 2009 at 12:04, hunny wrote:
>
> Hi All,
>
> I am new to cakephp. I would like to execute the following SELF Join
> query.
>
> SELECT B.* FROM `users` AS A LEFT JOIN `use
Hey,
You would surely love Zend studio! Just create a new project, and then add
all cakePHP folder into your current project, I bet you will be surprised!
Hope this helps,
Faifas
On Fri, Sep 25, 2009 at 10:29, Selva manickaraja wrote:
> Hi,
>
> I wish to do all my php project development usin
WHERE 1 = 1
SELECT `GalleryPhoto`.`id`, `GalleryPhoto`.`position`,
`GalleryPhoto`.`gallery_id`, `GalleryPhoto`.`photo_id` FROM `gallery_photos`
AS `GalleryPhoto` WHERE `GalleryPhoto`.`gallery_id` = (7)
SELECT `GP`.`id`, `GP`.`filename` FROM `uploads` AS `GP` WHERE
`GalleryPhot
Great job Miles!
Faifas
On Wed, Sep 16, 2009 at 05:51, Miles J wrote:
>
> So I just released my Cupcake forum plugin into a public beta. If you
> need an easily integrateable forum system into an existent Cake
> application, use this plugin!
>
> Download: http://www.milesj.me/resources/script/
Create each employee a different user and log which orders did the employee
see.
Then, after firing a employee you will only have to delete his/her user.
Simple as that.
Faifas
On Wed, Sep 16, 2009 at 14:48, Tim wrote:
>
> Thanks for the replies. The IP restriction was since the employees
> k
When you get a new order, new row in database table appears. Set it's
confirmed = 0 and when staff refreshes the page (or JS does that every
minute) they would see the new order. As for IP restriction - why would you
want this? Cake's got it's auth, so there's no need to add IP restriction.
As for
Didn't you migrate to an existing database? Remember that Security::salt
does not only use md5 or sha1 but also a Salt that you've filled in your
core.php
Faifas
http://www.voveris.eu/
On Tue, Sep 15, 2009 at 22:10, Wladiston Paiva wrote:
> Hi guys!
> I find a problem in auth component.
>
> *Us
DS stands for DIRECTORY_SEPARATOR which is / on unix and \ on windows. So,
in fact, having an almighty mac does not solve the problem of DS :(
Faifas
http://www.voveris.eu/
On Tue, Sep 15, 2009 at 23:17, hahmadi82 wrote:
>
>
> Hi,
>
> I'm developing this on a mac. I'm not sure what "DS" means
27;title']
> ['Post']['description']
> ['Comment']['comment']
>
> All i need is User or Post or Comment as a variable.
>
> Thanks for your help so far guys.
>
> Dave
>
> --
> *From:* Aivaras [mailto:faifas1...@gmai
var myVar = $(this).attr('name').substr(4);
myVar = myVar.replace(/\][username]/gi, '');
myVar = myVar.substr(1, myVar.lentgh);
Faifas
On Mon, Sep 14, 2009 at 15:57, Dave Maharaj :: WidePixels.com <
d...@widepixels.com> wrote:
> I know its more of a jQuery question...i asked on the jQuery grou
Hey,
you can create a custom validation function which will check for unique data
in both fields.
Faifas
On Mon, Sep 14, 2009 at 13:10, Shaun wrote:
>
> I have a table called comment_ratings where users can rate comments up
> or down. It looks like this:
>
> TABLE: comment_ratings
>id =
Hi,
there's a whole section about that in a Book!
http://book.cakephp.org/view/172/Authentication
Faifas
On Thu, Sep 10, 2009 at 00:01, Salines wrote:
>
> Hello,
>
> I'm new to cakephp :)
>
> Help me to find way how i can made links for (non)privilege users.
>
> example:
>
> [guest] show li
http://www.milesj.me/forum is purely with CakePHP :p
Faifas
On Wed, Sep 9, 2009 at 02:09, ihti wrote:
>
> CakeForum is a fast and lightweight CakePHP powered forum software
> with very basic functionality. It is being actively developed and new
> featured are popping up on a daily basis.
> Cak
Well, in this case if you want you can store your ID in a session, but form
is fine also, it's how we used to do it ;)
Faifas
On Mon, Sep 7, 2009 at 07:47, Jamie wrote:
>
> Well, are you just new to CakePHP, or PHP in general? Because remember
> that CakePHP is really just PHP. And just like wi
te fck.
>
>
> On 4 Sep, 16:26, Aivaras wrote:
> > Why is it bad to mix JS with PHP? You can get some seriously cool
> results.
> > Or when you need a custom ID for your element which you created via ajax,
> > you still have to use PHP
> >
> > Faifas
>
Why is it bad to mix JS with PHP? You can get some seriously cool results.
Or when you need a custom ID for your element which you created via ajax,
you still have to use PHP
Faifas
On Fri, Sep 4, 2009 at 13:55, martinp wrote:
>
> I would ask in a Javascript forum unless you're mixing up y
Or just create a custom validation rule, where you can add your own regexp -
remember, that not changing the core will always be so helpful sooner or
later ;)
Faifas
http://www.voveris.eu/
On Mon, Aug 31, 2009 at 18:58, brian wrote:
>
> It looks like the Validation regex needs to be updated. T
indeed, defining it is so simple! On the other hand you can still create a
symlink from /var/www/app_name/logs/ to app_path/tmp/logs.
I bet that will work like a charm if you have +Options
FollowSymlinksOnOwnerMatch also ;)
Faifas
http://www.voveris.eu/
On Mon, Aug 31, 2009 at 23:16, Crazy wro
ick
> witch redirect working after user did login but after even go to /
> load default general route from /
>
> but i'll try user Route::conntect in login() :)
>
> On 31 Sie, 10:32, Aivaras wrote:
> > Hey,
> >
> > did you take a look at thishttp://book.cak
Hey,
did you take a look at this http://book.cakephp.org/view/391/loginAction ?
Faifas
On Mon, Aug 31, 2009 at 11:05, andrzejborkow...@gmail.com <
andrzejborkow...@gmail.com> wrote:
>
> i want to change default route after login my users, i try like this:
>
> [/project/app_controller.php]
> pu
Ever tried $this->Email->to = 'o...@user.com, t...@user.com';// ?
Faifas
On Mon, Aug 31, 2009 at 09:56, Brendon Gleeson wrote:
>
> How do I specify multiple $to addresses in the email component? when I
> specify a comma separated string the mail debug indicates "Array"
> instead of a string?
>
esign was not made by me ;-)
> I'm just responsible for all the bugs you may find
>
> On 30 Aug., 17:14, Aivaras wrote:
> > I just love the layout, the site looks great, good job!
> >
> > Faifas
> >
> > On Sun, Aug 30, 2009 at 22:45, Enrique
> wrote:
I just love the layout, the site looks great, good job!
Faifas
On Sun, Aug 30, 2009 at 22:45, Enrique wrote:
>
> Dear Cake Fans:
> We can proudly announce our freshly baked site:
> http://www.guerra-creativa.com
> (Still Alpha, but already 948 users!)
>
> """
> Guerra Creativa is a community p
Well,
model.php line 1388 in function updateCounterCache says foreach
($this->belongsTo
as $parent => $assoc) {
therefore in theory you could use this belongsTo method.
Somebody, please confirm this.
Faifas
On Sun, Aug 30, 2009 at 11:14, WebbedIT wrote:
>
> I *think* the OP is actually afte
nt_count.
>
> Within the Post and Comment model you would have.
>
> var $belongsTo = array('User' => array('counterCache' => true));
>
> And thats it.
>
> On Aug 29, 3:45 pm, Aivaras wrote:
> > Sorry to say Miles, but the guy was asking fo
Not exactly persianshadow,
it is ok to leave action only, or fill nothing into redirect if you want
user to be redirected to current controller and action.
As for your issue arif,
why don't you try some debugging to see if redirect(); is actually called?
if(!empty($this->data))
{
if($this-
Sorry to say Miles, but the guy was asking for a double counterCache :x
So, if User hasMany Post
and User hasMany Recipe
the guy would want user_post_count and user_recipe count in his users table.
Unfortunately, I do not know the solution with cake's countercache :(
Faifas
On Sun, Aug 30, 20
Hey,
well, you can always do the following echo $form->input('whatever',
array('name' => 'data[Blogurl][url][]'));
to get your desired names.
If you want to append inputs on button click you will have to use
javascript. Since I prefer jQuery, the code would be:
$("#button_id").click(function(){
Hey folks,
I've been away from cakePHP lately, but finally I've stopped reinventing the
wheel and just went back to cakePHP. Let me say I am proud of it and I love
it again!
Since I was gone, cake's improved and I definitely like it.
Anyway, I've came up with a problem which obviously should be s
Well, I can't replicate the error, but it was only selecting data from one
table which was surely the case.
Thank you for reminding about counterCache, I used to love it!
Cheers,
Faifas
On Fri, Aug 28, 2009 at 19:53, WebbedIT wrote:
>
> What SQL and error is it generating? Why not run the fi
:
> > What about create a true poll for it?
> >
> > First create a poll for all suggestions, after create a poll to vote on
> that
> > suggestions and voilá =)
> >
> > Henrique Machado
> >
> > 2009/5/18 Aivaras
> >
> > > Hey,
> &
Hey,
actually the most annoying thing is that we cannot download separate parts
of Cake. It would be cool if advanced users could choose what do they need
for their project, just like mootools made in their download page. I
certainly understand that this is just *wishful thinking* because Cake's
c
Hey,
if you want to use Auth info in your views it is very simple.
Try this in your view: pr($session->read('Auth.User')); //assuming User is
your login model, otherwise try pr($session->read('Auth'));
Hope you find this handy,
Faifas
On Mon, May 18, 2009 at 12:59, Marojahan M.T. Sigiro wrote:
Why not setting different modes for your virtual host only?
And yes - this changing will affect other sites aswell. (assuming your
is /var/www)
Greets,
Faifas
On Sat, May 2, 2009 at 11:10, shinokada wrote:
>
> My school server is running on Windows 2003, XAMPP.
> I have other applications ru
ut you can
> keep your critiques to yourself. Maybe I am not a professional PHP guru such
> as yourself but the way you learn is from mistakes.
>
>
>
> ------
> *From:* Aivaras [mailto:faifas1...@gmail.com]
> *Sent:* April-30-09 1:55 PM
>
>
d changing it to , where they tied
> changing it to in a db, and I get a report of who was doing stuff they
> should not be doing. So thats why the number can change..if they added 5
> text fields in a form using Firebug or something i see the 5 fields they
> added and what they tried to
<
d...@widepixels.com> wrote:
> Right but the [0] [1] will change depending on the array its self.
>
> I do not know the number that will be generated as it could be an array of
> errors.
>
> If there is 1 error [0] but if 10 errors?
>
> Ideas?
>
> -----
Hey,
echo $the_variable_you_are_pr_ing[$key]
example: echo $aNonsenceLetters[0]; // outputs: jkl
Cheers,
Faifas
On Thu, Apr 30, 2009 at 00:47, Dave Maharaj :: WidePixels.com <
d...@widepixels.com> wrote:
>
> How can i get the value of a key?
>
> the array is from debug($requests);
> for examp
Hey,
did you remove associations in your other models?
Cheers,
Faifas
On Wed, Apr 29, 2009 at 17:32, forrestgump wrote:
>
> hey guys,
> Iam working on a cakephp app and i ran into this problem, though
> minor it is driving me crazy
> I had created a complete MVC structure for a "Seasons"
Hey,
your $content_for_layout is filled by your view, which is called via
controller/action.
If you want your domain.tld/ to go to specific controller/action instead of
/pages/display/home you need to create a routing rule (see book for this).
The file is here: APP/core/routes.php
If you want to
If you have a server and ssh access (which I assume you due, because you
told you had online server) you can easily change permissions.
FYI: you don't need to do chmod 777 /cake/tmp/ -R
It's enough to do chown www-data:www-data /cake/tmp/ -R more security, less
log-reading then :p
Another thing,
Why in this world you're using $form->label()? CakePHP isn't that
complicated :o
Did you actually check for any errors in the behaviour itself? Try to debug
parts of the code: start with small ones then go bigger and see where it
breaks. Then you will definitely find an answer :)
Cheers,
Faifas
Linai,
pasidaryk Modelyje f-ja beforeSave(){ ir ten ikalk $this->data =
Sanitize::paranoid($this->data); } ir vsio, iskals tau viska ;) Dar server
apachej ar SQL uzsetink magic_quotes_gpc on (nors ciuju php.ini). Sekmes :)
English:
Linasm
rewrite Model's beforeSave method to beforeSave($this->da
You define dontUseModels, but you are checking for dontUserModels, are you
sure this code is working as expected? :)
Cheers,
Faifas
2009/4/14 Dérico Filho
>
> I solved.
>
> I put this in one of application controllers... although it can be put
> also in app_controller.php
>var $dontUse
You can simply create a new controller/model and parse your data there.
Create a view so that everything would be ready.
You should also take a look at routes.php which can be found at
cake/app/core/routes.php and change routing to your desired place.
Hope you find this handy,
Faifas
On Tue, Ap
ble with the
> conventions instead of trying to shoe-horn old code into controllers
> and models.
>
> /Martin
>
>
> On Mar 23, 5:06 pm, Aivaras wrote:
> > Hello dear developers,
> >
> > I am wondering if it is possible to use CakePHP as a part of project. I
> mean
&g
Hello dear developers,
I am wondering if it is possible to use CakePHP as a part of project. I mean
I'd love to have some old code, but would still love to use CakePHP.
I cannot convert everything to cakephp so that is why I need my old code to
work also.
Any suggestions?
Thanks in advance,
Faif
Exactly
On Fri, Mar 20, 2009 at 11:58, Henrik Gemal wrote:
>
> class BookingsController extends AppController {
>
> rite?
>
> On Mar 20, 10:48 am, "jitka (poLK)" wrote:
> > > class TestController extends Controller {
> >
> > Guess what is wrong in this line.
> >
>
--~--~-~--~~-
Daffy, you may also want to add this to your beforeFilter():
Configure::write('Session.timeout', '600');
It will make session to last longer, hopefully, enough to load images.
Cheers,
Faifas
On Wed, Mar 18, 2009 at 18:12, Daffy wrote:
>
> Another update.
>
> I tried inserting this code into m
Hey,
Why not trying this: Configure::write('security', 'medium')? I believe it
would work.
Best wishes,
Faifas
On Tue, Mar 17, 2009 at 20:52, Alfredo Quiroga-Villamil
wrote:
>
> Ummm, not that I know of.
>
> Regards,
>
> Alfredo
>
> On Tue, Mar 17, 2009 at 2:38 PM, Daffy wrote:
> >
> > Thanks
Hey,
try this: debug($this->Auth->user()); die;
it will print out everything about the current user, so I am pretty sure you
will find out how to adjust your application.
Cheers,
Faifas
On Tue, Mar 17, 2009 at 21:42, Dave wrote:
>
> Can someone point me in the direction on how I would check
Thank you!
Faifas
On Mon, Mar 2, 2009 at 19:28, kai wrote:
>
> Maybe this article will help you:
> http://bakery.cakephp.org/articles/view/habtm-searching
> It is a component that deals with custom query.
>
> On Mar 2, 9:22 am, faifas wrote:
> > Hello fellow programmers,
> >
> > is it possibl
Well, you could re-write their function to fit your needs.
Cheers,
Faifas
On Thu, Feb 26, 2009 at 01:02, kryo wrote:
>
> Hello KoPanda,
>
> I'm wondering if you were able to find the reason this error is
> occuring? I am not using CakePHP, but I have a similar problem using
> the mb_ereg_repla
Well, old fashioned way is still working, so it can be simple as this:
For better performance, you should create a div and play with background
positioning, so that users would load both images. That means no waiting
time when you hover with mouse.
Cheers,
Faifas
On Wed, Feb 25, 2009 at 19:02
Hello,
sure thing you can put that in app_controller, so that you do not have
to re-write it all over.
If you are using findAll(); for all pages, you should consider
caching, that really makes the job really good.
Cheers,
Faifas
On Wed, Feb 25, 2009 at 13:59, simon...@terra.com.br
wrote:
>
Why would he use elements if there's Auth->allow(); ? Would save tons
of time and be better in performance.
Cheers,
Faifas
On Mon, Feb 23, 2009 at 00:49, brian wrote:
>
> On Sun, Feb 22, 2009 at 1:26 PM, motoq88 wrote:
>>
>> hi, I am new to cakePHP.
>>
>> I want to know it is possible to onl
Note: I am not sure if this is a correct solution, but you can try this:
$data = $this->paginate('Recipe', array('Recipe.title LIKE' => 'a%',
'Recipe.recipe LIKE' => 'tasty%'));
Hope this helps,
Faifas
On Sat, Feb 21, 2009 at 13:14, himynameisjonas
wrote:
>
> Hi, im trying to do a paginate w
Or if you're not going to use router then:
$html->link('Add User', 'users/add');
Faifas
On Thu, Feb 19, 2009 at 13:14, djiize wrote:
>
> $html->link('Add User', array('controller' => 'users', 'action' =>
> 'add'));
>
> On 19 fév, 12:01, amarradi wrote:
>> Hello together,
>>
>> i have 2 Cont
Thank you for a correction.
Faifas
On Wed, Feb 18, 2009 at 18:34, Mark (Germany)
wrote:
>
> if(!empty($data) {}
> is enough
> as it does not contain anything if there haven not been any found
> records
>
>
> On 18 Feb., 17:06, vikas wrote:
> > Ya you are right.. my problem is solved..
> > tha
Hello, why not trying this:
if(!empty($data) && isset($data[0])) {
echo "yay";
}
else {
echo "No records found, we are really sorry :(";
}
if there are no records then $data should be empty and $data[0] should not
be set, that is how you check if there are any records, or I misunderstood
your
Unless you create a form with Model.id that is filled by edit() function.
You don't need to specify an action then.
Aivaras
On Wed, Feb 18, 2009 at 10:35, RichardAtHome wrote:
>
> Sindey, Marcelo is right. The default action for a form is to post to
> the $controller->add() me
Or even like this:
$this->paginate = array(
'sort' => array('date' > 'desc')
);
$this->set('data', $this->paginate());
Hope this helps,
Faifas
On Sat, Feb 14, 2009 at 03:47, brian wrote:
>
> like this?
>
> var $paginate = array(
> 'sort' => array(
> 'date' => 'DESC',
> 'hours' =>
Hello Paris,
if you would like to make all users go to www. instead of your domain only,
you should change some settings in your apache config.
First, modify your vhost file (if possible):
AllowOverride all
Then all you have to do is edit your .htaccess file which should be in
/path_t
65 matches
Mail list logo