Re: Pagination

2007-05-16 Thread stacey
Check out AD7Six's pagination tutorial... http://bakery.cakephp.org/articles/view/pagination On May 16, 2:20 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > i am working on a php project.. we are using cake php.. > i am new with cake php.. > anybody can help me to do pagination... --~--~-

Re: HABTM Join extra data

2007-05-14 Thread stacey
Like this? http://groups.google.com/group/cake-php/browse_thread/thread/bef70558f7854732/6363603e04fcee68?lnk=st&q=&rnum=10#6363603e04fcee68 Check out the 3rd post by nate. On May 14, 7:07 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > >From what I can see in trac the next release will ha

Re: hasAndBelongsToMany in model with conditions?

2007-05-13 Thread stacey
I played with this for a bit and ended up using bindModel anyway. Yes, it is good practice to keep the associations in the model, but sometimes you need to 'override' the logic. So, I have the general associations in the models, and then use bindModel in my controller actions when I want something

Re: 21 Things You Must Know About CakePHP - Newbie tips

2007-05-13 Thread stacey
I'm using 1.1.13 and it works just fine. I agree with the above post, the SQL error must be coming from somewhere else. Did you check the log to see if 'logtest' made it in there. If so, the error lies elsewhere. On May 13, 6:10 am, "Dr. Tarique Sani" <[EMAIL PROTECTED]> wrote: > On 5/13/07, [EMA

21 Things You Must Know About CakePHP - Newbie tips

2007-05-12 Thread stacey
I found this article rather useful...just thought I'd pass it along. http://cake-php.blogspot.com/2006/09/21-things-you-must-know-about-cakephp.html --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group.

Very strange unbindModel issue...

2007-05-12 Thread stacey
Hi all, I am having a problem unbinding my model. Really, it makes no sense to me at all. I assumed this would be a no brainer, but it just won't work correctly. First off, I have tables 'conditions' and 'remedies', then i have an association table 'conditions_remedies'. Here are the association

Re: Load Javascript on the fly

2007-05-12 Thread stacey
You can call like this from the view: js('customborders/cb'); ?> and you need to include the 'head' helper in your controller: var $helpers = array('Html', 'Head'); // html is always needed On May 12, 12:53 pm, dom <[EMAIL PROTECTED]> wrote: > Hi everybody. > I wonder if it is possible to loa

Re: selectTag

2007-05-12 Thread stacey
It's the 3rd param... selectTag ($fieldName, $optionElements, $selected=null, $selectAttr=array(), $optionAttr=null, $showEmpty=true, $return=false) description of params here: http://api.cakephp.org/class_html_helper.html#dc661e84e1710023d94691fad33f40ec On May 10, 8:08 pm, peterhf <[EMAIL P

Re: is there any chance that using cakephp in apache not support mod_write

2007-05-12 Thread stacey
There is a section covering this in the Blog tutorial: http://manual.cakephp.org/appendix/blog_tutorial Scroll down to Section 5 On May 12, 5:58 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > is there any chance that using cakephp in apache not support > mod_write ? > > thx a lot --~--

Re: HABTM...limiting results

2007-05-11 Thread Stacey
'finderSql' => '', 'foreignKey' => 'remedy_id' ))) ); That'll work for now, but I'd sti

HABTM...limiting results

2007-05-11 Thread Stacey
Hi All, I've been reading the posts and playing around with HABTM. I thought I was close, but I'm noticing that I'm using a lot of hack code to accomplish something I think should be easier. Just thought I'd check here before I make a mess of my whole app. I've got 3 main tables: conditions, rem

Re: Ajax and Pagination...I broke it

2007-05-10 Thread Stacey
Ok, this is probably starting to go off topic. But, after some more playing around, I think it may be some kind of caching issue. It's not just the first page that causes a problem. It seems to be centered around the original link that is loaded in IE. Ex. If I load '/mysite/conditions/?page=3',

Re: Ajax and Pagination...I broke it

2007-05-10 Thread Stacey
to look. On May 10, 11:27 am, AD7six <[EMAIL PROTECTED]> wrote: > On May 10, 4:46 pm, Stacey <[EMAIL PROTECTED]> wrote: > > > > > Hmm, this could be a problem. Why are there two Event.observe for the > > same div with different id's? Would this

Re: Ajax and Pagination...I broke it

2007-05-10 Thread Stacey
Hmm, this could be a problem. Why are there two Event.observe for the same div with different id's? Would this be causing the 'tabcontent1' div not to update? Results: 1-20 of 24<< 1 | 2 Event.observe('link24171', 'click', function(event){ new Ajax.Updater('tabcontent1','/mysite/search/ result

Re: Ajax and Pagination...I broke it

2007-05-10 Thread Stacey
, but I thought I'd clarify. On May 10, 10:02 am, Stacey <[EMAIL PROTECTED]> wrote: > Hi All, > > I have a page which shows search results for three controllers > (conditions, remedies & ratings) in three, separate divs. I finally > got the pagination working correc

Ajax and Pagination...I broke it

2007-05-10 Thread Stacey
Hi All, I have a page which shows search results for three controllers (conditions, remedies & ratings) in three, separate divs. I finally got the pagination working correctly so that each 'paginator' is showing the correct number of pages/results. Then, I decided to use an Ajax update to allow

Re: Database search confusion...

2007-05-08 Thread Stacey
page); } if ($this->params['url']['t'] = 'cats'){ $this->data = $this->Cats->findAll(null, null, $order, $limit, $page); } $this->set('randomId',$random

Re: Database search confusion...

2007-05-08 Thread Stacey
Hi Andy, Thanks for your reply. No, I just thought dog, cat & bird would be easier =) Actually, I posted my code in your wiki article a bit ago, but I wasn't sure if anyone was keeping up with it, so I 're-posted' here after not getting any responses. I'm using Cake 1.1.x.x. I'll check out the l

Database search confusion...

2007-05-08 Thread Stacey
Hi All, I'm hoping to get some insight on a problem I'm having. I'm fairly new to CakePHP and have read every post I can find relating to searches and pagination. (Including AD7Six's wiki entry) Basically, I have a search box on my default.thtml page. I also have a SearchController created which

Re: Accessing model functions from view?

2007-05-06 Thread Stacey
yet have a remedy, because the afterFind adds the calculated field and basically creates a blank row with the one field in it. So, I'm trying to figure out how to avoid this. On May 6, 4:32 am, hepper <[EMAIL PROTECTED]> wrote: > Why not > > if (isset($var)) { > // Do

Accessing model functions from view?

2007-05-05 Thread Stacey
Hi All, I'm having a problem trying to access 'hasField' in a view. I have a calculated field that is only created if there is a value to put in the field. So, I need to first check if the field is available before I do something with it in my view. Is this possible? --~--~-~--~~---

Re: Trouble trying to print this array.

2007-05-05 Thread Stacey
I'm a newbie, but I just ran into this same issue. I believe it should be: instead of: On May 5, 12:10 pm, rockit <[EMAIL PROTECTED]> wrote: > I'm having troubles trying to print this array in the format i need. > let me explain that yes i know how to loop through a basic array. > > As you

Newbie, database and model relations?

2007-05-05 Thread Stacey
Hi All, I'm having a bit of trouble figuring out how to set up my models & controllers with respect to my database. Here is a general overview of what I'm trying to accomplish. I have 2 main tables: conditions & remedies. remedies can belong to several conditions, so i set up another table calle

having a problem getting dbsearch and pagination to work together

2007-05-01 Thread Stacey
hi all, i'm new to cake, using v1.1.x. i have a search on the main page of my app that searches within 'conditions', 'remedies' & (eventually) 'ratings'. i have models/controllers set up for 'conditions', 'remedies', 'ratings' & 'search'. the 'search' has useTable = False. the table associations

Re: Baking without database

2007-04-25 Thread Stacey
you can use the following line in your models to stop them from looking for a database connection: $useTable = false; i don't know if there is a way to globally disable the db. On Apr 25, 12:04 pm, Macon <[EMAIL PROTECTED]> wrote: > Hi all, > > I'm writing a front-end app using Cake relying exc

confused newbie...trying to figure out what problem i need to search on

2007-04-24 Thread Stacey
hi all, i'm trying to implement cakephpbb. i've got the most of it working, except for the admin section of phpbb. when i try to hit the url 'myapp/forums/admin', i get the following error: Missing Method in ForumsController You are seeing this error because the action admin is not defined in

newbie question...creating a 'login' element

2007-04-23 Thread Stacey
hi all, i read a post in here about having a login form built into the default layout. it suggested using an element, so i created one. i'm having one small problem with variables, and i'm hoping someone can help me out. what i'm trying to accomplish, is having the login form in the right column.

Re: How to manage URLs that doesn't require access to Database

2007-04-23 Thread Stacey
ke /cpanel link to any other url, be it / > pages/panel, /somecontroller/someparam, etc. > > On Apr 23, 10:53 am, Stacey <[EMAIL PROTECTED]> wrote: > > > if memory serves me correctly, you need to edit your main .htaccess > > file to include the following: > > >

Re: othAuth...login problem

2007-04-23 Thread Stacey
ok, i'm stupid. i am new to cake, and thought that othAuth somehow handled the field validation. after reading some posts, i realized i need to do it myself. got it working...thanks. On Apr 23, 12:30 pm, Stacey <[EMAIL PROTECTED]> wrote: > hi all, > > cake version: v1.1.1

othAuth...login problem

2007-04-23 Thread Stacey
hi all, cake version: v1.1.13.4450 i've been trying to implement othAuth, and seem to be having a problem with login errors. it seems to be installed properly...if i login with the correct password, it lets me access the pages. but, it is not returning any errors if the login is incorrect or if

Re: How to manage URLs that doesn't require access to Database

2007-04-23 Thread Stacey
if memory serves me correctly, you need to edit your main .htaccess file to include the following: RewriteEngine on RewriteRule^$ app/webroot/[L] RewriteRule(.*) app/webroot/$1 [L] that keeps it from handling the webroot files, and just shows them as is. On Apr 23, 9:35 a

Re: problems with alternative installation and acl.php

2007-03-25 Thread Stacey
still trying to work this out. i've played a bit, and it seems that the 'CONFIG' path is not being set properly. even though i can pass parameters along with the acl.php, it only uses them in certain conditions. but, it is not doing anything with the 'CONFIG' path after is has initially been set i

Re: Not "relative" but "absolute" link is needed.

2007-03-25 Thread Stacey
i'm new to cakephp, but i believe the $html helper is your problem. i think it appends your site to the beginning of the link. just remove the helper bit and put the direct link in. On Mar 25, 11:06 am, "skyblueink" <[EMAIL PROTECTED]> wrote: > The following index.thtml gives a Google link > ofh

problems with alternative installation and acl.php

2007-03-25 Thread Stacey
i followed the alternative installation procedure in the cake manual. everything works well, except i seem to be running into a lot of pathing problems with the command line tools. first, here is my installation structure running on a wamp server... /wamp /cakeapp /mysite

Re: newbie baker question

2007-03-25 Thread Stacey
at trac. On Mar 25, 6:55 am, "mindcharger" <[EMAIL PROTECTED]> wrote: > Hi, > > In fcat that's wierd...it shouldn't be happening... > > Did you defined any rules on inflections.php (it's in $PATH_TO_CAKE\app > \config)? > > Also, what Cake ve

newbie baker question

2007-03-24 Thread Stacey
hi all, i'm playing with bake for the first time using a tutorial i found on the ibm website. after finally getting my paths right, i am confused by one thing. i have a model as follows: app\models\dealer.php array( 'className' => 'Product', 'conditions'=>'', 'order'=>'

Adding a menu? Newbie question...

2007-03-17 Thread Stacey
hi all, i'm new to cakephp. i've read through most of the manual and have completed the blog tutorial. i've got a decent feel for the basic idea, but i'm confused about the best way to implement a menu. i'd like to have the same menu on each page. i've coded the menu, and could put it into the te