Re: Ajax tree view + Ajax form

2009-08-05 Thread Stu
I managed to make this work a while ago, basically I was refreshing only my tree div instead of my content div. Using explode on my id, I had an array containing every level of information I needed. depending on the size of the array it shows more and more of my form. --~--~-~--~~

Ajax tree view + Ajax form

2009-07-29 Thread Stu
Hi everyone, For the past days I have been developing a fully dynamic tree view display to show stats from our database. Basically it looks like this: When clicked, it goes through my controller, gets data based on the id given and generates the next level. Th

Re: Live Validation with jQuery

2009-07-14 Thread Stu
http://stackoverflow.com/questions/209127/jquery-live-validation-plug-ins I'm not sure if there's anything ultimately 'caky' to do here. But have a look at it, I'm sure it could be fairly easy to implement. --~--~-~--~~~---~--~~ You received this message because y

Re: retrieve profile id from session

2009-06-25 Thread Stu
There are a few ways you could get that, just for the hell of it, when you say you used: $user['Profile']['id'], was that in the User's views or the Profile's views. "$user" will only be available to your views to which were passed the variable from the controller $this->set(compact('user')); h

Re: Bootstrap variable

2009-06-22 Thread Stu
I know that you probably set that variable up in Bootstrap for a good reason, but for Conventions over Configuration you should (if possible) set this up in the app_controller: $site_new = '/'.$_SERVER["HTTP_HOST"].'/abc'; $this->set('site_new', $site_new); --~--~-~--~~~-

Re: Bootstrap variable

2009-06-22 Thread Stu
You could try: define('site_new', '/'.$_SERVER["HTTP_HOST"].'/abc'); or, I'm pretty sure you read config vars like this: Configure::read('site_new'); http://book.cakephp.org/view/42/The-Configuration-Class#read-413 Good luck! --~--~-~--~~~---~--~~ You received

Re: Bootstrap variable

2009-06-19 Thread Stu
Well, it seems that your variable isn't defined. Could you post your bootstrap code along with how you're reading your variables in the view? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post t

Re: Bootstrap variable

2009-06-19 Thread Stu
Well, it seems that your variable isn't defined. Could you print your bootstar code along with how you're reading your variables in the view? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post t

Re: Manual database switching

2009-06-18 Thread Stu
Anyone at all on this? --~--~-~--~~~---~--~~ 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, send email to cake-php+unsubscr..

Re: Real noob question

2009-06-18 Thread Stu
You could simply do: $this->set('total', $total); in view: use $total --~--~-~--~~~---~--~~ 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 fr

Manual database switching

2009-06-17 Thread Stu
Hello all, I know this has been asked a few time, but I feel that what I'm trying to do is slightly different. Here's the idea: I want to setup an element containing a form which would allow the user to select the database he wants. Basically I'm going to have two identical databases (Test and

Re: I want to add a parameter to the PaginatorHelper's link, where is the best to add?

2009-06-16 Thread Stu
ps: I think the code you might be looking for is: var $paginate = array('page' => 1); try adding this on top of the app_controller --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this gr

Re: I want to add a parameter to the PaginatorHelper's link, where is the best to add?

2009-06-16 Thread Stu
I usually add them from the app_controller: var $paginate = array(''); http://api.cakephp.org/class/paginator-helper If you want it for a view in particular, you could manually set them there as seen here: http://book.cakephp.org/view/166/Pagination-in-Views Hope this helps Good Luck! --~--~

Re: Logging changes made on "edit" action

2009-06-11 Thread Stu
Never mind, I got it, app->models->behaviors->Logable.php needs to be app->models->behaviors->logable.php an hour wasted for a god damn lower case L. Hehehehe, back to work :D! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Googl

Re: Logging changes made on "edit" action

2009-06-11 Thread Stu
Hey, I'm pretty sure I have set up everything correctly, but this is not working out to well for me. The logable Behavior never gets called... I must say I have never worked with behaviors before and these next few lines may sounds very "noobish" this is how I set it up: --

Re: Logging changes made on "edit" action

2009-06-11 Thread Stu
Thanks Chris, I knew there must of been something already written for this. Will go try it out!! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googleg

Re: Logging changes made on "edit" action

2009-06-10 Thread Stu
ps: I was thinking of adding the logic here: app_model.php -- afterSave($created){ if(!$created){ //logic goes here } } --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. T

Logging changes made on "edit" action

2009-06-10 Thread Stu
Hey all, I need to log changes made to a table on each entries. I'm using cake's 'edit' action. so every time someone edits something, I need to log it to the table which will look like: log - id - table_name - user_id - date/time - modifications I have a pretty good idea on how to code this

Re: How to use find() over 3 models?

2009-06-01 Thread Stu
I'm pretty sure you're looking for -> find('list', array) http://book.cakephp.org/view/810/find-list Hope it helps, Good luck --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group

Re: Form still tries to find action => edit

2009-06-01 Thread Stu
Care to post your controller action? --~--~-~--~~~---~--~~ 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, send email to cake-

Re: set and field of more words

2009-05-27 Thread Stu
"$this->set" uses camel casing so: $post of the month becomes : $postOfTheMonth Hope this helps Good luck --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-

Re: Handling "minute" and "hour" elements in forms

2009-05-27 Thread Stu
ps: The view code should look something like this: echo $form->dateTime('column_name', 'NONE', '12'); The '12' just represents the format, you can either choose '12' (e.g. 11:15 am) or '24' (e.g. 23:15) --~--~-~--~~~---~--~~ You received this message because you

Re: Handling "minute" and "hour" elements in forms

2009-05-27 Thread Stu
Hey, sorry for the late reply. For time data, I still use the $form->dateTime function, there is a parameter that voids the Date value. If you check out the source code, it explains it all. API: http://api.cakephp.org/class/form-helper#method-FormHelperdateTime Source: http://api.cakephp.org/v

Re: Handling "minute" and "hour" elements in forms

2009-05-26 Thread Stu
This is strange, I had to double check in my app to check it out. It is normal for cake to store dateTime information in an array, and it "Should" save it correctly to your MySql table. Could you send your controller and view code? Taking a shot in the dark, I'd think it's because of your colum

Re: Help me

2009-05-25 Thread Stu
Check this one out: http://www.jamesfairhurst.co.uk/ 12 part tutorial with great examples! This is the link to the first part: http://www.jamesfairhurst.co.uk/posts/view/full_cakephp_application_part_1/ --~--~-~--~~~---~--~~ You received this message because you

Re: Database Record deletion problem

2009-05-25 Thread Stu
What happens when you click your link? Does it even redirect somewhere? Throws errors? --~--~-~--~~~---~--~~ 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

Re: Delete Cascade error

2009-05-20 Thread Stu
Alright, I just figured it out... I have to read more about SQL. --~--~-~--~~~---~--~~ 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 th

Delete Cascade error

2009-05-20 Thread Stu
Hey all, Whenever I try to delete a parent row I get an SQL error if it has any child. Query: DELETE FROM `one_programs` WHERE `one_programs`.`id` = 53 Warning (512): SQL Error: 1451: Cannot delete or update a parent row: a foreign key constraint fails (`one/one_ivr_lines`, CONSTRAINT `one_ivr_

Re: Datetime difference

2009-05-19 Thread Stu
Just note that Gabriel's answer is probably the cleanest way to do it, but If you would prefer using a PHP function: http://www.codingforums.com/archive/index.php/t-140522.html Cancer10's code worked great for me: Plus you could tweak this code a bit if you would like seconds, minutes, hours

Re: Login Redirect Problem

2009-05-19 Thread Stu
What happens when you submit? Stays there? Redirects somewhere else? Throws errors (if so, which ones)? In the code you have provided, does "$this->Auth->user()" evaluate to true? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Go

Re: validation: 1 rule for 2 or more fields

2009-05-12 Thread Stu
It wouldn't require much Cake knowledge as much as basic programming knowledge to create a custom validation rule. You would liek that your field is unique, so here is what you could do: add this to your model: function uniqueValidation($data, $field){ $list = $this->Model->find('list' array(

Re: Limit $paginate->numbers()

2009-05-07 Thread Stu
yeah, I actually call it from the app_controller, for I need a page limit of 10 entries globally so mine actually looks like: var $paginate = array('limit'=>10); but, if you want to change it for one controller, yes it would be: $this->paginate = array('limit' => 10); --~--~-~--~~

Re: Limit $paginate->numbers()

2009-05-06 Thread Stu
Wait, did you mean the number of results displayed by page? If so : $paginate = array('limit'=>3); Cheers --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-

Re: Limit $paginate->numbers()

2009-05-06 Thread Stu
I think it's : $paginate = array('numbers'=>3); Cheers --~--~-~--~~~---~--~~ 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,

Re: onChange event for Checkbox

2009-05-06 Thread Stu
Alright, thx Brian, I'll try it out. On May 6, 11:41 am, brian wrote: > On Wed, May 6, 2009 at 11:17 AM, Stu wrote: > > > Hi All, > > > I'd like to add an onChange event for a checkbox, basically this would > > trigger a $form->submit.  The radio Bu

Re: Using special chars in routes

2009-05-06 Thread Stu
Maybe put a backslash '\' before the '+', let me know if this works, I doubt it though... --~--~-~--~~~---~--~~ 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.co

onChange event for Checkbox

2009-05-06 Thread Stu
Hi All, I'd like to add an onChange event for a checkbox, basically this would trigger a $form->submit. The radio Button and Select have the $attributes parameter which allows this but unfortunately for me, it's not the case for the checkbox. I also tried to do it in html: It does execute the

Re: Timesheet app

2009-05-04 Thread Stu
I think Cake wouldn't be to bad for what you have to do. A small App is easily done with cake, even with "rudimentary" PHP skills (Although I must say that a healthy PHP background helps you a lot). --~--~-~--~~~---~--~~ You received this message because you are su

Re: Create a banned word list?

2009-05-04 Thread Stu
I think an "illegal table" would be the cleanest way to do it as you suggested. --~--~-~--~~~---~--~~ 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 unsubs

Translate array with special chars

2009-05-04 Thread Stu
Hello everyone, I have an array used for populating a select (drop down list). I'm filling this array with provinces names. Now I'd like a clean way to translate that array with special chars (e.g. 'Quebec' becomes 'Québec') This is what I have so far: --- add.ctp: ---

Re: Translate array with special chars

2009-05-04 Thread Stu
Alright, I was missing a little something... When building the array, do this: $form->select('province', array( 'Ontario'=>__('Ontario', true), 'Quebec'=>__('Quebec', true), I was forgetting to put the " ,true " after the field. Also after the array I forgot to put this: , null, array('esca

Re: Fatal error: Call to a member function find()

2009-04-30 Thread Stu
Well the key lines here are: Notice (8): Undefined property: Enmn::$Wordtype [APP\controllers \enmns_controller.php, line 27] and Fatal error: Call to a member function find() on a non-object in F: \wamp\www\dict\app\controllers\enmns_controller.php on line 27 My diagnostic shows that you are

Re: validation notEmpty

2009-04-29 Thread Stu
sologroup's method still gave me the same error. Might depend on the version. For those using 1.2.0.7119 RC1, use Yasir's answer: 'names' => array( 'rule'=>VALID_NOT_EMPTY , 'message'=>'Please provide your name.' ) ) --~--~-~--~~~---~--~~ You received this

Re: User Id Question

2009-04-27 Thread Stu
$catalogs = $this->Song->Catalog->find('list', array ('conditions'=> array('Catalog.user_id'=>$this->Session->read ('Auth.User.id'))); Just throwing it out there, I'm assuming you have a user_id field in your Catalog table. Sorry if this doesn't applies. Cheers --~--~-~--~~-

Re: User Id Question

2009-04-27 Thread Stu
$catalogs = $this->Song->Catalog->find('list', array ('Catalog.user_id'=>$this->Session->read('Auth.User.id')); Just throwing it out there, I'm assuming you have a user_id field in your Catalog table. Sorry if this doesn't applies. Cheers --~--~-~--~~~---~--~~ Yo

Re: Debug Ajax

2009-04-27 Thread Stu
A classic case of step retracing might solve this one: - You said it worked before, try changing stuff back to when it did work - You have probably tried this, but try debugging outside your if statement ps: your code snips are identical, might of been intended but I still get confused on what y

Re: cakephp auth component password field always empty why ??

2009-04-24 Thread Stu
Just for the heck of it, try changing your field's name to something else. It's possible that cake handles 'password' fields a particular way. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post

Re: cakephp auth component password field always empty why ??

2009-04-22 Thread Stu
ok, set your debug to 2 (if it's not already) do an exit(); before your redirect in your add function then check your INSERT query at the bottom, see if the password field is empty there. --~--~-~--~~~---~--~~ You received this message because you are subscribed to

Re: Search hasMany Associated Model

2009-04-22 Thread Stu
What code are you trying right now? Seems like you're trying to find data based on an unknown column Usually for hasMany searches I would do this: $this->User->friend->find('foo', $options); --~--~-~--~~~---~--~~ You received this message because you are subscrib

Re: cakephp auth component password field always empty why ??

2009-04-21 Thread Stu
Look in you add.ctp file and make the password field is correctly written. Also it's possible that the word 'password' is reserved for something (I had this happen to me before, I think I was working with Access) you could try changing the name of that field if possible. Are you using MySQL? How

Re: cakephp auth component password field always empty why ??

2009-04-21 Thread Stu
Look in you add.ctp file and make the password field is correctly written. Also it's possible that the word 'password' is reserved for something (I had this happen to me before, I think I was working with Access) you could try changing the name of that field if possible. --~--~-~--~~-

Re: Internationalization in find results

2009-04-17 Thread Stu
Thanks Marcelo, I wasn't using the correct approach for this. Cheers --~--~-~--~~~---~--~~ 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

Re: Quick debugging question

2009-04-16 Thread Stu
I just caught on to what you were saying Brian, just exit(); your controller before the redirect and they print right there... Makes sense... 'slaps forehead'. Thanks man --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Group

Re: Quick debugging question

2009-04-16 Thread Stu
Yeah, it's just because the function went through as normal but the there was 2 columns that were left empty, I pr'd $this->data and everything was fine. My next debugging idea was to check what the query looked like. Even with the debugging at 2, it didn't show the INSERT query, so I thought th

Internationalization in find results

2009-04-16 Thread Stu
Hey guys, I would be surprised to find a solution to this, but here it goes. basically what I want to do is, get a list result from find while still being able to translate the resulting data with : __('word') Didn't catch that now did you? I don't blame you.. here's some code to clear it up:

Re: Problem with paginator

2009-04-15 Thread Stu
the next and prev functions from paginator require an "Options" array as the second argument as you are currently giving it a boolean. You might want to go check out the paginator helper line 189 and 201. Good luck, Stu --~--~-~--~~~---~--~~ You rec

Re: Quick debugging question

2009-04-15 Thread Stu
I got my problem fixed without it, but I'm still curious. My debug is set to ' 2 ', but how do you print the insert query as you're adding $this->data in the database? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Quick debugging question

2009-04-15 Thread Stu
I'm sorry to post this here but I can't seem to google why way out of it. How do you print insert queries from the add function, I just want to see what's going on back there. Thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to t

Re: tinyint returning boolean value

2009-04-07 Thread Stu
Yeah, apparently I haven't searched enough. https://trac.cakephp.org/ticket/1253 http://groups.google.com/group/cake-php/browse_thread/thread/8a67c8f63ed24c48 I'd think that after 3 years this would be fixed, am I the only one finding this behavior strange? --~--~-~--~~~-

Re: $this->set(compact()) not working

2009-04-07 Thread Stu
It's apparently related to the underscore: http://myeasyscripts.com/loudbaking/category/cakephp/ try renaming volume_nodes. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, sen

Re: tinyint returning boolean value

2009-04-07 Thread Stu
Ok, So I managed to get the field switched to a regular Integer and it works fine now. Although I still think it should of worked with the tinyint, anyone care to enlighten the cause? --~--~-~--~~~---~--~~ You received this message because you are subscribed to t

Re: Custom Redirect

2009-04-07 Thread Stu
Hmmm, tricky... I have never used the built in Auth component before, but to the best of my knowledge I don't think anything's wrong in your before filter code. but then I would do this in the view function: if(User logged in Condition){ //your view code else{ $this->render('/deny_page', null,

Re: Custom Redirect

2009-04-07 Thread Stu
Hi Dave, For pages that a user is not allowed to see I use: $this->render('/deny_page', null, false) of course you'll need a 'deny_page' in your views directory. I'm not sure if I do it the 'right' way seeing on I'm using a custom Auth component, but I check whether or not the user has the app

tinyint returning boolean value

2009-04-07 Thread Stu
Hey all, I have this in my add view's form. Basically I have a dropdown list with the week days as they select them it should return me an int value depending on the day, fairly simple. echo $form->select('weekday', array('1'=>'Sunday', '2'=>'Monday',

Re: Search by Selects

2009-04-01 Thread Stu
I'd do a check-up on the check boxes (no pund intended) when calling the search function, get those types into an array. I'm going to assume you are using cake's paginate and then you could do something like this: var $paginate = array( 'conditions'=> array('Music.type' => $arrayWithTheTypesSele

Re: hi

2009-04-01 Thread Stu
Hey, Just a bit confused, when exactly is your data being refreshed? Cake usually handles all the edit functions (add, edit, delete) very easily. Ps: Might want to change your subject to attract more answers. Something like "Issues with the add function" might work better. --~--~-~--~-

Re: Ajax gone after redirect

2009-03-30 Thread Stu
Hahaha, I hear you. I have learned thru the hard way that Ajax is to be used in moderation. Switched from a 100% Ajax navigated site, to about a 5%. I wouldn't say it was a waste of time. My Ajax knowledge grew and I learned a valuable lesson. --~--~-~--~~~---~--~

Re: Ajax gone after redirect

2009-03-26 Thread Stu
This was my first attempt with Ajax, and I think I took it for granted. $html->link would work fine, it's just that for security measures, using Ajax->link would of saved me a bunch of coding. Anyways, I'm gonna limit my Ajax to pagination only, and get some work done. Thx anyways man, I appreci

Re: Ajax gone after redirect

2009-03-26 Thread Stu
I didn't change that option in my links, so by default I guess it sets it to 'asynchronous'. I just tried and set a few of 'em to 'synchronous' and it didn't change anything unfortunately. but ya, that's pretty much what I want to do: > I am thinking you have this, keep me honest here: > > Menu

Re: confused by cake's design

2009-03-26 Thread Stu
You cannot do that from the view, if you need to have information in the view you can do this in the controller: $this->set('variableName', value); then by using $variableName in your view. You can put all your user info in an array and use that in your view. On Mar 26, 9:43 am, jonas wrote:

Re: Ajax gone after redirect

2009-03-26 Thread Stu
Well, it's been a long night and I am soon to give up on this Ajax implementation throughout my application. Let me describe what's going on. We have this web-site where we handle settings, permissions, tickets etc... This web-site all built with cake uses a modified version of the DarkAuth comp

Re: Why is it so hard to find answers on cakephp trouble?

2009-03-26 Thread Stu
if I kept using it without giving any contribution what-so- ever. Long live the fairies brother! On Mar 25, 4:05 pm, AD7six wrote: > > Hi Stu, > > It would be great to also here from you in #cakephp-docs regarding > what and where you found information lacking. > > Alternativel

Re: Why is it so hard to find answers on cakephp trouble?

2009-03-25 Thread Stu
Yes, CakePhP is lacking a great amount of documentation, you're not alone in that boat. I guess the best ways to get to learn it is either completing tutorials or reading the source code. I must agree that reading the documentation on cakephp.org gets somewhat frustrating sometimes, especially i

Re: Ajax gone after redirect

2009-03-25 Thread Stu
Will do, buddy --~--~-~--~~~---~--~~ 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, send email to cake-php+unsubscr...@google

Re: Ajax gone after redirect

2009-03-25 Thread Stu
Oh do I wish it was only that, hehehe. Yeah, I'm starting to think that some routing code is overriding the ajaxHelper behavior. Gonna have to look into that... :( Anyways, thanks for your time Alfredo. --~--~-~--~~~---~--~~ You received this message because you

Re: Ajax gone after redirect

2009-03-25 Thread Stu
Thx for the reply Alfredo I checked it out and his core config file is identical to mine except for this line which was uncommented: Configure::write('Routing.admin', 'admin'); Don't think this has anything to do with it though. When I was running my application on localhost, I hadn't touched

Ajax gone after redirect

2009-03-25 Thread Stu
Hi, Ive recently moved my application to our Linux development server, basically I have this menu populated with Ajax links to get around the application itself. now when I click an Ajax link to go to another page, it works fine, but all my Ajax related objects (links, pagination) will not work

Re: Getting started with Ajax Forms

2009-03-18 Thread Stu
Thanks dave, but I still get this weird error... Tells me I have a missing controller: = Missing Controller Error: Controller could not be found. Error: Create the class Controller below in file: App\controllers\controller.php what is that class you're calli

Re: Getting started with Ajax Forms

2009-03-18 Thread Stu
Using this piece of code will redirect me back to my index function properly but will not save any data: form('add', 'post', array( 'model'=>'Model', 'update'=>'content' ) ); ?> in

Re: Getting started with Ajax Forms

2009-03-18 Thread Stu
Thx for the reply Dave do you use: $ajax->form($options) or do you keep the standard: $form->create('Model')? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email t

Getting started with Ajax Forms

2009-03-18 Thread Stu
Does anyone know a good/reliable source to get started with Ajax forms. The cookbook's version seems incomplete and all the tutorials out there (or the ones I could find) seem to be outdated. I just want the standard most simple way to send a frm using ajax (add/ edit) from the same controller,

Re: Expiry date

2009-03-12 Thread Stu
This would depend on how your login works but to me it would look like this: //Login Controller //get your expriry date $expiryDate = $this->data['UserModel']['expiryDateColumn']; //Get today's date $today = date('Y m d'); if($expiryDate >= $today){ //Rejected //Could throw a flash messag

Re: A list of more productive tutorials?

2009-03-09 Thread Stu
This guy has a 12 part tutorial, explaining everything in details: http://www.jamesfairhurst.co.uk/ Cheers --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-p

Re: Accordion not working for prototype

2009-03-09 Thread Stu
Ummm, looking through your code I've noticed a random "" next to your "effects.js" load. Not sure if it might mess up something. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group,

Re: Accordion

2009-03-09 Thread Stu
Also, when you say: > When I click on a heading it scrolls up and disappears. I mean the whole > section is gonevanished, so the top header that's there is now the > second one. Click that one and it scrolls up and disappears just like the > first. Do you mean it's doing that in Cake or in t

Re: Accordion

2009-03-09 Thread Stu
Hmmm, Are you using the version of prototype that he supplied on his website? Because I noticed if I used the most recent version (1.6), it won't work very smoothly. If you're not already using it, try that (FYI: his version is " 1.5.1.1 " and should weight about 98kb). Other then that I really

Re: Accordion

2009-03-09 Thread Stu
Hmmm, Are you using the version of prototype that he supplied on his website? Because I noticed if I used the most recent version (1.6), it won't work very smoothly. If you're not already using it, try that (fyi: his version should weight about 98kb). Other then that I really don't see how it'

Re: Accordion

2009-03-09 Thread Stu
Did you guys try to make it work in a simple html document? If you copy his whole source code into an html doc, it should work. of course you'll have to change the javascript load: --~--~-~--~~~---~--~~ You received this message because you are subscribed to th

Re: Accordion

2009-03-06 Thread Stu
Not sure if you need the scriptaculous script for anything else, but you don't need it for this. Also you're missing effects.js which is specified on the website. You might wanna take out some of that code too, you don't need all of that, for instance: > var topAccordion

Re: Accordion

2009-03-06 Thread Stu
Hehe, I got this working 2 days ago, Check out his source code, there's more then a few hints in there. But yeah, post your code. So we can see whats going on. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakeP

Re: Converting SQL query to Cake query

2009-03-06 Thread Stu
$topTen = $this->Post->find('list', array( 'fields' => array('Post.id', 'Post.view_count'), 'order' => array('Post.view_count DESC'), 'limit' => 10 ) ); this worked for me. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Gro

Re: Multiple javascripts calls issue

2009-03-03 Thread Stu
Thanks for the reply Doctor, I'm not even sure why I was using both, I didn't know what JQuery was until last week, nor did prototype was until this morning, hehehe. anyways last week I implemented some JQuery U.I. features to my app: http://docs.jquery.com/UI/Accordion and today I wanted to fi

Re: Multiple javascripts calls issue

2009-03-03 Thread Stu
So I think I've come to understand that Jquery and prototype will not work together, does anyone know how to recreate Ajax links using J Query? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post

Multiple javascripts calls issue

2009-03-03 Thread Stu
Ok, today I have decided to add nice ajax links so that my app seem more clean and friendly. Although I'm experiencing something weird while trying to call my javascripts from my 'default' layout: this is what I do: $javascript->link(array('script1', 'script2', 'script3', 'script4')); script 1

Re: Find max(id)

2009-03-02 Thread Stu
I'm not to familiar with MS SQL but you might want to consider using find('first') instead of find('all') as it always returns the first and only result. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group

Re: JQuery UI on cake

2009-02-27 Thread Stu
I works! basically I wasn't calling JQuery the right way. @Brandon: Thanks man, I failed to use common sense and check my source code. Hehe, rookie mistake. Cheers --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "C

Re: Problem in inserting data

2009-02-27 Thread Stu
Best thing would be to post your controller code. --~--~-~--~~~---~--~~ 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, send em

Re: JQuery UI on cake

2009-02-27 Thread Stu
To be a bit more specific, I want to implement this guy: http://docs.jquery.com/UI/Accordion I tried it out in a simple html and it worked fine, but Cake on the other hand does a good job at refuting my JQuery codes. --~--~-~--~~~---~--~~ You received this message

Re: JQuery UI on cake

2009-02-27 Thread Stu
Thanks, but I'm looking for JQuery UI implements. Do I need to use this "scriptaculous" I keep reading everywhere. Also do I need to call in the Ajax helper? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP"

JQuery UI on cake

2009-02-27 Thread Stu
Hi, I have been reading the docs on this, yet I must say I am completely confused as of where to start. Can anyone explain to me how to implement JQuery UI to Cake, or if anyone has a good link to a tutorial, it would be very appreciated. Thanks --~--~-~--~~~---~--~-

  1   2   >