Re: $html-checkbox() and database field enum('true','false')

2006-08-16 Thread Brian French
As i understand how the forms and the $_POST/$_GET variables work:If it's a checkbox and it's not checked, it doesnt show up in the $_POST/$_GET (could be wrong, didnt test)You may want to consider either checking if it exists and if it doesnt, then set the value, or you could use a radio button

SOAP

2006-08-18 Thread Brian French
Gotcha, sry if this is off topic, but.. it's friday :-p Awesome review of Snakes on a Plane for anyone interested :-p http://www.aintitcool.com/display.cgi?id=24199 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Re: Template Extension and Smarty.

2006-08-21 Thread Brian French
Is there a way to set it in the config for the app? (i use dreamweaver and want to keep the code highlighting, etc.) mouth wrote: ad 1) create file app/views/test.php with content: ?php require_once 'cake'.DS.'libs'.DS.'view'.DS.'view.php'; class TestView extends View { var $ext =

Re: Template Extension and Smarty.

2006-08-21 Thread Brian French
' and just displays this as regular text. Looking at your example below, does this change the extension to 'index.test'? mouth wrote: Brian French wrote: Is there a way to set it in the config for the app? Just make file app/app_controller.php with this content: ?php class

Re: State List

2006-08-24 Thread Brian French
Here is the list of US states which also include Canadian territories: -- -- Table structure for table `state` -- CREATE TABLE `state` ( `id` char(2) NOT NULL default '', `name` varchar(30) NOT NULL default '', UNIQUE KEY `id` (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='list

Re: State List

2006-08-24 Thread Brian French
Sorry about that. I did it so anyone googling (sry google) for the actual sql for states and countries, they would come across it. Chris Hartjes wrote: That's a cool resource...but next time I wouldn't blast the list with all that SQL. ;)

Re: multiple controllers on 1 page

2006-09-07 Thread Brian French
lt to live with there? Brian French wrote: Im still in the process of wrapping my head around the MVC. I understand the roles of each of the elements. What i am coming across that i cant seem to figure out is how to have multiple elements work on 1 page. Example: Myspace (i know, but go

Re: draggable select box options

2006-09-08 Thread Brian French
http://demo.script.aculo.us/shop codecowboy wrote: I am trying to create a select box that I can drag elements out of and drop into another select box. Does anyone know how to do this? Thank you --~--~-~--~~~---~--~~ You received this message

Model association issue

2006-09-08 Thread Brian French
I am having trouble associating the multiple models i have with each other. I have a 'User' that hasOne 'Fan','Artist','Venue','Promoter'. The 'User' also hasAndBelongsToMany of the same ones (like he can subscribe to them as well as be one/all of them). I am using the scaffolding to view the

Re: Migrating to Cake and Few General Questions

2006-09-08 Thread Brian French
$this-here also seems to hold the info as well. Tony wrote: Yes my IT department is COMPLETELY anal. It's so bad I can't even have a localhost. And yes I meant to say down and not done. LOL! I'm getting this error: Connection to irc://irc.freenode.org reset. Reconnecting in 30 seconds.

Re: Migrating to Cake and Few General Questions

2006-09-08 Thread Brian French
i think you can use something like $this-params[pass] or $this-params[url] set define('DEBUG', 3); in your config/core.php and you can see them printed out when you run the script. Tony wrote: Yes my IT department is COMPLETELY anal. It's so bad I can't even have a localhost. And yes I meant

Re: Model association issue

2006-09-11 Thread Brian French
bump Brian French wrote: I am having trouble associating the multiple models i have with each other. I have a 'User' that hasOne 'Fan','Artist','Venue','Promoter'. The 'User' also hasAndBelongsToMany of the same ones (like he can subscribe to them as well as be one/all of them). I am

Re: multiple controllers on 1 page

2006-09-11 Thread Brian French
to the other thread "Simple question about $this-set") you can do it like this: $someBlock = $this-requestAction('Controllers/_Method',array('foo'='bar')); echo $someBlock; // refering to other thread in groups $this-set('someBlock',$someBlock); anyone, correct me if im wrong. Brian Fren

Re: Model association issue

2006-09-11 Thread Brian French
it, scaffolding is recursive. Thank you for your help, Brian French Chris Hartjes wrote: On 9/8/06, Brian French [EMAIL PROTECTED] wrote: I am having trouble associating the multiple models i have with each other. I have a 'User' that hasOne 'Fan','Artist','Venue','Promoter

Re: Model association issue

2006-09-11 Thread Brian French
I should have elaborated more. When you view that link then go to view a particular user: http://www.myclubbersguide.com/users/view/6 The associations dont seem to be working and i am now getting a php error. (i have a view method in the users controller, but i commented it out so the

Re: Controller redirect

2006-09-11 Thread Brian French
Use could use Sessions. Tim wrote: Is there a way of doing a redirect from my controller which preserves the form data? Thanks. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Cake PHP group. To post to

Re: Model association issue

2006-09-12 Thread Brian French
Could someone help me with this? Brian French wrote: I should have elaborated more. When you view that link then go to view a particular user: http://www.myclubbersguide.com/users/view/6 The associations dont seem to be working and i am now getting a php error. (i have a view method

Re: Model association issue

2006-09-13 Thread Brian French
Thank you! That fixed my problem perfectly! AD7six wrote: Hi Brian, You can´t create 2 associations with the same name. You can't say a user HasOne Venue and User HABTM Venue - if you don´t give you associations unique names the data for both will get mixed together (with confusing results

Pear (Re: wiki parser)

2006-09-14 Thread Brian French
Actually, an extended questions to his... How could you use PEAR in cakephp? (no, im lazy ad didnt do even a basic search) codecowboy wrote: I am looking to give site users the ability to input wiki syntax into form fields. I have been looking for a good wiki text parser and I have only

Re: Copying a db record

2006-09-15 Thread Brian French
'Applicant']); } I didnt test it, but this may help. Brian French [EMAIL PROTECTED] wrote: Thanks for the reply. I tried unsetting the 'id' value, but most strangely, the result is that it changes the original record anyway! I've tried it a dozen times, just to make sure, but that is i

Re: Session problem only with php v 4.x.x

2006-09-15 Thread Brian French
A long time ago i spent hours trying to figure out why i was getting this only to find out the i had a space outside of the php tags (space here ? ?). This is the first thing i look for now when i get a session error like that. You may want to check to see if you have this too. :-p Brian

Re: Copying a db record

2006-09-15 Thread Brian French
what is in the $this-data variable in the copytest function? Is it recursive? I cant remember off the top of my head... does read() return a recursive array? Would using something else like $this-Applicant-findById() possibly fix this? [EMAIL PROTECTED] wrote: Thanks for keeping at it!

Re: Scaffold Error

2006-09-19 Thread Brian French
it should be: class HelpCategoriesController extends AppController { public $name = HelpCategories; var $scaffold; var $useDbConfig = wwa; } where $name doesnt have 'Controller' in the string. it should be named: app/controllers/help_categories_controller.php Syl

Re: Controller-Controller call

2006-09-19 Thread Brian French
Hey could one of you show what the controller would look like when using Photo-Album? Im not sure im following :-p nate wrote: Well, unnecessary use of $uses is just bad form. Granted, Photo-Album takes a little extra typing, but it gives you the context of the object.

Re: Scaffold Error

2006-09-19 Thread Brian French
nate beat me :-p nate wrote: Try this: public $name = HelpCategories; Sorry if the name thing wasn't completely clear. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Cake PHP group. To post to this

Re: Stats

2006-09-22 Thread Brian French
i believe google uses urchin. I think there is an open-source one out there too that is also based on urchin. John David Anderson (_psychic_) wrote: On Sep 21, 2006, at 7:48 AM, [EMAIL PROTECTED] wrote: Hello, i looking for some code that would help me to 1) display "realtime"

Re: Help getting started: creating related records

2006-09-22 Thread Brian French
you could try to maybe bake your view and then modify that form to work how you want it. http://wiki.cakephp.org/docs:bake Andrew wrote: Note: please ignore the line echo $html-hidden('Option/decision_id', 55); That was in there for debugging and never actually did anything.

Re: Conventions on many-to-many recursive table?

2006-09-25 Thread Brian French
I did something similar to this. Check out the hasAndBelongsToMany Sonic Baker wrote: You can call your table and foreign keys anything you want as long as you define them in the association arrays. Maybe you already know this though. Cheers, Sonic

Re: Stats

2006-09-25 Thread Brian French
Another 'Up to the minute' one is visistat.com but they cost something like 100 a year or so. We use them at our job. They are pretty nice and have alot of info. [EMAIL PROTECTED] wrote: I LOVE my Google Analytics account. It is wonderful for me. But, I just came across this for up to the

Re: What Editor Do You Use

2006-09-25 Thread Brian French
RadRails http://www.radrails.org/ would be nice if it could be retrofitted to work with cake seing as how cake is (basically) a rewrite of ROR. BlenderStyle wrote: I'm curious to know what text editor everyone's using. I'm all about free stuff, so I've been using PSPad. It's pretty good, I

Re: Admin, could you please add a subject prefix for this group?

2006-09-26 Thread Brian French
you can also just create a filter in your MUA that looks for any email address coming from 'cake-php@googlegroups.com' and dump it into a sub folder; At least thats what i do. Kjell Bublitz wrote: Heya I just enabled the mail on new message for this group. The subjects not always tell if

Re: Predefined Elements for Layouts

2006-09-26 Thread Brian French
I guess you could always do this in your layout or actual view: ?php echo $this-renderElement('header'); ? Brian French wrote: You may be looking for the layouts. http://manual.cakephp.org/chapter/views [EMAIL PROTECTED] wrote: Hello there fellow bakers! I've finally taken

Re: Predefined Elements for Layouts

2006-09-26 Thread Brian French
You may be looking for the layouts. http://manual.cakephp.org/chapter/views [EMAIL PROTECTED] wrote: Hello there fellow bakers! I've finally taken the plunge into using CakePHP to place some structure into my webdesign work. I am totally new to using frameworks and have been racking my

Bake.php error

2006-09-26 Thread Brian French
I am creating a new project and i am using the bake.php script to do this. I go through the process to create the Model then is asks: Cake test suite not installed. Do you want to bake unit test files anyway? (y/n) I select Yes and it gives me the below error: You can download the Cake test

Re: Route : defaut action for a controller

2006-09-27 Thread Brian French
"_" ( _someMethod(){} ), you shouldn't be able to access it by going to http://localhost/blog/_someMethod right? If you were to create a route to it, then would it that method be accessable via the url? (Not saying i would do it as it doesnt seem very cakey, just curious). Brian French x0r

$this-redirect() after an ajax update

2006-10-23 Thread Brian French
I have the following code which addes a revision. the form is in a div that gets updated when the form is submitted. The form is submitting and saving fine and the div is getting updated when finished, but the problem is, the div is using the default.thtml layout instead of the ajax.thtml

basic Ajax file uploading

2006-10-23 Thread Brian French
I have a form which is submitted via ajax. I have a field in this form which needs to be a file upload. below is the smippet of code. it's only sending me the local location of the file and not the actual file data. how do i get it to properly upload the file? form onsubmit=return false;

Re: basic Ajax file uploading

2006-10-24 Thread Brian French
Thanks alot nate! Is there any example of this anywhere? nate wrote: how do i get it to properly upload the file? You don't. Because of the way the XHR transport layer works, you can't use it to send actual file data. What you *can* do is have the upload form POST to an

Re: $this-redirect() after an ajax update

2006-10-24 Thread Brian French
Thanks alot!! that is exactly what i was looking for... maybe this should be proposed to go into the core? AD7six wrote: Hi Brian, Have a look at how the redirect method is defined (overriden) in the app controller here: http://www.noswad.me.uk/MiBlog/ACLPart1 When you do a redirect, you

AppController's beforeFilter question

2006-10-24 Thread Brian French
When i have an AppController set with the method beforeFilter as well as another normal controller (TasksController). Does the beforeFilter in the TasksController: a. overwrite the AppController's beforeFilter b. run before the AppController's beforeFilter c. run after the AppController's

Re: AppController's beforeFilter question

2006-10-24 Thread Brian French
answer even more simple: http://groups.google.com/group/cake-php/browse_frm/thread/ad985831c21147f2/d142b2ce2fe432b4#d142b2ce2fe432b4 (posed to the list for a searchable reference) Samuel DeVore wrote: you should try a test, and let us know On 10/24/06, Brian French [EMAIL PROTECTED] wrote: Wh

Re: Ajax submission of form affecting navigation of browser

2006-10-27 Thread Brian French
This is how i do my cakephp ajax forms: form onsubmit=return false; ... form data here ... div class=submit ?php echo $ajax-submit('Save', array('url' = '/clients/edit/','update' = 'main','loading'='showSaving();')); ? /div /form hope this can help a little bit.

Re: File Uploads

2006-12-05 Thread Brian French
also, if you want to store the data of the file in the database instead of just in a file, you should also base64_encode(); the data before saving it to either a blog or text datatype. when you want to retreive you do: ?php // header to let the browser know what type of file it is // saee

HABTM Multiple instances of the same row assigned to the related row

2007-03-06 Thread Brian French
I hope my subject line was descriptive enough. I know and unsterstan how the HABTM works pretty well. But i have come across an interesing issue and the googles, they do nothing. In a classic habtm example: (mainly for the noobs) article tag articles can have multiple tags and tags can have

Re: Unique subdomain for each user

2007-03-06 Thread Brian French
I'm dealing with his now. the way i have figured it out is to check the domain in the app_controller.php's beforeFilter() method. Then look up that user info based on the domain and save the user's info in the session. Then in your other controllers you do:

Re: HABTM Multiple instances of the same row assigned to the related row

2007-03-06 Thread Brian French
FYI for anyone interested. ok, well i added the data into the joining table to test an sql query i could from the below url and it worked. Now i need to figure out how to get it to work with the add/edit/delete functions for the Package.

Re: Unique subdomain for each user

2007-03-08 Thread Brian French
(explode('.', $_SERVER['HTTP_HOST']))); then your url can look like username.domain.com/controller/action On Mar 7, 5:52 am, phirschybar [EMAIL PROTECTED] wrote: Brian, is this after you did your apache setup? On Mar 6, 2:01 pm, Brian French [EMAIL PROTECTED] wrote: I'm dealing with his now

Re: Cake Extension and Application Repository

2007-03-15 Thread Brian French
Isn't some of the 'code in the core' already there by taking advantage of the plugin directory? On Mar 14, 1:04 pm, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: what you are proposing is: 1) a structure (outside of the core code) where 3rd party pieces of code can be put 2) you don't