Re: HABTM can't save manually

2011-08-08 Thread mr_robot
hi john thanks for the answer. but i am doing this: $artist['Tag'][1]['artist_id'] = 184287; regards -- 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

Re: Check username availability using jquery

2011-08-08 Thread euromark
exactly this is quite a bad example! use find() and you will have at least a secure query... On 8 Aug., 04:19, Ma'moon phpir...@gmail.com wrote: The only thing that i can see that worth the concern is using  $this -params['form']['username'] and also $this-User-query() , its been clearly

Re: html-css is generating wrong path

2011-08-08 Thread Sathia S
echo $html-css(array('login')); link href=/cake_app/css/login.css type=text/css rel=stylesheet instead of link href=/css/login.css type=text/css rel=stylesheet Because of wrong href css file is not included... and same is happening with images and js files. Can any one tell me what am i

Re: Model not fully loading

2011-08-08 Thread euromark
class Y extends PluginAppController ??? are you sure thats not supposed to be a model? On 7 Aug., 23:07, crouch...@googlemail.com crouch...@googlemail.com wrote: Hello, I am having a weird problem that I am not able to figure out and am not fully able to describe in a brief statement. So

Re: Model not fully loading

2011-08-08 Thread Jens Dittrich
What do you expect to be in Y? Your controller does not call the model for any data nor do you set any data to the object. What do you expect? -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org

How do I process forms via Ajax for a Quiz-like game in CakePHP?

2011-08-08 Thread ujjain
I have written a game in PHP, but I am planning to rewrite it OOP and with CakePHP. Starting it was pretty easy and it seems I wasted a lot of productivity in having written all the queries myself etc. I spent almost 20 hours (wasted much though), while with Cake it could've been done in a few

Email with an attachment

2011-08-08 Thread Ambika Kulkarni
Hello folks, I want to send an email with an attachment. I have used the following snippet but its not working. I have created a file called attach.txt in /app/webroot/ $this-Email-filePaths = array('/www/app/webroot/'); $this-Email-attachments =array('attach.txt'); $this-Email-to =

Re: Email with an attachment

2011-08-08 Thread Sam Sherlock
App::import the vendor library. - S On 8 Aug 2011 13:47, Ambika Kulkarni ambikakulkarn...@gmail.com wrote: Hello folks, I want to send an email with an attachment. I have used the following snippet but its not working. I have created a file called attach.txt in /app/webroot/

Re: Access db from static pages

2011-08-08 Thread euromark
http://stackoverflow.com/questions/6973594/access-the-database-from-static-pages-in-cakephp1-3 On 7 Aug., 16:45, AB arun.u...@gmail.com wrote: Is there any way to access the database from static pages? -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check

Re: HABTM can't save manually

2011-08-08 Thread John Andersen
Yes, I saw that, but the book says you have to do it differently in order to do it automatically. You have to refer to the Artist like this: [code] $artist['Artist']['id'] = 184287; [/code] Observe that you should not just call the save method with the $artist['Tag'] data only, but the full

Re: Login failed. Invalid username or password. - Unable to get Authentication to work

2011-08-08 Thread John Andersen
Please confirm that you password field length is 40 characters? Also, when you saved you user, did you use PHP sha1 function or MySQL function? If the later, try using PHP sha1 function :) Enjoy, John On Aug 7, 10:42 pm, pengin myfakeplastic...@gmail.com wrote: Hello, I have a very basic

Non-Cake form, PagesController and Auth

2011-08-08 Thread BrendonKoz
I'm having a few coworkers experience and report issues with a form they've been submitting under our Auth-secured staff website. Some of the simpler forms were not converted to Cake models and just left as-is under the PagesController. This particular form is a self-submitting/processing form

Where to put my raw mail parser (helper,component,virtual field,..)

2011-08-08 Thread Johkke
For my ticket system we save the raw text from the mail which include the headers to. Since we don't save the body (only found in de raw text) we need to parse the body the whole time. My question is, where do I need to put my mail parser? I'd prefer to use it already on model level (and than

replace emty fields at model or controler level

2011-08-08 Thread Johkke
Is it possible to replace empty fields with an given string (like: 'No subject given') at model or controller level? I really like to keep the view as simple as possible -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site

Re: Login failed. Invalid username or password. - Unable to get Authentication to work

2011-08-08 Thread naidim
If you manually added the user and password to MySQL instead of adding them through Cake then the password isn't getting the proper seed when hashing. In your application set your auth allow to all ( $this-Auth- allow('*'); ) then add your user, then restrict your auth allow as you want. Example

Re: replace emty fields at model or controler level

2011-08-08 Thread Sam Sherlock
in cake 1.3 you can alter $this-data in the beforeFilter of the controller in 2.0 $this-data is read only. writing a cake behaviour for the model may be what your looking for - S On 8 August 2011 19:48, Johkke gybels.j...@gmail.com wrote: Is it possible to replace empty fields with an

Re: HABTM can't save manually

2011-08-08 Thread mr_robot
. no luck adding the whole $artist array. it starts to do weird stuff - adding values from the artist table into the artist_tags table. very confusing. will try build a form but this is all very strange - i assumed relations would be straightforward...? -- Our newest site for the

Re: replace emty fields at model or controler level

2011-08-08 Thread euromark
it is not a good idea to do those things in the model/controller a) what if you don't need most of the modified fields in the end? b) what if you somehow need to know in the view which field was empty in the first place simply do that in the view templates with if (!empty) etc on demand that is

how to check whether a user is already present or not with a name provided!

2011-08-08 Thread neilmenon
i tried and find a very simple way around you guys can check out this link http://www.instatutorial.com/check-username-availability-using-jquery-in-cakephp -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site

Re: Missing Behavior File

2011-08-08 Thread repher
Hey! Same error here. Have you ever found a solution? Bernhard -- View this message in context: http://cakephp.19694.n2.nabble.com/Missing-Behavior-File-tp5988535p6663750.html Sent from the CakePHP mailing list archive at Nabble.com. -- Our newest site for the community: CakePHP Video