Help getting cake to display a cleaner URL

2008-10-02 Thread kionae
I'm currently attempting to integrate logins within my cakephp 1.2 app and logins for phpBB (using the project at http://cakeforge.org/projects/cakephpbb/ )... the integration itself has all gone splendedly, and I can log in to both my site and the forum through cake without any problems. My

Unit testing in 1.2

2007-12-14 Thread kionae
In attempting to use cakephp 1.2's unit testing suite, I've come upon a problem with a table named Media. What I'm trying to do is test some functions that use data from a table named articles that has a hasAndBelongsToMany relationship to a table named media. The problem is that when I try to

form helper dateTime

2007-09-24 Thread kionae
Is there a way to get dateTime to display a dropdown for seconds? All I can get is hours and minutes. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Cake PHP group. To post to this group, send email to

hasAndBelongsToMany help

2007-09-21 Thread kionae
My issue here is that I have an Article model and I want to be able to associate articles with other articles. It works in as much as I can relate one article to several others, but I need the relationship to go both ways. For example, in the backend of my site, a user associates article 1 with

Re: CakePHP hosting service

2007-09-06 Thread kionae
I use Bluehost (http://www.bluehost.com). I haven't had any trouble using cakephp with them, and they've got great customer service. There may be cheaper hosting plans out there, but Bluehost won't cost you an arm and a leg by any means (if you pre-pay for two years of hosting (their advertised

Re: Replacing data in database

2007-08-24 Thread kionae
Pass the id in a hidden field on your form. Then instead of creating a new record, it will just update the old record with new information. On Aug 23, 3:20 am, Unite [EMAIL PROTECTED] wrote: Hi. Heres the problem. I have a form which returns values and stores them in a database. When a

Re: Images for my models

2007-08-09 Thread kionae
I would create an Image model, and associate it with a Project (i.e. a Project hasMany Images, an Image belongsTo a Project, relating the two based on project id). On Aug 9, 12:51 pm, murtada [EMAIL PROTECTED] wrote: Hi, I am not sure how to best go about doing this. I have a model called

Re: Loop with select and insert not working as expected

2007-08-09 Thread kionae
Have you tried $household_id = $this-Household-field(id, array('id' = $match_userid)); instead? That seems to work for me... On Aug 9, 1:34 pm, phalvrson [EMAIL PROTECTED] wrote: True - I changed to use the buit-in functions - ie save() but I still have the same problem. The problem is

Re: any idea why my save doesn't (?) work - help

2007-08-01 Thread kionae
Try passing the user id along with the user name and password to the save function. If it doesn't know which record to edit, it'll always just create a new one. On Aug 1, 9:40 am, apadzik [EMAIL PROTECTED] wrote: Thank you very much!!:- Maybe there's another function for updating record?

Paginating results of custom queries?

2007-07-30 Thread kionae
Is there any way to just pass an array into 1.2's paginate function and have it paginate the data? Essentially, I have an array that is a set of search results returned by some custom queries and a bit of manipulation. I couldn't generate the results I needed by going through $this-paginate

Re: Need: CakePHP Contact Form Need Please

2007-07-27 Thread kionae
I usually just use the nifty isset() php function, as in: if(isset($this-data['Contact']['email']) { //do some stuff relevant to your ultimate goal } On Jul 27, 2:23 pm, Baz [EMAIL PROTECTED] wrote: I'm a bit unclear here. Since there's not -read() or -findAll(), how do we know that

Re: Pulling data from arrays

2007-07-23 Thread kionae
If I'm understanding you right, you want to add $data[0][0]['c'] and $data[1][0]['c'] to get 40, but what your code is actually doing is adding $data[1][0]['c'] plus $data[1][0]['c'] to give you 25 + 25 rather than 15 + 25. Personally, I'd go with a for loop rather than a foreach, if that's your

Re: Being cached ?

2007-07-13 Thread kionae
Nothing in particular jumps out at me in the code... have you checked to make sure that the form data is being stored in $this-data properly when you submit? No extra or missing arrays within arrays? On Jul 13, 3:05 am, Feris Thia [EMAIL PROTECTED] wrote: On 7/13/07, majna [EMAIL PROTECTED]

Re: Being cached ?

2007-07-13 Thread kionae
autocomplete=off action=?php echo $html-url('/ alumni/edit'); ? I suppose it's worth a shot, if you really think it's something on the client side. On Jul 13, 9:27 am, Feris Thia [EMAIL PROTECTED] wrote: On 7/13/07, kionae [EMAIL PROTECTED] wrote: Nothing in particular jumps out at me

Re: Redirect after authentification?

2007-07-13 Thread kionae
I just store it in a session variable. Any function that requires a user to be logged in gets a line fo code like: $this-Session-write('redirect', '/forums/index'); $this-checkSession(); $this-Session-delete('redirect'); This results in the user either getting redirected to the login page via

Re: Where to store the logic? V or C?

2007-07-12 Thread kionae
Alternatively, you could write up a helper that will not only either grab the appropriate path or fill in the default, but also return it in in a nice little img tag all ready to display in your View. Then you wouldn't have to worry about duplicating the code the next time you need to display an

Re: Save problem

2007-07-12 Thread kionae
Maybe I'm just not following your logic correctly, but why are you calling save in your if statement before you process the information that you're storing in $time_data for the second save? On Jul 12, 2:21 pm, clarkvr [EMAIL PROTECTED] wrote: Hello everybody!! I've an controler that save

Re: Being cached ?

2007-07-12 Thread kionae
Are you sure the database is actually updating, and you're not just being redirected to the list view without seeing an error message? On Jul 12, 10:35 am, Feris Thia [EMAIL PROTECTED] wrote: Hi All, I'm generating controller code view based on models I created. One thing I concern is

Re: form helper dateTime (cake 1.2)

2007-07-12 Thread kionae
Yep. ?php echo $form-datetime('datetime', 'DMY', 24, null, array('maxYear' = '2008', 'minYear' = '2000'), true); ? On Jul 12, 4:00 pm, pete [EMAIL PROTECTED] wrote: hi, is there a way to set the minYear, maxYear for dateTime? ?php echo $form-dateTime('dateTime','DMY',24,null,null); ? i

Re: I need to use frame works

2007-07-11 Thread kionae
frameworks(like sajax,prototype,cakephp)? Regards, Venki On Jul 10, 11:17 pm, kionae [EMAIL PROTECTED] wrote: My recommendation would be first to figure out if you even NEED to use a framework for your projects. Depending on complexity, cakePHP (or any other framework) might be overkill

Re: I need to use frame works

2007-07-10 Thread kionae
My recommendation would be first to figure out if you even NEED to use a framework for your projects. Depending on complexity, cakePHP (or any other framework) might be overkill. If you decide that you do want/need to use one, learn about the concept a bit before you start asking questions.

Re: cake install root page

2007-07-10 Thread kionae
Google cakephp trailing slash http://jeff.loiselles.com/wordpress/?p=22 http://bakery.cakephp.org/articles/view/cakephp-in-a-subdirectory-and-no-trailing-slash

Re: Strange url's

2007-07-09 Thread kionae
I had the exact same problem on my site. I never did figure out exactly WHY it did that, but I did manage to fix it by adding the following to the bootstrap.php file: ini_set(url_rewriter.tags,); ini_set('session.use_trans_sid', false); On Jul 8, 7:55 am, cakedude [EMAIL PROTECTED] wrote:

Re: Safari 3 and Firefox do not understand the urls my cake app is generating...

2007-07-02 Thread kionae
That particular error message in FireFox usually means one of two things... either there's an issue with cookies, or something's off in your server configuration and/or .htaccess files (I got this once when I accidentally deleted an .htaccess file). On Jun 29, 4:51 am, RLR [EMAIL PROTECTED]

Probably a ridiculously easy-to-solve problem with 1.2's paginate

2007-06-25 Thread kionae
The problem is not getting paginate in 1.2 to work, but rather changing the default sort order. Everything is sorted in ascending order on the ID field when the page initially loads, but I need it in descending order on the date field... and for the life of me, I can't find any way to specify

Re: How do I?

2007-06-25 Thread kionae
When I need to do that, I generally just write the posted data to a session then read it back out after the redirect. On Jun 25, 1:47 am, Unite [EMAIL PROTECTED] wrote: Below is my controller. What I want to do is post the data from page2 to page3 using a $this-redirect(); Is this possible?

Re: Probably a ridiculously easy-to-solve problem with 1.2's paginate

2007-06-25 Thread kionae
be the easiest test for now On 6/25/07, kionae [EMAIL PROTECTED] wrote: The problem is not getting paginate in 1.2 to work, but rather changing the default sort order. Everything is sorted in ascending order on the ID field when the page initially loads, but I need it in descending order

Re: Probably a ridiculously easy-to-solve problem with 1.2's paginate

2007-06-25 Thread kionae
[EMAIL PROTECTED] wrote: Where are you calling paginate from? in your controller? if so, just try $this-params['sort'] = 'id'; $this-params['direction'] = 'desc'; before you call $this-paginate(); On 6/25/07, kionae [EMAIL PROTECTED] wrote: The problem with that is that I can't

Re: How to enable a CSV webservice?

2007-05-30 Thread kionae
there first and foremost). Damned if I know why, though. -Kionae On May 29, 3:58 pm, Gonzalo Servat [EMAIL PROTECTED] wrote: On 5/29/07, Howard Glynn [EMAIL PROTECTED] wrote: klonae: just wondering, shouldn't the header() calls be made just before the foreach begins? - Gonzalo

Re: How to enable a CSV webservice?

2007-05-29 Thread kionae
This may or may not help. it's not exactly what you want to do, but I don't have much use for CSV. I needed to be able to allow site managers to generate and download an excel spreasheet of user records from the database. In the controller: function excel() { $this-layout =

Re: params['form'] no longer in cakePHP 1.2

2007-05-17 Thread kionae
Try $this-postConditions($this-data) instead. On May 17, 12:18 pm, Siegfried Hirsch [EMAIL PROTECTED] wrote: Hello, today I have read through the manual (1.1) about the $this-params['form'] which holds all the POST information from a form. Right ? I am using 1.2 4798 and I have setup the

Re: params['form'] no longer in cakePHP 1.2

2007-05-17 Thread kionae
Try $this-postConditions($this-data) instead. On May 17, 12:18 pm, Siegfried Hirsch [EMAIL PROTECTED] wrote: Hello, today I have read through the manual (1.1) about the $this-params['form'] which holds all the POST information from a form. Right ? I am using 1.2 4798 and I have setup the

Re: correct use of flash

2007-05-17 Thread kionae
Are you in production mode or development mode? Flash will only forward you if you've set your site to production in app/config/ core.php (change the line that reads define('DEBUG', 1); to define('DEBUG', 0);). On May 17, 3:48 am, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: hi, Newbee to