From jschwartz at exit445.com Wed Apr 2 16:12:59 2008 From: jschwartz at exit445.com (Jonathan Schwartz) Date: Wed Apr 2 16:13:21 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID Message-ID: Hi Folks, I'm helping a colleague with their first PHP project, but they are using the FMP API. I can't make heads or tails of the API interface. Can someone clue me in how to grab the recid after creating a record? I need it to edit the record later in the session. The existing code for creating the record looks like this: if(!isset($_SESSION['recordcreated'])) { $add_result_add = $customer->newAddCommand('CU_Web_Customer'); $add_result_fields = array('Shipping_Contact_First_Name'=>$_POST['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); foreach($add_result_fields as $key=>$value) { $add_result_add->setField($key,$value); } $add_result_result = $add_result_add->execute(); if(FileMaker::isError($add_result_result)) fmsTrapError($add_result_result,"error.php"); $add_result_row = current($add_result_result->getRecords()); Thanks. Jonathan -- Jonathan Schwartz Exit 445 Group jonathan@exit445.com http://www.exit445.com 415-381-1852 From bob at patin.com Wed Apr 2 16:47:57 2008 From: bob at patin.com (Bob Patin) Date: Wed Apr 2 16:48:18 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: <0205CD1E-0462-4CB1-AF09-A3108D75CE1A@patin.com> Jonathan, I do it by creating a calc field called "recid" and then I grab that; here's some code: newFindAllCommand('posts'); $postsFind->addSortRule('timestamp',1,FILEMAKER_SORT_DESCEND); $posts = $postsFind->execute(); if(FileMaker::isError($posts)){ header ("Location: index.htm"); // this redirects if my FM server doesn't respond for some reason } // this pulls out the records $postsArray=$posts->getRecords(); foreach($postsArray as $post){ $body = html_entity_decode(nl2br($post->getField('post_preview'))); $post_preview = html_entity_decode(nl2br($post- >getField('post_preview'))); $d_created = $post->getField('d_created'); $is_different = $post->getField('is_different'); $recid = $post->getField('recid'); $title = $post->getField('title'); } ?> So as you can see, I'm doing a FINDALL, and then this line $postsArray=$posts->getRecords(); gets the results and puts it into $postsArray, after which you use a FOREACH to cycle thru the found set. As you can see, I retrieve my field called "recid;" I'm sure there's another way to do it, but I like this method, which I also use in FX.php, rather than using the explode command. Just seems easier to me. Hope this helps; I read the Stephen Knight book to get a grip on the API, and it walks you through it very well. I found it very useful, and the code I write is very trim, compared to what FMServer 9 generates in the Site Designer (I forget what it's called). Here's the contents of db.inc.php: Best, Bob Patin Longterm Solutions bob@longtermsolutions.com 615-333-6858 http://www.longtermsolutions.com Member of FileMaker Business Alliance and FileMaker TechNet CONTACT US VIA INSTANT MESSAGING: AIM or iChat: longterm1954 Yahoo: longterm_solutions MSN: tech@longtermsolutions.com ICQ: 159333060 -------------------------- Contact us for FileMaker hosting and programming for all versions of FileMaker PHP ? CDML ? Full email services ? Free DNS hosting ? Colocation ? Consulting On Apr 2, 2008, at 5:12 PM, Jonathan Schwartz wrote: > Hi Folks, > > I'm helping a colleague with their first PHP project, but they are > using the FMP API. > > I can't make heads or tails of the API interface. > > Can someone clue me in how to grab the recid after creating a > record? I need it to edit the record later in the session. > > The existing code for creating the record looks like this: From jschwartz at exit445.com Wed Apr 2 19:10:59 2008 From: jschwartz at exit445.com (Jonathan Schwartz) Date: Wed Apr 2 19:14:03 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <0205CD1E-0462-4CB1-AF09-A3108D75CE1A@patin.com> References: <0205CD1E-0462-4CB1-AF09-A3108D75CE1A@patin.com> Message-ID: Perfect! This is what I needed. Thanks BTW...I'm not liking the API at all, versus fx.php. Perhaps I just need more time.... Jonathan At 5:47 PM -0500 4/2/08, Bob Patin wrote: >Jonathan, > >I do it by creating a calc field called "recid" and then I grab >that; here's some code: > > >require('include/db.inc.php'); // this has my database info in it > >$postsFind = $blogDB -> newFindAllCommand('posts'); >$postsFind->addSortRule('timestamp',1,FILEMAKER_SORT_DESCEND); >$posts = $postsFind->execute(); >if(FileMaker::isError($posts)){ > header ("Location: index.htm"); // this redirects if my FM >server doesn't respond for some reason >} > >// this pulls out the records > >$postsArray=$posts->getRecords(); >foreach($postsArray as $post){ > $body = html_entity_decode(nl2br($post->getField('post_preview'))); > $post_preview = >html_entity_decode(nl2br($post->getField('post_preview'))); > $d_created = $post->getField('d_created'); > $is_different = $post->getField('is_different'); > $recid = $post->getField('recid'); > $title = $post->getField('title'); >} > >?> > >So as you can see, I'm doing a FINDALL, and then this line > >$postsArray=$posts->getRecords(); > >gets the results and puts it into $postsArray, after which you use a >FOREACH to cycle thru the found set. As you can see, I retrieve my >field called "recid;" I'm sure there's another way to do it, but I >like this method, which I also use in FX.php, rather than using the >explode command. Just seems easier to me. > >Hope this helps; I read the Stephen Knight book to get a grip on the >API, and it walks you through it very well. I found it very useful, >and the code I write is very trim, compared to what FMServer 9 >generates in the Site Designer (I forget what it's called). > >Here's the contents of db.inc.php: > >require_once('FileMaker/FileMaker.php'); > >$DB_HOST = 'xxx.xxx.xxx.xxx'; >$DB_NAME = 'dbname'; >$DB_USER = 'username'; >$DB_PASS = 'password'; > >$blogDB = new FileMaker($DB_NAME, $DB_HOST, $DB_USER, $DB_PASS); >?> > > > >Best, > >Bob Patin >Longterm Solutions >bob@longtermsolutions.com >615-333-6858 >http://www.longtermsolutions.com >Member of FileMaker Business Alliance and FileMaker TechNet > > CONTACT US VIA INSTANT MESSAGING: > AIM or iChat: longterm1954 > Yahoo: longterm_solutions > MSN: tech@longtermsolutions.com > ICQ: 159333060 > >-------------------------- >Contact us for FileMaker hosting and programming for all versions of FileMaker >PHP * CDML * Full email services * Free DNS hosting * Colocation * Consulting > > >On Apr 2, 2008, at 5:12 PM, Jonathan Schwartz wrote: > >>Hi Folks, >> >>I'm helping a colleague with their first PHP project, but they are >>using the FMP API. >> >>I can't make heads or tails of the API interface. >> >>Can someone clue me in how to grab the recid after creating a >>record? I need it to edit the record later in the session. >> >>The existing code for creating the record looks like this: > >_______________________________________________ >FX.php_List mailing list >FX.php_List@mail.iviking.org >http://www.iviking.org/mailman/listinfo/fx.php_list -- Jonathan Schwartz Exit 445 Group jonathan@exit445.com http://www.exit445.com 415-381-1852 From bob at patin.com Wed Apr 2 19:22:22 2008 From: bob at patin.com (Bob Patin) Date: Wed Apr 2 19:22:40 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: <0205CD1E-0462-4CB1-AF09-A3108D75CE1A@patin.com> Message-ID: <83C96793-A686-43A7-9CD7-BE6BA983E40D@patin.com> > Perfect! This is what I needed. Thanks My pleasure... > > > BTW...I'm not liking the API at all, versus fx.php. > > Perhaps I just need more time.... I'm not sure I like it either, but it's easy enough to work with. I've only written a few projects in the API though, versus dozens in FX, so it's partly that I'm so used to FX and like it... There are times when we'll need to know it though, at least in my case; I've had clients who wanted their apps written with it, for different reasons... BP From leo at finalresort.org Thu Apr 3 01:22:35 2008 From: leo at finalresort.org (Leo R. Lundgren) Date: Thu Apr 3 01:22:56 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: If you look at the API reference (included with the package, I think. Might be on the server CD), you'll see that for the Filemaker_Record class there is a method called getRecordId(). From the reference (slightly rearranged): getRecordId (line 183) integer getRecordId () Returns the record ID of this object. return: Record ID. A record instance is of course what you get when looping through the records from a result you got from a query to the database. -| 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: > Hi Folks, > > I'm helping a colleague with their first PHP project, but they are > using the FMP API. > > I can't make heads or tails of the API interface. > > Can someone clue me in how to grab the recid after creating a > record? I need it to edit the record later in the session. > > The existing code for creating the record looks like this: > > > if(!isset($_SESSION['recordcreated'])) > { > $add_result_add = $customer->newAddCommand('CU_Web_Customer'); > $add_result_fields = array('Shipping_Contact_First_Name'=>$_POST > ['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=>$_POST > ['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST > ['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=> > $_POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); > foreach($add_result_fields as $key=>$value) { > $add_result_add->setField($key,$value); > } > > $add_result_result = $add_result_add->execute(); > > if(FileMaker::isError($add_result_result)) fmsTrapError > ($add_result_result,"error.php"); > > $add_result_row = current($add_result_result->getRecords()); > > > > > Thanks. > > Jonathan > -- > Jonathan Schwartz > Exit 445 Group > jonathan@exit445.com > http://www.exit445.com > 415-381-1852 > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list -| From ggt667 at gmail.com Thu Apr 3 02:55:20 2008 From: ggt667 at gmail.com (Gjermund Gusland Thorsen) Date: Thu Apr 3 02:55:37 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: Hmm, is it just me, or where do you find arguments for using FileMaker PHP API when you already know FX.php? ggt 2008/4/3, Leo R. Lundgren : > If you look at the API reference (included with the package, I think. Might > be on the server CD), you'll see that for the Filemaker_Record class there > is a method called getRecordId(). From the reference (slightly rearranged): > > getRecordId (line 183) > integer getRecordId () > Returns the record ID of this object. > > return: Record ID. > > A record instance is of course what you get when looping through the > records from a result you got from a query to the database. > > -| > > > 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: > > > > Hi Folks, > > > > I'm helping a colleague with their first PHP project, but they are using > the FMP API. > > > > I can't make heads or tails of the API interface. > > > > Can someone clue me in how to grab the recid after creating a record? I > need it to edit the record later in the session. > > > > The existing code for creating the record looks like this: > > > > > > if(!isset($_SESSION['recordcreated'])) > > { > > $add_result_add = > $customer->newAddCommand('CU_Web_Customer'); > > $add_result_fields = > array('Shipping_Contact_First_Name'=>$_POST['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); > > foreach($add_result_fields as $key=>$value) { > > $add_result_add->setField($key,$value); > > } > > > > $add_result_result = $add_result_add->execute(); > > > > if(FileMaker::isError($add_result_result)) > fmsTrapError($add_result_result,"error.php"); > > > > $add_result_row = > current($add_result_result->getRecords()); > > > > > > > > > > Thanks. > > > > Jonathan > > -- > > Jonathan Schwartz > > Exit 445 Group > > jonathan@exit445.com > > http://www.exit445.com > > 415-381-1852 > > _______________________________________________ > > FX.php_List mailing list > > FX.php_List@mail.iviking.org > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > -| > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From leo at finalresort.org Thu Apr 3 02:58:06 2008 From: leo at finalresort.org (Leo R. Lundgren) Date: Thu Apr 3 02:58:22 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: I don't really know FX.php :) 3 apr 2008 kl. 10.55 skrev Gjermund Gusland Thorsen: > Hmm, is it just me, or where do you find arguments for using FileMaker > PHP API when you already know FX.php? > > ggt > > 2008/4/3, Leo R. Lundgren : >> If you look at the API reference (included with the package, I >> think. Might >> be on the server CD), you'll see that for the Filemaker_Record >> class there >> is a method called getRecordId(). From the reference (slightly >> rearranged): >> >> getRecordId (line 183) >> integer getRecordId () >> Returns the record ID of this object. >> >> return: Record ID. >> >> A record instance is of course what you get when looping through the >> records from a result you got from a query to the database. >> >> -| >> >> >> 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: >> >> >>> Hi Folks, >>> >>> I'm helping a colleague with their first PHP project, but they >>> are using >> the FMP API. >>> >>> I can't make heads or tails of the API interface. >>> >>> Can someone clue me in how to grab the recid after creating a >>> record? I >> need it to edit the record later in the session. >>> >>> The existing code for creating the record looks like this: >>> >>> >>> if(!isset($_SESSION['recordcreated'])) >>> { >>> $add_result_add = >> $customer->newAddCommand('CU_Web_Customer'); >>> $add_result_fields = >> array('Shipping_Contact_First_Name'=>$_POST >> ['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=> >> $_POST['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST >> ['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=> >> $_POST['Promotion_Code'],'Shipping_Email'=>$_POST >> ['Shipping_Email'],); >>> foreach($add_result_fields as $key=>$value) { >>> $add_result_add->setField($key,$value); >>> } >>> >>> $add_result_result = $add_result_add->execute(); >>> >>> if(FileMaker::isError($add_result_result)) >> fmsTrapError($add_result_result,"error.php"); >>> >>> $add_result_row = >> current($add_result_result->getRecords()); >>> >>> >>> >>> >>> Thanks. >>> >>> Jonathan >>> -- >>> Jonathan Schwartz >>> Exit 445 Group >>> jonathan@exit445.com >>> http://www.exit445.com >>> 415-381-1852 >>> _______________________________________________ >>> FX.php_List mailing list >>> FX.php_List@mail.iviking.org >>> http://www.iviking.org/mailman/listinfo/fx.php_list >>> >> >> >> -| >> >> >> _______________________________________________ >> FX.php_List mailing list >> FX.php_List@mail.iviking.org >> http://www.iviking.org/mailman/listinfo/fx.php_list >> > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list -| From dbengston at preservationstudio.com Thu Apr 3 07:48:53 2008 From: dbengston at preservationstudio.com (Dale Bengston) Date: Thu Apr 3 07:49:56 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: Sometimes the client makes that choice. On Apr 3, 2008, at 3:55 AM, Gjermund Gusland Thorsen wrote: > Hmm, is it just me, or where do you find arguments for using FileMaker > PHP API when you already know FX.php? > > ggt > > 2008/4/3, Leo R. Lundgren : >> If you look at the API reference (included with the package, I >> think. Might >> be on the server CD), you'll see that for the Filemaker_Record >> class there >> is a method called getRecordId(). From the reference (slightly >> rearranged): >> >> getRecordId (line 183) >> integer getRecordId () >> Returns the record ID of this object. >> >> return: Record ID. >> >> A record instance is of course what you get when looping through the >> records from a result you got from a query to the database. >> >> -| >> >> >> 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: >> >> >>> Hi Folks, >>> >>> I'm helping a colleague with their first PHP project, but they are >>> using >> the FMP API. >>> >>> I can't make heads or tails of the API interface. >>> >>> Can someone clue me in how to grab the recid after creating a >>> record? I >> need it to edit the record later in the session. >>> >>> The existing code for creating the record looks like this: >>> >>> >>> if(!isset($_SESSION['recordcreated'])) >>> { >>> $add_result_add = >> $customer->newAddCommand('CU_Web_Customer'); >>> $add_result_fields = >> array('Shipping_Contact_First_Name'=> >> $_POST['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=> >> $_POST['Shipping_Contact_Last_Name'],'Login_Name'=> >> $_POST['Login_Name'],'Password'=> >> $_POST['Password'],'Promotion_Code'=> >> $_POST['Promotion_Code'],'Shipping_Email'=> >> $_POST['Shipping_Email'],); >>> foreach($add_result_fields as $key=>$value) { >>> $add_result_add->setField($key,$value); >>> } >>> >>> $add_result_result = $add_result_add->execute(); >>> >>> if(FileMaker::isError($add_result_result)) >> fmsTrapError($add_result_result,"error.php"); >>> >>> $add_result_row = >> current($add_result_result->getRecords()); >>> >>> >>> >>> >>> Thanks. >>> >>> Jonathan >>> -- >>> Jonathan Schwartz >>> Exit 445 Group >>> jonathan@exit445.com >>> http://www.exit445.com >>> 415-381-1852 >>> _______________________________________________ >>> FX.php_List mailing list >>> FX.php_List@mail.iviking.org >>> http://www.iviking.org/mailman/listinfo/fx.php_list >>> >> >> >> -| >> >> >> _______________________________________________ >> FX.php_List mailing list >> FX.php_List@mail.iviking.org >> http://www.iviking.org/mailman/listinfo/fx.php_list >> > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list From ggt667 at gmail.com Thu Apr 3 08:35:01 2008 From: ggt667 at gmail.com (Gjermund Gusland Thorsen) Date: Thu Apr 3 08:35:25 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: On which conditions? 2008/4/3, Dale Bengston : > Sometimes the client makes that choice. > > > On Apr 3, 2008, at 3:55 AM, Gjermund Gusland Thorsen wrote: > > > > Hmm, is it just me, or where do you find arguments for using FileMaker > > PHP API when you already know FX.php? > > > > ggt > > > > 2008/4/3, Leo R. Lundgren : > > > > > If you look at the API reference (included with the package, I think. > Might > > > be on the server CD), you'll see that for the Filemaker_Record class > there > > > is a method called getRecordId(). From the reference (slightly > rearranged): > > > > > > getRecordId (line 183) > > > integer getRecordId () > > > Returns the record ID of this object. > > > > > > return: Record ID. > > > > > > A record instance is of course what you get when looping through the > > > records from a result you got from a query to the database. > > > > > > -| > > > > > > > > > 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: > > > > > > > > > > > > > Hi Folks, > > > > > > > > I'm helping a colleague with their first PHP project, but they are > using > > > > > > > the FMP API. > > > > > > > > > > > I can't make heads or tails of the API interface. > > > > > > > > Can someone clue me in how to grab the recid after creating a record? > I > > > > > > > need it to edit the record later in the session. > > > > > > > > > > > The existing code for creating the record looks like this: > > > > > > > > > > > > if(!isset($_SESSION['recordcreated'])) > > > > { > > > > $add_result_add = > > > > > > > $customer->newAddCommand('CU_Web_Customer'); > > > > > > > $add_result_fields = > > > > > > > > array('Shipping_Contact_First_Name'=>$_POST['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); > > > > > > > foreach($add_result_fields as $key=>$value) { > > > > $add_result_add->setField($key,$value); > > > > } > > > > > > > > $add_result_result = $add_result_add->execute(); > > > > > > > > if(FileMaker::isError($add_result_result)) > > > > > > > fmsTrapError($add_result_result,"error.php"); > > > > > > > > > > > $add_result_row = > > > > > > > current($add_result_result->getRecords()); > > > > > > > > > > > > > > > > > > > > > > > Thanks. > > > > > > > > Jonathan > > > > -- > > > > Jonathan Schwartz > > > > Exit 445 Group > > > > jonathan@exit445.com > > > > http://www.exit445.com > > > > 415-381-1852 > > > > _______________________________________________ > > > > FX.php_List mailing list > > > > FX.php_List@mail.iviking.org > > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > > > > > > > > > > -| > > > > > > > > > _______________________________________________ > > > FX.php_List mailing list > > > FX.php_List@mail.iviking.org > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > _______________________________________________ > > FX.php_List mailing list > > FX.php_List@mail.iviking.org > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From steve at bluecrocodile.co.nz Thu Apr 3 08:42:11 2008 From: steve at bluecrocodile.co.nz (Steve Winter) Date: Thu Apr 3 08:43:32 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> On the condition that they are the client, and they say 'I want you to build me a web interface which uses the PHP API built in to FileMaker'. Even if you tell them there are good reasons why they should use FX, still some clients will say, use the API... in my experience this is usually because they have limited knowledge, but see the API as an 'official' part of FMP, where as FX is an add-on, which they see as unnecessary... My 2p worth ;-) Cheers Steve -----Original Message----- From: fx.php_list-bounces@mail.iviking.org [mailto:fx.php_list-bounces@mail.iviking.org] On Behalf Of Gjermund Gusland Thorsen Sent: 03 April 2008 15:35 To: FX.php Discussion List Subject: Re: [FX.php List] [OFF] API Equivalent for Grabbing RECID On which conditions? 2008/4/3, Dale Bengston : > Sometimes the client makes that choice. > > > On Apr 3, 2008, at 3:55 AM, Gjermund Gusland Thorsen wrote: > > > > Hmm, is it just me, or where do you find arguments for using FileMaker > > PHP API when you already know FX.php? > > > > ggt > > > > 2008/4/3, Leo R. Lundgren : > > > > > If you look at the API reference (included with the package, I think. > Might > > > be on the server CD), you'll see that for the Filemaker_Record class > there > > > is a method called getRecordId(). From the reference (slightly > rearranged): > > > > > > getRecordId (line 183) > > > integer getRecordId () > > > Returns the record ID of this object. > > > > > > return: Record ID. > > > > > > A record instance is of course what you get when looping through the > > > records from a result you got from a query to the database. > > > > > > -| > > > > > > > > > 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: > > > > > > > > > > > > > Hi Folks, > > > > > > > > I'm helping a colleague with their first PHP project, but they are > using > > > > > > > the FMP API. > > > > > > > > > > > I can't make heads or tails of the API interface. > > > > > > > > Can someone clue me in how to grab the recid after creating a record? > I > > > > > > > need it to edit the record later in the session. > > > > > > > > > > > The existing code for creating the record looks like this: > > > > > > > > > > > > if(!isset($_SESSION['recordcreated'])) > > > > { > > > > $add_result_add = > > > > > > > $customer->newAddCommand('CU_Web_Customer'); > > > > > > > $add_result_fields = > > > > > > > > array('Shipping_Contact_First_Name'=>$_POST['Shipping_Contact_First_Name'],' Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Nam e'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_ POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); > > > > > > > foreach($add_result_fields as $key=>$value) { > > > > $add_result_add->setField($key,$value); > > > > } > > > > > > > > $add_result_result = $add_result_add->execute(); > > > > > > > > if(FileMaker::isError($add_result_result)) > > > > > > > fmsTrapError($add_result_result,"error.php"); > > > > > > > > > > > $add_result_row = > > > > > > > current($add_result_result->getRecords()); > > > > > > > > > > > > > > > > > > > > > > > Thanks. > > > > > > > > Jonathan > > > > -- > > > > Jonathan Schwartz > > > > Exit 445 Group > > > > jonathan@exit445.com > > > > http://www.exit445.com > > > > 415-381-1852 > > > > _______________________________________________ > > > > FX.php_List mailing list > > > > FX.php_List@mail.iviking.org > > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > > > > > > > > > > -| > > > > > > > > > _______________________________________________ > > > FX.php_List mailing list > > > FX.php_List@mail.iviking.org > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > _______________________________________________ > > FX.php_List mailing list > > FX.php_List@mail.iviking.org > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > _______________________________________________ FX.php_List mailing list FX.php_List@mail.iviking.org http://www.iviking.org/mailman/listinfo/fx.php_list From ggt667 at gmail.com Thu Apr 3 08:46:47 2008 From: ggt667 at gmail.com (Gjermund Gusland Thorsen) Date: Thu Apr 3 08:47:07 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> Message-ID: When shrinks receive clients that attempt to shoot themselves in the food, it's OK? 2008/4/3, Steve Winter : > On the condition that they are the client, and they say 'I want you to build > me a web interface which uses the PHP API built in to FileMaker'. > > Even if you tell them there are good reasons why they should use FX, still > some clients will say, use the API... in my experience this is usually > because they have limited knowledge, but see the API as an 'official' part > of FMP, where as FX is an add-on, which they see as unnecessary... > > My 2p worth ;-) > > Cheers > > Steve > > > -----Original Message----- > From: fx.php_list-bounces@mail.iviking.org > [mailto:fx.php_list-bounces@mail.iviking.org] On Behalf Of Gjermund Gusland > Thorsen > Sent: 03 April 2008 15:35 > To: FX.php Discussion List > Subject: Re: [FX.php List] [OFF] API Equivalent for Grabbing RECID > > On which conditions? > > 2008/4/3, Dale Bengston : > > Sometimes the client makes that choice. > > > > > > On Apr 3, 2008, at 3:55 AM, Gjermund Gusland Thorsen wrote: > > > > > > > Hmm, is it just me, or where do you find arguments for using FileMaker > > > PHP API when you already know FX.php? > > > > > > ggt > > > > > > 2008/4/3, Leo R. Lundgren : > > > > > > > If you look at the API reference (included with the package, I think. > > Might > > > > be on the server CD), you'll see that for the Filemaker_Record class > > there > > > > is a method called getRecordId(). From the reference (slightly > > rearranged): > > > > > > > > getRecordId (line 183) > > > > integer getRecordId () > > > > Returns the record ID of this object. > > > > > > > > return: Record ID. > > > > > > > > A record instance is of course what you get when looping through the > > > > records from a result you got from a query to the database. > > > > > > > > -| > > > > > > > > > > > > 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: > > > > > > > > > > > > > > > > > Hi Folks, > > > > > > > > > > I'm helping a colleague with their first PHP project, but they are > > using > > > > > > > > > the FMP API. > > > > > > > > > > > > > > I can't make heads or tails of the API interface. > > > > > > > > > > Can someone clue me in how to grab the recid after creating a > record? > > I > > > > > > > > > need it to edit the record later in the session. > > > > > > > > > > > > > > The existing code for creating the record looks like this: > > > > > > > > > > > > > > > if(!isset($_SESSION['recordcreated'])) > > > > > { > > > > > $add_result_add = > > > > > > > > > $customer->newAddCommand('CU_Web_Customer'); > > > > > > > > > $add_result_fields = > > > > > > > > > > > > array('Shipping_Contact_First_Name'=>$_POST['Shipping_Contact_First_Name'],' > Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Nam > e'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_ > POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); > > > > > > > > > foreach($add_result_fields as $key=>$value) { > > > > > $add_result_add->setField($key,$value); > > > > > } > > > > > > > > > > $add_result_result = $add_result_add->execute(); > > > > > > > > > > if(FileMaker::isError($add_result_result)) > > > > > > > > > fmsTrapError($add_result_result,"error.php"); > > > > > > > > > > > > > > $add_result_row = > > > > > > > > > current($add_result_result->getRecords()); > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Thanks. > > > > > > > > > > Jonathan > > > > > -- > > > > > Jonathan Schwartz > > > > > Exit 445 Group > > > > > jonathan@exit445.com > > > > > http://www.exit445.com > > > > > 415-381-1852 > > > > > _______________________________________________ > > > > > FX.php_List mailing list > > > > > FX.php_List@mail.iviking.org > > > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > > > > > > > > > > > > > > > -| > > > > > > > > > > > > _______________________________________________ > > > > FX.php_List mailing list > > > > FX.php_List@mail.iviking.org > > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > > > > _______________________________________________ > > > FX.php_List mailing list > > > FX.php_List@mail.iviking.org > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > _______________________________________________ > > FX.php_List mailing list > > FX.php_List@mail.iviking.org > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From steve at bluecrocodile.co.nz Thu Apr 3 08:49:14 2008 From: steve at bluecrocodile.co.nz (Steve Winter) Date: Thu Apr 3 08:50:22 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> Message-ID: <8B8B4B43C4674D9DB256C547C7CA7446@matatirosolutions.co.uk> Some days, not matter what a psychologist or psychiatrist does, people still commit suicide... ;-) -----Original Message----- From: fx.php_list-bounces@mail.iviking.org [mailto:fx.php_list-bounces@mail.iviking.org] On Behalf Of Gjermund Gusland Thorsen Sent: 03 April 2008 15:47 To: FX.php Discussion List Subject: Re: [FX.php List] [OFF] API Equivalent for Grabbing RECID When shrinks receive clients that attempt to shoot themselves in the food, it's OK? 2008/4/3, Steve Winter : > On the condition that they are the client, and they say 'I want you to build > me a web interface which uses the PHP API built in to FileMaker'. > > Even if you tell them there are good reasons why they should use FX, still > some clients will say, use the API... in my experience this is usually > because they have limited knowledge, but see the API as an 'official' part > of FMP, where as FX is an add-on, which they see as unnecessary... > > My 2p worth ;-) > > Cheers > > Steve > > > -----Original Message----- > From: fx.php_list-bounces@mail.iviking.org > [mailto:fx.php_list-bounces@mail.iviking.org] On Behalf Of Gjermund Gusland > Thorsen > Sent: 03 April 2008 15:35 > To: FX.php Discussion List > Subject: Re: [FX.php List] [OFF] API Equivalent for Grabbing RECID > > On which conditions? > > 2008/4/3, Dale Bengston : > > Sometimes the client makes that choice. > > > > > > On Apr 3, 2008, at 3:55 AM, Gjermund Gusland Thorsen wrote: > > > > > > > Hmm, is it just me, or where do you find arguments for using FileMaker > > > PHP API when you already know FX.php? > > > > > > ggt > > > > > > 2008/4/3, Leo R. Lundgren : > > > > > > > If you look at the API reference (included with the package, I think. > > Might > > > > be on the server CD), you'll see that for the Filemaker_Record class > > there > > > > is a method called getRecordId(). From the reference (slightly > > rearranged): > > > > > > > > getRecordId (line 183) > > > > integer getRecordId () > > > > Returns the record ID of this object. > > > > > > > > return: Record ID. > > > > > > > > A record instance is of course what you get when looping through the > > > > records from a result you got from a query to the database. > > > > > > > > -| > > > > > > > > > > > > 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: > > > > > > > > > > > > > > > > > Hi Folks, > > > > > > > > > > I'm helping a colleague with their first PHP project, but they are > > using > > > > > > > > > the FMP API. > > > > > > > > > > > > > > I can't make heads or tails of the API interface. > > > > > > > > > > Can someone clue me in how to grab the recid after creating a > record? > > I > > > > > > > > > need it to edit the record later in the session. > > > > > > > > > > > > > > The existing code for creating the record looks like this: > > > > > > > > > > > > > > > if(!isset($_SESSION['recordcreated'])) > > > > > { > > > > > $add_result_add = > > > > > > > > > $customer->newAddCommand('CU_Web_Customer'); > > > > > > > > > $add_result_fields = > > > > > > > > > > > > array('Shipping_Contact_First_Name'=>$_POST['Shipping_Contact_First_Name'],' > Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Nam > e'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_ > POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); > > > > > > > > > foreach($add_result_fields as $key=>$value) { > > > > > $add_result_add->setField($key,$value); > > > > > } > > > > > > > > > > $add_result_result = $add_result_add->execute(); > > > > > > > > > > if(FileMaker::isError($add_result_result)) > > > > > > > > > fmsTrapError($add_result_result,"error.php"); > > > > > > > > > > > > > > $add_result_row = > > > > > > > > > current($add_result_result->getRecords()); > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Thanks. > > > > > > > > > > Jonathan > > > > > -- > > > > > Jonathan Schwartz > > > > > Exit 445 Group > > > > > jonathan@exit445.com > > > > > http://www.exit445.com > > > > > 415-381-1852 > > > > > _______________________________________________ > > > > > FX.php_List mailing list > > > > > FX.php_List@mail.iviking.org > > > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > > > > > > > > > > > > > > > -| > > > > > > > > > > > > _______________________________________________ > > > > FX.php_List mailing list > > > > FX.php_List@mail.iviking.org > > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > > > > _______________________________________________ > > > FX.php_List mailing list > > > FX.php_List@mail.iviking.org > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > _______________________________________________ > > FX.php_List mailing list > > FX.php_List@mail.iviking.org > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > _______________________________________________ FX.php_List mailing list FX.php_List@mail.iviking.org http://www.iviking.org/mailman/listinfo/fx.php_list From ggt667 at gmail.com Thu Apr 3 08:59:45 2008 From: ggt667 at gmail.com (Gjermund Gusland Thorsen) Date: Thu Apr 3 09:00:11 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <8B8B4B43C4674D9DB256C547C7CA7446@matatirosolutions.co.uk> References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8B8B4B43C4674D9DB256C547C7CA7446@matatirosolutions.co.uk> Message-ID: OK, then I see what the reason is. Thank you, ggt 2008/4/3, Steve Winter : > Some days, not matter what a psychologist or psychiatrist does, people still > commit suicide... ;-) > > > -----Original Message----- > From: fx.php_list-bounces@mail.iviking.org > [mailto:fx.php_list-bounces@mail.iviking.org] On Behalf Of Gjermund Gusland > Thorsen > > Sent: 03 April 2008 15:47 > To: FX.php Discussion List > Subject: Re: [FX.php List] [OFF] API Equivalent for Grabbing RECID > > When shrinks receive clients that attempt to shoot themselves in the food, > it's OK? > > 2008/4/3, Steve Winter : > > On the condition that they are the client, and they say 'I want you to > build > > me a web interface which uses the PHP API built in to FileMaker'. > > > > Even if you tell them there are good reasons why they should use FX, > still > > some clients will say, use the API... in my experience this is usually > > because they have limited knowledge, but see the API as an 'official' > part > > of FMP, where as FX is an add-on, which they see as unnecessary... > > > > My 2p worth ;-) > > > > Cheers > > > > Steve > > > > > > -----Original Message----- > > From: fx.php_list-bounces@mail.iviking.org > > [mailto:fx.php_list-bounces@mail.iviking.org] On Behalf Of Gjermund > Gusland > > Thorsen > > Sent: 03 April 2008 15:35 > > To: FX.php Discussion List > > Subject: Re: [FX.php List] [OFF] API Equivalent for Grabbing RECID > > > > On which conditions? > > > > 2008/4/3, Dale Bengston : > > > Sometimes the client makes that choice. > > > > > > > > > On Apr 3, 2008, at 3:55 AM, Gjermund Gusland Thorsen wrote: > > > > > > > > > > Hmm, is it just me, or where do you find arguments for using > FileMaker > > > > PHP API when you already know FX.php? > > > > > > > > ggt > > > > > > > > 2008/4/3, Leo R. Lundgren : > > > > > > > > > If you look at the API reference (included with the package, I > think. > > > Might > > > > > be on the server CD), you'll see that for the Filemaker_Record > class > > > there > > > > > is a method called getRecordId(). From the reference (slightly > > > rearranged): > > > > > > > > > > getRecordId (line 183) > > > > > integer getRecordId () > > > > > Returns the record ID of this object. > > > > > > > > > > return: Record ID. > > > > > > > > > > A record instance is of course what you get when looping through > the > > > > > records from a result you got from a query to the database. > > > > > > > > > > -| > > > > > > > > > > > > > > > 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: > > > > > > > > > > > > > > > > > > > > > Hi Folks, > > > > > > > > > > > > I'm helping a colleague with their first PHP project, but they > are > > > using > > > > > > > > > > > the FMP API. > > > > > > > > > > > > > > > > > I can't make heads or tails of the API interface. > > > > > > > > > > > > Can someone clue me in how to grab the recid after creating a > > record? > > > I > > > > > > > > > > > need it to edit the record later in the session. > > > > > > > > > > > > > > > > > The existing code for creating the record looks like this: > > > > > > > > > > > > > > > > > > if(!isset($_SESSION['recordcreated'])) > > > > > > { > > > > > > $add_result_add = > > > > > > > > > > > $customer->newAddCommand('CU_Web_Customer'); > > > > > > > > > > > $add_result_fields = > > > > > > > > > > > > > > > > > array('Shipping_Contact_First_Name'=>$_POST['Shipping_Contact_First_Name'],' > > > Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Nam > > > e'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_ > > POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); > > > > > > > > > > > foreach($add_result_fields as $key=>$value) { > > > > > > $add_result_add->setField($key,$value); > > > > > > } > > > > > > > > > > > > $add_result_result = $add_result_add->execute(); > > > > > > > > > > > > if(FileMaker::isError($add_result_result)) > > > > > > > > > > > fmsTrapError($add_result_result,"error.php"); > > > > > > > > > > > > > > > > > $add_result_row = > > > > > > > > > > > current($add_result_result->getRecords()); > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Thanks. > > > > > > > > > > > > Jonathan > > > > > > -- > > > > > > Jonathan Schwartz > > > > > > Exit 445 Group > > > > > > jonathan@exit445.com > > > > > > http://www.exit445.com > > > > > > 415-381-1852 > > > > > > _______________________________________________ > > > > > > FX.php_List mailing list > > > > > > FX.php_List@mail.iviking.org > > > > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > > > > > > > > > > > > > > > > > > > > -| > > > > > > > > > > > > > > > _______________________________________________ > > > > > FX.php_List mailing list > > > > > FX.php_List@mail.iviking.org > > > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > > > > > > > _______________________________________________ > > > > FX.php_List mailing list > > > > FX.php_List@mail.iviking.org > > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > > > > > _______________________________________________ > > > FX.php_List mailing list > > > FX.php_List@mail.iviking.org > > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > _______________________________________________ > > FX.php_List mailing list > > FX.php_List@mail.iviking.org > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > > > _______________________________________________ > > FX.php_List mailing list > > FX.php_List@mail.iviking.org > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From bob at patin.com Thu Apr 3 10:14:18 2008 From: bob at patin.com (Bob Patin) Date: Thu Apr 3 10:14:38 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: > Hmm, is it just me, Yep, I think it's just you... :) > or where do you find arguments for using FileMaker > PHP API when you already know FX.php? Here are 6 that come to mind (all of these have happened to me): a) Client requests it because he's also a programmer and wants to modify it later on b) Client *thinks* he may want to add to it later on and plans to learn the API c) Client is convinced that the API is the way of the future and therefore asks if I can write the web app in the API d) Client gives no reason whatsoever, just says, "Do you know how to write using the FM API?" e) Client is also a FM consultant (in my case, he's a FM 9 Certified Developer) who is just now learning the API, and wants me to collaborate on a very large project that we'll be starting next month; he wants to use the API f) FileMaker, Inc. has put a lot of time and expense into its development, so I don't think it's going away anytime soon. I want to be able to use any of the new things they introduce that are based around the API. When it comes down to it, there are 2 basic ways to look at this: do you want the client's money, or not? Since the answer is yes, I come to the next question: does the API provide a decent product? Again, the answer is yes. In my hosting company, I've had people who wanted to put a Lasso site here; in the past, I hosted Lasso, and in order to do that, I bought the necessary software so that I could "be all things to all people." If they want mailing list capabilities, I can provide it, because In the music business, as a studio musician keyboard player, I'm expected to not only play piano, but to have synths with me so that if the client wants organ, or strings, or electric piano, I can swivel on the piano bench and play a part on a synthesizer. Sure, I could say, "No, I only play piano," since piano is my favorite keyboard, but I'd miss some great opportunities to record on some projects. Long answer, but that's why I learned the API. Bob Patin Longterm Solutions bob@longtermsolutions.com 615-333-6858 http://www.longtermsolutions.com Member of FileMaker Business Alliance and FileMaker TechNet CONTACT US VIA INSTANT MESSAGING: AIM or iChat: longterm1954 Yahoo: longterm_solutions MSN: tech@longtermsolutions.com ICQ: 159333060 -------------------------- Contact us for FileMaker hosting and programming for all versions of FileMaker PHP ? CDML ? Full email services ? Free DNS hosting ? Colocation ? Consulting From bob at patin.com Thu Apr 3 10:18:46 2008 From: bob at patin.com (Bob Patin) Date: Thu Apr 3 10:19:03 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> Message-ID: <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> Not the same thing. What if you have a client, as I do, who is a FM 9 Certified Developer, who knows a thing or two, and who never learned FX first? He believes (as I do) that the API is here to stay; he wants to write this upcoming project using the API, so that's what we're going to do. I'm doing about 90% of the web app development, but since he is learning the API, he wants me to write it using the API. I could've refused, but then, I would have lost a 5-figure project. Pretty simple decision. BP On Apr 3, 2008, at 9:46 AM, Gjermund Gusland Thorsen wrote: > When shrinks receive clients that attempt to shoot themselves in the > food, > it's OK? From jschwartz at exit445.com Thu Apr 3 11:00:01 2008 From: jschwartz at exit445.com (Jonathan Schwartz) Date: Thu Apr 3 11:01:47 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> Message-ID: Is that 5-figure with or without the decimal places? I need to add a couple of more zeroes to my proposals. ;-) J At 11:18 AM -0500 4/3/08, Bob Patin wrote: > >I could've refused, but then, I would have lost a 5-figure project. >Pretty simple decision. > >BP > > -- Jonathan Schwartz Exit 445 Group jonathan@exit445.com http://www.exit445.com 415-381-1852 From bob at patin.com Thu Apr 3 11:11:44 2008 From: bob at patin.com (Bob Patin) Date: Thu Apr 3 11:12:03 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> Message-ID: <701187BC-1849-4850-8750-E13DE587DD16@patin.com> I'm really happy to say that it's without! :) That's not the norm though; this is a good one... :) Bob Patin Longterm Solutions bob@longtermsolutions.com 615-333-6858 http://www.longtermsolutions.com Member of FileMaker Business Alliance and FileMaker TechNet CONTACT US VIA INSTANT MESSAGING: AIM or iChat: longterm1954 Yahoo: longterm_solutions MSN: tech@longtermsolutions.com ICQ: 159333060 -------------------------- Contact us for FileMaker hosting and programming for all versions of FileMaker PHP ? CDML ? Full email services ? Free DNS hosting ? Colocation ? Consulting On Apr 3, 2008, at 12:00 PM, Jonathan Schwartz wrote: > Is that 5-figure with or without the decimal places? I need to add > a couple of more zeroes to my proposals. ;-) > > J > > > At 11:18 AM -0500 4/3/08, Bob Patin wrote: >> >> I could've refused, but then, I would have lost a 5-figure project. >> Pretty simple decision. >> >> BP >> >> > > > -- > Jonathan Schwartz > Exit 445 Group > jonathan@exit445.com > http://www.exit445.com > 415-381-1852 > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list From ggt667 at gmail.com Thu Apr 3 11:30:31 2008 From: ggt667 at gmail.com (Gjermund Gusland Thorsen) Date: Thu Apr 3 11:30:54 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <701187BC-1849-4850-8750-E13DE587DD16@patin.com> References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> <701187BC-1849-4850-8750-E13DE587DD16@patin.com> Message-ID: Performance is not an issue I see... 2008/4/3, Bob Patin : > I'm really happy to say that it's without! :) > > That's not the norm though; this is a good one... :) > > Bob Patin > Longterm Solutions > bob@longtermsolutions.com > 615-333-6858 > http://www.longtermsolutions.com > Member of FileMaker Business Alliance and FileMaker TechNet > > CONTACT US VIA INSTANT MESSAGING: > AIM or iChat: longterm1954 > Yahoo: longterm_solutions > MSN: tech@longtermsolutions.com > ICQ: 159333060 > > -------------------------- > Contact us for FileMaker hosting and programming for all versions of > FileMaker > PHP ? CDML ? Full email services ? Free DNS hosting ? Colocation ? > Consulting > > On Apr 3, 2008, at 12:00 PM, Jonathan Schwartz wrote: > > > > Is that 5-figure with or without the decimal places? I need to add a > couple of more zeroes to my proposals. ;-) > > > > J > > > > > > At 11:18 AM -0500 4/3/08, Bob Patin wrote: > > > > > > > > I could've refused, but then, I would have lost a 5-figure project. > Pretty simple decision. > > > > > > BP > > > > > > > > > > > > > > > -- > > Jonathan Schwartz > > Exit 445 Group > > jonathan@exit445.com > > http://www.exit445.com > > 415-381-1852 > > _______________________________________________ > > FX.php_List mailing list > > FX.php_List@mail.iviking.org > > http://www.iviking.org/mailman/listinfo/fx.php_list > > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From bob at patin.com Thu Apr 3 11:58:44 2008 From: bob at patin.com (Bob Patin) Date: Thu Apr 3 11:59:02 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> <701187BC-1849-4850-8750-E13DE587DD16@patin.com> Message-ID: In the tests I've done, the difference is negligible... Bob Patin Longterm Solutions bob@longtermsolutions.com 615-333-6858 http://www.longtermsolutions.com Member of FileMaker Business Alliance and FileMaker TechNet CONTACT US VIA INSTANT MESSAGING: AIM or iChat: longterm1954 Yahoo: longterm_solutions MSN: tech@longtermsolutions.com ICQ: 159333060 -------------------------- Contact us for FileMaker hosting and programming for all versions of FileMaker PHP ? CDML ? Full email services ? Free DNS hosting ? Colocation ? Consulting On Apr 3, 2008, at 12:30 PM, Gjermund Gusland Thorsen wrote: > Performance is not an issue I see... From bob at patin.com Thu Apr 3 12:01:05 2008 From: bob at patin.com (Bob Patin) Date: Thu Apr 3 12:01:22 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> <701187BC-1849-4850-8750-E13DE587DD16@patin.com> Message-ID: <67D1B25E-1D7D-4750-B756-B37D6A96F5DA@patin.com> Also, if better were always the determining factor, we would have gone with BETA rather than VHS, Mac rather than PC, and on and on. On Apr 3, 2008, at 12:30 PM, Gjermund Gusland Thorsen wrote: > Performance is not an issue I see... From ggt667 at gmail.com Thu Apr 3 12:01:02 2008 From: ggt667 at gmail.com (Gjermund Gusland Thorsen) Date: Thu Apr 3 12:01:30 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> <701187BC-1849-4850-8750-E13DE587DD16@patin.com> Message-ID: Did you publish the test? array vs object has a performance difference in php at factor from 3 - 10x depending on situation. 2008/4/3, Bob Patin : > In the tests I've done, the difference is negligible... > > Bob Patin > Longterm Solutions > bob@longtermsolutions.com > 615-333-6858 > http://www.longtermsolutions.com > Member of FileMaker Business Alliance and FileMaker TechNet > > CONTACT US VIA INSTANT MESSAGING: > AIM or iChat: longterm1954 > Yahoo: longterm_solutions > MSN: tech@longtermsolutions.com > ICQ: 159333060 > > -------------------------- > Contact us for FileMaker hosting and programming for all versions of > FileMaker > PHP ? CDML ? Full email services ? Free DNS hosting ? Colocation ? > Consulting > > On Apr 3, 2008, at 12:30 PM, Gjermund Gusland Thorsen wrote: > > > > Performance is not an issue I see... > > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From ggt667 at gmail.com Thu Apr 3 12:04:26 2008 From: ggt667 at gmail.com (Gjermund Gusland Thorsen) Date: Thu Apr 3 12:04:44 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <67D1B25E-1D7D-4750-B756-B37D6A96F5DA@patin.com> References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> <701187BC-1849-4850-8750-E13DE587DD16@patin.com> <67D1B25E-1D7D-4750-B756-B37D6A96F5DA@patin.com> Message-ID: php is mainly a set of hacks, and has better array tools than oo tools, it's as simple as that. 2008/4/3, Bob Patin : > Also, if better were always the determining factor, we would have gone with > BETA rather than VHS, Mac rather than PC, and on and on. > > > On Apr 3, 2008, at 12:30 PM, Gjermund Gusland Thorsen wrote: > > > > Performance is not an issue I see... > > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From bob at patin.com Thu Apr 3 12:17:38 2008 From: bob at patin.com (Bob Patin) Date: Thu Apr 3 12:17:56 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <67D1B25E-1D7D-4750-B756-B37D6A96F5DA@patin.com> References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> <701187BC-1849-4850-8750-E13DE587DD16@patin.com> <67D1B25E-1D7D-4750-B756-B37D6A96F5DA@patin.com> Message-ID: <9745B9BA-2323-4AE7-9EA8-13B6F794A4B8@patin.com> And what difference does that make anyway, when the client's requests the API?? You're missing the point. If we were talking about what's better, then speed between the 2 becomes an issue. Clients aren't considering speed here; for the vast bulk of what I've developed, and at this point I've probably done 100 FX sites, the traffic is fairly low, so speed isn't a big issue. What IS important is a) what the client asks for, when that occurs, and b) being able to do the work when the call comes in. I've been doing freelance work for over 30 years, and my experience has taught me that in most cases, you get your chance once; when the call comes, and they're offering you a big pile of money, they're not saying, "We have this work to do; can you take a month and learn how to do x-y-z?" They're saying, "The work is this; are you able to do this right now?" In the music business, you get a shot at the big jobs once; if you aren't able to do it, or you do a bad job, you rarely get the second chance. If you get called for an audition, and they ask you if you can sight-read, you can't go home and learn--you have to be ready to rock when the call comes. The same thing applies here; the reason I've had my best year yet, and am on track to beat it in 2008, is that I try to prepare for the call before it comes. For me, as a FileMaker web-app designer, that includes having an arsenal of skills that will enable me to take more calls. Sure, you can be hard-headed and say, "I only program with FX.php," or "I only work on PC maachines," or "I only work on Macs," but in my opinion, that's a bone-headed attitude, and will cost you money in the long run. I know musicians who made the choice, when synths became popular, to stick just to piano. It's funny, but I rarely hear their names anymore... wonder why. I know musicians who refused to switch to digital recording, saying analog is better, tape is warmer, yada yada yada... who cares, what matters is what the industry is doing. In the FileMaker industry there are tons of people using the API, whether it's better or not... who cares, I want a piece of that pie too. My opinion, BP On Apr 3, 2008, at 1:01 PM, Bob Patin wrote: > Also, if better were always the determining factor, we would have > gone with BETA rather than VHS, Mac rather than PC, and on and on. > > > On Apr 3, 2008, at 12:30 PM, Gjermund Gusland Thorsen wrote: > >> Performance is not an issue I see... > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list From jschwartz at exit445.com Thu Apr 3 12:27:45 2008 From: jschwartz at exit445.com (Jonathan Schwartz) Date: Thu Apr 3 12:32:41 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: Where is this API reference? All I have found is the FMS9_CWP_PHP_en.pdf document...and is short on detail. Thanks, Jonathan At 9:22 AM +0200 4/3/08, Leo R. Lundgren wrote: >If you look at the API reference (included with the package, I >think. Might be on the server CD), you'll see that for the >Filemaker_Record class there is a method called getRecordId(). From >the reference (slightly rearranged): > > getRecordId (line 183) > integer getRecordId () > Returns the record ID of this object. > > return: Record ID. > >A record instance is of course what you get when looping through the >records from a result you got from a query to the database. > >-| > > >3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: >>Hi Folks, >> >>I'm helping a colleague with their first PHP project, but they are >>using the FMP API. >> >>I can't make heads or tails of the API interface. >> >>Can someone clue me in how to grab the recid after creating a >>record? I need it to edit the record later in the session. >> >>The existing code for creating the record looks like this: >> >> >>if(!isset($_SESSION['recordcreated'])) >>{ >>$add_result_add = $customer->newAddCommand('CU_Web_Customer'); >>$add_result_fields = >>array('Shipping_Contact_First_Name'=>$_POST['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); >>foreach($add_result_fields as $key=>$value) { >> $add_result_add->setField($key,$value); >>} >> >>$add_result_result = $add_result_add->execute(); >> >>if(FileMaker::isError($add_result_result)) >>fmsTrapError($add_result_result,"error.php"); >> >>$add_result_row = current($add_result_result->getRecords()); >> >> >> >> >>Thanks. >> >>Jonathan >>-- >>Jonathan Schwartz >>Exit 445 Group >>jonathan@exit445.com >>http://www.exit445.com >>415-381-1852 >>_______________________________________________ >>FX.php_List mailing list >>FX.php_List@mail.iviking.org >>http://www.iviking.org/mailman/listinfo/fx.php_list > > >-| > >_______________________________________________ >FX.php_List mailing list >FX.php_List@mail.iviking.org >http://www.iviking.org/mailman/listinfo/fx.php_list -- Jonathan Schwartz Exit 445 Group jonathan@exit445.com http://www.exit445.com 415-381-1852 From ggt667 at gmail.com Thu Apr 3 12:33:44 2008 From: ggt667 at gmail.com (Gjermund Gusland Thorsen) Date: Thu Apr 3 12:34:03 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <9745B9BA-2323-4AE7-9EA8-13B6F794A4B8@patin.com> References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> <701187BC-1849-4850-8750-E13DE587DD16@patin.com> <67D1B25E-1D7D-4750-B756-B37D6A96F5DA@patin.com> <9745B9BA-2323-4AE7-9EA8-13B6F794A4B8@patin.com> Message-ID: > In the FileMaker industry there are tons of people using the API, whether > it's better or not... who cares, I want a piece of that pie too. Fair enough From info at visioncomputerconsulting.com Thu Apr 3 13:40:29 2008 From: info at visioncomputerconsulting.com (Vision Computer Consulting) Date: Thu Apr 3 13:40:57 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: <88326D23-6CB8-404C-9995-A5B0EA5A7A79@visioncomputerconsulting.com> The best I can find is at: http://www.filemaker.com/support/technologies/php.html bottom of the page is a link to * FileMaker Server 9 Custom Web Publishing with PHP On Apr 3, 2008, at 11:27 AM, Jonathan Schwartz wrote: > Where is this API reference? All I have found is the > FMS9_CWP_PHP_en.pdf document...and is short on detail. > > Thanks, > > Jonathan > > > > > At 9:22 AM +0200 4/3/08, Leo R. Lundgren wrote: >> If you look at the API reference (included with the package, I >> think. Might be on the server CD), you'll see that for the >> Filemaker_Record class there is a method called getRecordId(). >> From the reference (slightly rearranged): >> >> getRecordId (line 183) >> integer getRecordId () >> Returns the record ID of this object. >> >> return: Record ID. >> >> A record instance is of course what you get when looping through >> the records from a result you got from a query to the database. >> >> -| >> >> >> 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: >>> Hi Folks, >>> >>> I'm helping a colleague with their first PHP project, but they >>> are using the FMP API. >>> >>> I can't make heads or tails of the API interface. >>> >>> Can someone clue me in how to grab the recid after creating a >>> record? I need it to edit the record later in the session. >>> >>> The existing code for creating the record looks like this: >>> >>> >>> if(!isset($_SESSION['recordcreated'])) >>> { >>> $add_result_add = $customer->newAddCommand('CU_Web_Customer'); >>> $add_result_fields = array('Shipping_Contact_First_Name'=>$_POST >>> ['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=> >>> $_POST['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST >>> ['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=> >>> $_POST['Promotion_Code'],'Shipping_Email'=>$_POST >>> ['Shipping_Email'],); >>> foreach($add_result_fields as $key=>$value) { >>> $add_result_add->setField($key,$value); >>> } >>> >>> $add_result_result = $add_result_add->execute(); >>> >>> if(FileMaker::isError($add_result_result)) fmsTrapError >>> ($add_result_result,"error.php"); >>> >>> $add_result_row = current($add_result_result->getRecords()); >>> >>> >>> >>> >>> Thanks. >>> >>> Jonathan >>> -- >>> Jonathan Schwartz >>> Exit 445 Group >>> jonathan@exit445.com >>> http://www.exit445.com >>> 415-381-1852 >>> _______________________________________________ >>> FX.php_List mailing list >>> FX.php_List@mail.iviking.org >>> http://www.iviking.org/mailman/listinfo/fx.php_list >> >> >> -| >> >> _______________________________________________ >> FX.php_List mailing list >> FX.php_List@mail.iviking.org >> http://www.iviking.org/mailman/listinfo/fx.php_list > > > -- > Jonathan Schwartz > Exit 445 Group > jonathan@exit445.com > http://www.exit445.com > 415-381-1852 > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.iviking.org/pipermail/fx.php_list/attachments/20080403/b634fb81/attachment-0001.html From jschwartz at exit445.com Thu Apr 3 13:47:43 2008 From: jschwartz at exit445.com (Jonathan Schwartz) Date: Thu Apr 3 13:52:40 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: <1AEBBEB3EA394828BF077DEFE4F8EF91@matatirosolutions.co.uk> <8C6DE855-84EB-4FE3-A88F-36F898C43A58@patin.com> <701187BC-1849-4850-8750-E13DE587DD16@patin.com> <67D1B25E-1D7D-4750-B756-B37D6A96F5DA@patin.com> <9745B9BA-2323-4AE7-9EA8-13B6F794A4B8@patin.com> Message-ID: Here's my 2?... I came along at a point just prior to the API making it on the scene, using fx.php. I had bandwidth for only one technology and I stuck with fx.php. A year or so later, with the API now gaining visibility , and with my fx.php and PHP skills in a steady state, I finally have time to try it out and at least be aware of the differences. A colleague asked for my help with his client's API project. It came at a great time, forcing me to crack open the manual. Now, I am starting to develop some perspective on the differences. I'm in a better position to advise future clients to implement with fx.php, rather than shrug my shoulders and have that big question mark float above my head. I save the shrug for better uses. ;-) Jonathan At 8:33 PM +0200 4/3/08, Gjermund Gusland Thorsen wrote: > > In the FileMaker industry there are tons of people using the API, whether >> it's better or not... who cares, I want a piece of that pie too. > >Fair enough >_______________________________________________ >FX.php_List mailing list >FX.php_List@mail.iviking.org >http://www.iviking.org/mailman/listinfo/fx.php_list -- Jonathan Schwartz Exit 445 Group jonathan@exit445.com http://www.exit445.com 415-381-1852 From chris at iViking.org Thu Apr 3 13:52:43 2008 From: chris at iViking.org (Chris Hansen) Date: Thu Apr 3 13:53:05 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: References: Message-ID: <8DBCAB32-F711-4945-BD8C-8DCE5DAC1E09@iViking.org> Try this: http://your.fmserver.com:16000/docs/PHP%20API%20Documentation/index.html The API docs are on your FileMaker server =) --Chris On Apr 3, 2008, at 12:27 PM, Jonathan Schwartz wrote: > Where is this API reference? All I have found is the > FMS9_CWP_PHP_en.pdf document...and is short on detail. > > Thanks, > > Jonathan > > > > > At 9:22 AM +0200 4/3/08, Leo R. Lundgren wrote: >> If you look at the API reference (included with the package, I >> think. Might be on the server CD), you'll see that for the >> Filemaker_Record class there is a method called getRecordId(). From >> the reference (slightly rearranged): >> >> getRecordId (line 183) >> integer getRecordId () >> Returns the record ID of this object. >> >> return: Record ID. >> >> A record instance is of course what you get when looping through >> the records from a result you got from a query to the database. >> >> -| >> >> >> 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: >>> Hi Folks, >>> >>> I'm helping a colleague with their first PHP project, but they are >>> using the FMP API. >>> >>> I can't make heads or tails of the API interface. >>> >>> Can someone clue me in how to grab the recid after creating a >>> record? I need it to edit the record later in the session. >>> >>> The existing code for creating the record looks like this: >>> >>> >>> if(!isset($_SESSION['recordcreated'])) >>> { >>> $add_result_add = $customer->newAddCommand('CU_Web_Customer'); >>> $add_result_fields = array('Shipping_Contact_First_Name'=> >>> $_POST['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); >>> foreach($add_result_fields as $key=>$value) { >>> $add_result_add->setField($key,$value); >>> } >>> >>> $add_result_result = $add_result_add->execute(); >>> >>> if(FileMaker::isError($add_result_result)) >>> fmsTrapError($add_result_result,"error.php"); >>> >>> $add_result_row = current($add_result_result->getRecords()); >>> >>> >>> >>> >>> Thanks. >>> >>> Jonathan >>> -- >>> Jonathan Schwartz >>> Exit 445 Group >>> jonathan@exit445.com >>> http://www.exit445.com >>> 415-381-1852 >>> _______________________________________________ >>> FX.php_List mailing list >>> FX.php_List@mail.iviking.org >>> http://www.iviking.org/mailman/listinfo/fx.php_list >> >> >> -| >> >> _______________________________________________ >> FX.php_List mailing list >> FX.php_List@mail.iviking.org >> http://www.iviking.org/mailman/listinfo/fx.php_list > > > -- > Jonathan Schwartz > Exit 445 Group > jonathan@exit445.com > http://www.exit445.com > 415-381-1852 > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From leo at finalresort.org Thu Apr 3 14:05:12 2008 From: leo at finalresort.org (Leo R. Lundgren) Date: Thu Apr 3 14:05:27 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <8DBCAB32-F711-4945-BD8C-8DCE5DAC1E09@iViking.org> References: <8DBCAB32-F711-4945-BD8C-8DCE5DAC1E09@iViking.org> Message-ID: <59241882-76FB-47C9-8879-44AF7E233634@finalresort.org> If this (below) reply answered the question, good. Otherwise let me know and I'll see where I found it :) 3 apr 2008 kl. 21.52 skrev Chris Hansen: > Try this: > > http://your.fmserver.com:16000/docs/PHP%20API%20Documentation/ > index.html > > The API docs are on your FileMaker server =) > > --Chris > > On Apr 3, 2008, at 12:27 PM, Jonathan Schwartz wrote: > >> Where is this API reference? All I have found is the >> FMS9_CWP_PHP_en.pdf document...and is short on detail. >> >> Thanks, >> >> Jonathan >> >> >> >> >> At 9:22 AM +0200 4/3/08, Leo R. Lundgren wrote: >>> If you look at the API reference (included with the package, I >>> think. Might be on the server CD), you'll see that for the >>> Filemaker_Record class there is a method called getRecordId(). >>> From the reference (slightly rearranged): >>> >>> getRecordId (line 183) >>> integer getRecordId () >>> Returns the record ID of this object. >>> >>> return: Record ID. >>> >>> A record instance is of course what you get when looping through >>> the records from a result you got from a query to the database. >>> >>> -| >>> >>> >>> 3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: >>>> Hi Folks, >>>> >>>> I'm helping a colleague with their first PHP project, but they >>>> are using the FMP API. >>>> >>>> I can't make heads or tails of the API interface. >>>> >>>> Can someone clue me in how to grab the recid after creating a >>>> record? I need it to edit the record later in the session. >>>> >>>> The existing code for creating the record looks like this: >>>> >>>> >>>> if(!isset($_SESSION['recordcreated'])) >>>> { >>>> $add_result_add = $customer->newAddCommand('CU_Web_Customer'); >>>> $add_result_fields = array('Shipping_Contact_First_Name'=>$_POST >>>> ['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=> >>>> $_POST['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST >>>> ['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=> >>>> $_POST['Promotion_Code'],'Shipping_Email'=>$_POST >>>> ['Shipping_Email'],); >>>> foreach($add_result_fields as $key=>$value) { >>>> $add_result_add->setField($key,$value); >>>> } >>>> >>>> $add_result_result = $add_result_add->execute(); >>>> >>>> if(FileMaker::isError($add_result_result)) fmsTrapError >>>> ($add_result_result,"error.php"); >>>> >>>> $add_result_row = current($add_result_result->getRecords()); >>>> >>>> >>>> >>>> >>>> Thanks. >>>> >>>> Jonathan >>>> -- >>>> Jonathan Schwartz >>>> Exit 445 Group >>>> jonathan@exit445.com >>>> http://www.exit445.com >>>> 415-381-1852 >>>> _______________________________________________ >>>> FX.php_List mailing list >>>> FX.php_List@mail.iviking.org >>>> http://www.iviking.org/mailman/listinfo/fx.php_list >>> >>> >>> -| >>> >>> _______________________________________________ >>> FX.php_List mailing list >>> FX.php_List@mail.iviking.org >>> http://www.iviking.org/mailman/listinfo/fx.php_list >> >> >> -- >> Jonathan Schwartz >> Exit 445 Group >> jonathan@exit445.com >> http://www.exit445.com >> 415-381-1852 >> _______________________________________________ >> FX.php_List mailing list >> FX.php_List@mail.iviking.org >> http://www.iviking.org/mailman/listinfo/fx.php_list >> > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list -| From Richard_Rose at nrel.gov Thu Apr 3 14:26:32 2008 From: Richard_Rose at nrel.gov (Rose, Richard) Date: Thu Apr 3 14:26:49 2008 Subject: [FX.php List] unsubscribe Message-ID: <94CA9432ECEFB84092222C964C32E50903AE8A1B@mail-4a.nrel.gov> -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.iviking.org/pipermail/fx.php_list/attachments/20080403/adf55799/attachment.html From jschwartz at exit445.com Thu Apr 3 14:37:01 2008 From: jschwartz at exit445.com (Jonathan Schwartz) Date: Thu Apr 3 14:41:16 2008 Subject: [FX.php List] [OFF] API Equivalent for Grabbing RECID In-Reply-To: <8DBCAB32-F711-4945-BD8C-8DCE5DAC1E09@iViking.org> References: <8DBCAB32-F711-4945-BD8C-8DCE5DAC1E09@iViking.org> Message-ID: Well that explains it.....I'm not using FMS9. My introduction to the API is on my colleague's system. However, I just did go ahead and install the Developer version from TechNet. And...yes..there it is. Thanks! Jonathan At 1:52 PM -0600 4/3/08, Chris Hansen wrote: >Try this: > >http://your.fmserver.com:16000/docs/PHP%20API%20Documentation/index.html > >The API docs are on your FileMaker server =) > >--Chris > >On Apr 3, 2008, at 12:27 PM, Jonathan Schwartz wrote: > >>Where is this API reference? All I have found is the >>FMS9_CWP_PHP_en.pdf document...and is short on detail. >> >>Thanks, >> >>Jonathan >> >> >> >> >>At 9:22 AM +0200 4/3/08, Leo R. Lundgren wrote: >>>If you look at the API reference (included with the package, I >>>think. Might be on the server CD), you'll see that for the >>>Filemaker_Record class there is a method called getRecordId(). >>>From the reference (slightly rearranged): >>> >>> getRecordId (line 183) >>> integer getRecordId () >>> Returns the record ID of this object. >>> >>> return: Record ID. >>> >>>A record instance is of course what you get when looping through >>>the records from a result you got from a query to the database. >>> >>>-| >>> >>> >>>3 apr 2008 kl. 00.12 skrev Jonathan Schwartz: >>>>Hi Folks, >>>> >>>>I'm helping a colleague with their first PHP project, but they >>>>are using the FMP API. >>>> >>>>I can't make heads or tails of the API interface. >>>> >>>>Can someone clue me in how to grab the recid after creating a >>>>record? I need it to edit the record later in the session. >>>> >>>>The existing code for creating the record looks like this: >>>> >>>> >>>>if(!isset($_SESSION['recordcreated'])) >>>>{ >>>>$add_result_add = $customer->newAddCommand('CU_Web_Customer'); >>>>$add_result_fields = >>>>array('Shipping_Contact_First_Name'=>$_POST['Shipping_Contact_First_Name'],'Shipping_Contact_Last_Name'=>$_POST['Shipping_Contact_Last_Name'],'Login_Name'=>$_POST['Login_Name'],'Password'=>$_POST['Password'],'Promotion_Code'=>$_POST['Promotion_Code'],'Shipping_Email'=>$_POST['Shipping_Email'],); >>>>foreach($add_result_fields as $key=>$value) { >>>> $add_result_add->setField($key,$value); >>>>} >>>> >>>>$add_result_result = $add_result_add->execute(); >>>> >>>>if(FileMaker::isError($add_result_result)) >>>>fmsTrapError($add_result_result,"error.php"); >>>> >>>>$add_result_row = current($add_result_result->getRecords()); >>>> >>>> >>>> >>>> >>>>Thanks. >>>> >>>>Jonathan >>>>-- >>>>Jonathan Schwartz >>>>Exit 445 Group >>>>jonathan@exit445.com >>>>http://www.exit445.com >>>>415-381-1852 >>>>_______________________________________________ >>>>FX.php_List mailing list >>>>FX.php_List@mail.iviking.org >>>>http://www.iviking.org/mailman/listinfo/fx.php_list >>> >>> >>>-| >>> >>>_______________________________________________ >>>FX.php_List mailing list >>>FX.php_List@mail.iviking.org >>>http://www.iviking.org/mailman/listinfo/fx.php_list >> >> >>-- >>Jonathan Schwartz >>Exit 445 Group >>jonathan@exit445.com >>http://www.exit445.com >>415-381-1852 >>_______________________________________________ >>FX.php_List mailing list >>FX.php_List@mail.iviking.org >>http://www.iviking.org/mailman/listinfo/fx.php_list >> > >_______________________________________________ >FX.php_List mailing list >FX.php_List@mail.iviking.org >http://www.iviking.org/mailman/listinfo/fx.php_list -- Jonathan Schwartz Exit 445 Group jonathan@exit445.com http://www.exit445.com 415-381-1852 From sam at smilepix.com Mon Apr 7 09:51:16 2008 From: sam at smilepix.com (Sam) Date: Mon Apr 7 09:51:30 2008 Subject: [FX.php List] Image not Showing in Internet Explorer 6 Message-ID: <9D394D1F-8E75-49F8-87F7-25822B18656A@smilepix.com> Image not Showing in Internet Explorer 6 I just changed service providers from Covad to Verizon and I have heard from my clients that the Thumbnail (in a container field) is not showing in Internet Explorer 6. Can this issue have anything to do with service providers? The Thumbnail worked for my clients before I switched to Verizon. I have tested it with FireFox (Mac & PC) and Safari and it shows in those browsers. Any ideas on how to get the thumbnail to show in Explorer? Here is the code: I have updated to 4.5.1 and configured image_proxy.php with the encrypt key from echo_new_key.php and also set server_data.php with my server address. Thanks in Advance - Sam ---------- Sam Laundon SmilePix "Picturing the Perfect Smile" http://www.smilepix.com 866-532-1843 -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.iviking.org/pipermail/fx.php_list/attachments/20080407/654ff4ee/attachment-0001.html From bob at patin.com Mon Apr 7 09:59:59 2008 From: bob at patin.com (Bob Patin) Date: Mon Apr 7 10:00:09 2008 Subject: [FX.php List] Image not Showing in Internet Explorer 6 In-Reply-To: <9D394D1F-8E75-49F8-87F7-25822B18656A@smilepix.com> References: <9D394D1F-8E75-49F8-87F7-25822B18656A@smilepix.com> Message-ID: <0C89E7E2-2FF4-4096-BAD0-C76542B331DC@patin.com> Sam, I see that in your code, your open tag is Image not Showing in Internet Explorer 6 > > I just changed service providers from Covad to Verizon and I have > heard from my clients that the Thumbnail (in a container field) is > not showing in Internet Explorer 6. Can this issue have anything to > do with service providers? The Thumbnail worked for my clients > before I switched to Verizon. I have tested it with FireFox (Mac & > PC) and Safari and it shows in those browsers. Any ideas on how to > get the thumbnail to show in Explorer? > > Here is the code: > > > I have updated to 4.5.1 and configured image_proxy.php with the > encrypt key from echo_new_key.php and also set server_data.php with > my server address. > > Thanks in Advance - Sam > > ---------- > Sam Laundon > SmilePix > "Picturing the Perfect Smile" > http://www.smilepix.com > 866-532-1843 > > > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list -------------- next part -------------- An HTML attachment was scrubbed... URL: http://www.iviking.org/pipermail/fx.php_list/attachments/20080407/91c23af4/attachment.html From andretozzini at gmail.com Mon Apr 7 18:07:07 2008 From: andretozzini at gmail.com (Andre Tozzini) Date: Mon Apr 7 18:07:10 2008 Subject: [FX.php List] =?iso-8859-1?q?Andre_Tozzini_convida_voc=EA_a_ser_?= =?iso-8859-1?q?seu_amigo_no_Sonico?= Message-ID: <20080408000707.923217708BE@mail.iviking.org> An HTML attachment was scrubbed... URL: http://www.iviking.org/pipermail/fx.php_list/attachments/20080407/efc9ebc2/attachment.html From kfutter at sbc.melb.catholic.edu.au Wed Apr 9 21:17:59 2008 From: kfutter at sbc.melb.catholic.edu.au (Kevin Futter) Date: Wed Apr 9 21:17:49 2008 Subject: [FX.php List] FX/FM escaping quotes with a backslash? Message-ID: Hi Folks, I've hit a snag that I just can't figure out. On submitting a URL to a text field in FM via FX, I'm finding that the quoted href path is being escaped. For example, on submitting something like this: My Site It comes out as this in the database: My Site It does the same thing to single quotes. The only thing I'm doing to the raw POST data prior to submitting it is to run a function to remove smart quotes and replace them with straight quotes (came from someone here I think). While it doesn't add slashes anywhere, just for laughs I disabled it anyway and it made no difference. I've been all over my code and I can't find anything that's doing this, so I'm assuming it's either FX (not likely) or FM's XML interface. If it's the latter, the only thing I can think of is that the submitting page is encoded as ISO-8859-1 rather than UTF-8, and FM is 'handling' that by escaping non-ASCII characters. An educated but rather wild guess, really. Any ideas? -- Kevin Futter Webmaster, St. Bernard's College http://www.sbc.melb.catholic.edu.au/ ##################################################################################### This e-mail message has been scanned for Viruses and Content and cleared by MailMarshal ##################################################################################### This e-mail and any attachments may be confidential. You must not disclose or use the information in this e-mail if you are not the intended recipient. If you have received this e-mail in error, please notify us immediately and delete the e-mail and all copies. The College does not guarantee that this e-mail is virus or error free. The attached files are provided and may only be used on the basis that the user assumes all responsibility for any loss, damage or consequence resulting directly or indirectly from the use of the attached files, whether caused by the negligence of the sender or not. The content and opinions in this e-mail are not necessarily those of the College. From tim at nicheit.com.au Wed Apr 9 21:39:55 2008 From: tim at nicheit.com.au (Tim 'Webko' Booth) Date: Wed Apr 9 21:40:33 2008 Subject: [FX.php List] FX/FM escaping quotes with a backslash? In-Reply-To: References: Message-ID: <4A8DFBBE-7773-44F5-94C1-1E6BF7DCE430@nicheit.com.au> > > I've been all over my code and I can't find anything that's doing > this, so > I'm assuming it's either FX (not likely) or FM's XML interface. If > it's the > latter, the only thing I can think of is that the submitting page is > encoded > as ISO-8859-1 rather than UTF-8, and FM is 'handling' that by escaping > non-ASCII characters. An educated but rather wild guess, really. I've had this occur every now and again, but never delved too deeply into why - the places it happened were my own testing pages, so I basically ignored it ;-) Maybe you could apply a stripslashes to it before inserting and see if that makes a difference? Cheers Webko From kfutter at sbc.melb.catholic.edu.au Wed Apr 9 22:22:37 2008 From: kfutter at sbc.melb.catholic.edu.au (Kevin Futter) Date: Wed Apr 9 22:22:26 2008 Subject: [FX.php List] FX/FM escaping quotes with a backslash? In-Reply-To: <4A8DFBBE-7773-44F5-94C1-1E6BF7DCE430@nicheit.com.au> Message-ID: On 10/04/08 1:39 PM, "Tim 'Webko' Booth" wrote: >> >> I've been all over my code and I can't find anything that's doing >> this, so >> I'm assuming it's either FX (not likely) or FM's XML interface. If >> it's the >> latter, the only thing I can think of is that the submitting page is >> encoded >> as ISO-8859-1 rather than UTF-8, and FM is 'handling' that by escaping >> non-ASCII characters. An educated but rather wild guess, really. > > I've had this occur every now and again, but never delved too deeply > into why - the places it happened were my own testing pages, so I > basically ignored it ;-) > > Maybe you could apply a stripslashes to it before inserting and see if > that makes a difference? > > Cheers > > Webko Thanks Tim. Just gave it a go but it made no difference. This more-or-less confirms for me that it's not FX or PHP doing it, but rather, something on the FM side - most likely the XML interface. Luckily it's only an internal page that us technical staff use, so it's no biggie from that perspective, but I'm still stumped about the 'why'. -- Kevin Futter Webmaster, St. Bernard's College http://www.sbc.melb.catholic.edu.au/ ##################################################################################### This e-mail message has been scanned for Viruses and Content and cleared by MailMarshal ##################################################################################### This e-mail and any attachments may be confidential. You must not disclose or use the information in this e-mail if you are not the intended recipient. If you have received this e-mail in error, please notify us immediately and delete the e-mail and all copies. The College does not guarantee that this e-mail is virus or error free. The attached files are provided and may only be used on the basis that the user assumes all responsibility for any loss, damage or consequence resulting directly or indirectly from the use of the attached files, whether caused by the negligence of the sender or not. The content and opinions in this e-mail are not necessarily those of the College. From ggt667 at gmail.com Wed Apr 9 23:38:20 2008 From: ggt667 at gmail.com (Gjermund Gusland Thorsen) Date: Wed Apr 9 23:38:45 2008 Subject: [FX.php List] FX/FM escaping quotes with a backslash? In-Reply-To: References: <4A8DFBBE-7773-44F5-94C1-1E6BF7DCE430@nicheit.com.au> Message-ID: You forgot to do stripslashes()? 2008/4/10, Kevin Futter : > On 10/04/08 1:39 PM, "Tim 'Webko' Booth" wrote: > > >> > >> I've been all over my code and I can't find anything that's doing > >> this, so > >> I'm assuming it's either FX (not likely) or FM's XML interface. If > >> it's the > >> latter, the only thing I can think of is that the submitting page is > >> encoded > >> as ISO-8859-1 rather than UTF-8, and FM is 'handling' that by escaping > >> non-ASCII characters. An educated but rather wild guess, really. > > > > I've had this occur every now and again, but never delved too deeply > > into why - the places it happened were my own testing pages, so I > > basically ignored it ;-) > > > > Maybe you could apply a stripslashes to it before inserting and see if > > that makes a difference? > > > > Cheers > > > > Webko > > > Thanks Tim. Just gave it a go but it made no difference. This more-or-less > confirms for me that it's not FX or PHP doing it, but rather, something on > the FM side - most likely the XML interface. Luckily it's only an internal > page that us technical staff use, so it's no biggie from that perspective, > but I'm still stumped about the 'why'. > > > -- > Kevin Futter > Webmaster, St. Bernard's College > http://www.sbc.melb.catholic.edu.au/ > > > ##################################################################################### > This e-mail message has been scanned for Viruses and Content and cleared > by MailMarshal > ##################################################################################### > > This e-mail and any attachments may be confidential. You must not disclose or use the information in this e-mail if you are not the intended recipient. If you have received this e-mail in error, please notify us immediately and delete the e-mail and all copies. The College does not guarantee that this e-mail is virus or error free. The attached files are provided and may only be used on the basis that the user assumes all responsibility for any loss, damage or consequence resulting directly or indirectly from the use of the attached files, whether caused by the negligence of the sender or not. The content and opinions in this e-mail are not necessarily those of the College. > _______________________________________________ > > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From sam at smilepix.com Thu Apr 10 09:46:48 2008 From: sam at smilepix.com (Sam) Date: Thu Apr 10 09:47:08 2008 Subject: [FX.php List] Re: Image not Showing in Internet Explorer 6 In-Reply-To: <20080410053848.9A5DD776F09@mail.iviking.org> References: <20080410053848.9A5DD776F09@mail.iviking.org> Message-ID: <4DBE59CD-EED4-47CE-9F12-4DFF07CEB736@smilepix.com> Thanks for trying Bob, but that was not the problem. I tried this and came up with a blank page: Any other ideas? Sam On Apr 10, 2008, at 1:38 AM, fx.php_list-request@mail.iviking.org wrote: > Send FX.php_List mailing list submissions to > fx.php_list@mail.iviking.org > > To subscribe or unsubscribe via the World Wide Web, visit > http://www.iviking.org/mailman/listinfo/fx.php_list > or, via email, send a message with subject or body 'help' to > fx.php_list-request@mail.iviking.org > > You can reach the person managing the list at > fx.php_list-owner@mail.iviking.org > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of FX.php_List digest..." > > > Today's Topics: > > 1. Re: Image not Showing in Internet Explorer 6 (Bob Patin) > 2. Andre Tozzini convida voc? a ser seu amigo no Sonico > (Andre Tozzini) > 3. FX/FM escaping quotes with a backslash? (Kevin Futter) > 4. Re: FX/FM escaping quotes with a backslash? (Tim 'Webko' Booth) > 5. Re: FX/FM escaping quotes with a backslash? (Kevin Futter) > 6. Re: FX/FM escaping quotes with a backslash? > (Gjermund Gusland Thorsen) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Mon, 7 Apr 2008 10:59:59 -0500 > From: Bob Patin > Subject: Re: [FX.php List] Image not Showing in Internet Explorer 6 > To: "FX.php Discussion List" > Message-ID: <0C89E7E2-2FF4-4096-BAD0-C76542B331DC@patin.com> > Content-Type: text/plain; charset="windows-1252" > > Sam, > > I see that in your code, your open tag is changed providers, does this mean that you've also changed web servers > too? > > The reason I ask is because the open tag may be breaking things; if > you have error reporting turned off, you might not know that there's a > problem in the page. If, for example, you went from PHP 4 to PHP 5, > and the server settings don't allow short open tags, then you'd be > getting an error. > > If this were the case though, I'd expect you'd have other problems on > the page as well. > > Recently I had a bit of unorthodox HTML code (that worked though) on > some pages, and although Firefox and Safari handled the code without > trouble, IE consistently failed to understand the code and wouldn't > display the page properly. > > Hope this helps, > > Bob Patin > Longterm Solutions > bob@longtermsolutions.com > 615-333-6858 > http://www.longtermsolutions.com > Member of FileMaker Business Alliance and FileMaker TechNet > > CONTACT US VIA INSTANT MESSAGING: > AIM or iChat: longterm1954 > Yahoo: longterm_solutions > MSN: tech@longtermsolutions.com > ICQ: 159333060 > > -------------------------- > Contact us for FileMaker hosting and programming for all versions of > FileMaker > PHP ? CDML ? Full email services ? Free DNS hosting ? Colocation ? > Consulting > > On Apr 7, 2008, at 10:51 AM, Sam wrote: > >> Image not Showing in Internet Explorer 6 >> >> I just changed service providers from Covad to Verizon and I have >> heard from my clients that the Thumbnail (in a container field) is >> not showing in Internet Explorer 6. Can this issue have anything to >> do with service providers? The Thumbnail worked for my clients >> before I switched to Verizon. I have tested it with FireFox (Mac & >> PC) and Safari and it shows in those browsers. Any ideas on how to >> get the thumbnail to show in Explorer? >> >> Here is the code: >> >> >> I have updated to 4.5.1 and configured image_proxy.php with the >> encrypt key from echo_new_key.php and also set server_data.php with >> my server address. >> >> Thanks in Advance - Sam >> >> ---------- >> Sam Laundon >> SmilePix >> "Picturing the Perfect Smile" >> http://www.smilepix.com >> 866-532-1843 >> >> >> _______________________________________________ >> FX.php_List mailing list >> FX.php_List@mail.iviking.org >> http://www.iviking.org/mailman/listinfo/fx.php_list > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: http://www.iviking.org/pipermail/fx.php_list/attachments/ > 20080407/91c23af4/attachment-0001.html > > ------------------------------ > > Message: 2 > Date: Mon, 7 Apr 2008 18:07:07 -0600 (MDT) > From: Andre Tozzini > Subject: [FX.php List] Andre Tozzini convida voc? a ser seu amigo no > Sonico > To: FX.php Discussion List > Message-ID: <20080408000707.923217708BE@mail.iviking.org> > Content-Type: text/plain; charset="us-ascii" > > An HTML attachment was scrubbed... > URL: http://www.iviking.org/pipermail/fx.php_list/attachments/ > 20080407/efc9ebc2/attachment-0001.html > > ------------------------------ > > Message: 3 > Date: Thu, 10 Apr 2008 13:17:59 +1000 > From: Kevin Futter > Subject: [FX.php List] FX/FM escaping quotes with a backslash? > To: "FX.php Discussion List" > Message-ID: > Content-Type: text/plain; charset="US-ASCII" > > Hi Folks, > > I've hit a snag that I just can't figure out. On submitting a URL > to a text > field in FM via FX, I'm finding that the quoted href path is being > escaped. > For example, on submitting something like this: > > My Site > > It comes out as this in the database: > > My Site > > It does the same thing to single quotes. The only thing I'm doing > to the raw > POST data prior to submitting it is to run a function to remove > smart quotes > and replace them with straight quotes (came from someone here I > think). > While it doesn't add slashes anywhere, just for laughs I disabled > it anyway > and it made no difference. > > I've been all over my code and I can't find anything that's doing > this, so > I'm assuming it's either FX (not likely) or FM's XML interface. If > it's the > latter, the only thing I can think of is that the submitting page > is encoded > as ISO-8859-1 rather than UTF-8, and FM is 'handling' that by escaping > non-ASCII characters. An educated but rather wild guess, really. > > Any ideas? > > -- > Kevin Futter > Webmaster, St. Bernard's College > http://www.sbc.melb.catholic.edu.au/ > > > ###################################################################### > ############### > This e-mail message has been scanned for Viruses and Content and > cleared > by MailMarshal > ###################################################################### > ############### > > This e-mail and any attachments may be confidential. You must not > disclose or use the information in this e-mail if you are not the > intended recipient. If you have received this e-mail in error, > please notify us immediately and delete the e-mail and all copies. > The College does not guarantee that this e-mail is virus or error > free. The attached files are provided and may only be used on the > basis that the user assumes all responsibility for any loss, damage > or consequence resulting directly or indirectly from the use of the > attached files, whether caused by the negligence of the sender or > not. The content and opinions in this e-mail are not necessarily > those of the College. > > > ------------------------------ > > Message: 4 > Date: Thu, 10 Apr 2008 13:39:55 +1000 > From: Tim 'Webko' Booth > Subject: Re: [FX.php List] FX/FM escaping quotes with a backslash? > To: "FX.php Discussion List" > Message-ID: <4A8DFBBE-7773-44F5-94C1-1E6BF7DCE430@nicheit.com.au> > Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes > >> >> I've been all over my code and I can't find anything that's doing >> this, so >> I'm assuming it's either FX (not likely) or FM's XML interface. If >> it's the >> latter, the only thing I can think of is that the submitting page is >> encoded >> as ISO-8859-1 rather than UTF-8, and FM is 'handling' that by >> escaping >> non-ASCII characters. An educated but rather wild guess, really. > > I've had this occur every now and again, but never delved too deeply > into why - the places it happened were my own testing pages, so I > basically ignored it ;-) > > Maybe you could apply a stripslashes to it before inserting and see if > that makes a difference? > > Cheers > > Webko > > > ------------------------------ > > Message: 5 > Date: Thu, 10 Apr 2008 14:22:37 +1000 > From: Kevin Futter > Subject: Re: [FX.php List] FX/FM escaping quotes with a backslash? > To: "FX.php Discussion List" > Message-ID: > Content-Type: text/plain; charset="US-ASCII" > > On 10/04/08 1:39 PM, "Tim 'Webko' Booth" wrote: > >>> >>> I've been all over my code and I can't find anything that's doing >>> this, so >>> I'm assuming it's either FX (not likely) or FM's XML interface. If >>> it's the >>> latter, the only thing I can think of is that the submitting page is >>> encoded >>> as ISO-8859-1 rather than UTF-8, and FM is 'handling' that by >>> escaping >>> non-ASCII characters. An educated but rather wild guess, really. >> >> I've had this occur every now and again, but never delved too deeply >> into why - the places it happened were my own testing pages, so I >> basically ignored it ;-) >> >> Maybe you could apply a stripslashes to it before inserting and >> see if >> that makes a difference? >> >> Cheers >> >> Webko > > Thanks Tim. Just gave it a go but it made no difference. This more- > or-less > confirms for me that it's not FX or PHP doing it, but rather, > something on > the FM side - most likely the XML interface. Luckily it's only an > internal > page that us technical staff use, so it's no biggie from that > perspective, > but I'm still stumped about the 'why'. > > -- > Kevin Futter > Webmaster, St. Bernard's College > http://www.sbc.melb.catholic.edu.au/ > > > ###################################################################### > ############### > This e-mail message has been scanned for Viruses and Content and > cleared > by MailMarshal > ###################################################################### > ############### > > This e-mail and any attachments may be confidential. You must not > disclose or use the information in this e-mail if you are not the > intended recipient. If you have received this e-mail in error, > please notify us immediately and delete the e-mail and all copies. > The College does not guarantee that this e-mail is virus or error > free. The attached files are provided and may only be used on the > basis that the user assumes all responsibility for any loss, damage > or consequence resulting directly or indirectly from the use of the > attached files, whether caused by the negligence of the sender or > not. The content and opinions in this e-mail are not necessarily > those of the College. > > > ------------------------------ > > Message: 6 > Date: Thu, 10 Apr 2008 07:38:20 +0200 > From: "Gjermund Gusland Thorsen" > Subject: Re: [FX.php List] FX/FM escaping quotes with a backslash? > To: "FX.php Discussion List" > Message-ID: > > Content-Type: text/plain; charset=UTF-8 > > You forgot to do stripslashes()? > > 2008/4/10, Kevin Futter : >> On 10/04/08 1:39 PM, "Tim 'Webko' Booth" wrote: >> >>>> >>>> I've been all over my code and I can't find anything that's doing >>>> this, so >>>> I'm assuming it's either FX (not likely) or FM's XML interface. If >>>> it's the >>>> latter, the only thing I can think of is that the submitting >>>> page is >>>> encoded >>>> as ISO-8859-1 rather than UTF-8, and FM is 'handling' that by >>>> escaping >>>> non-ASCII characters. An educated but rather wild guess, really. >>> >>> I've had this occur every now and again, but never delved too deeply >>> into why - the places it happened were my own testing pages, so I >>> basically ignored it ;-) >>> >>> Maybe you could apply a stripslashes to it before inserting and >>> see if >>> that makes a difference? >>> >>> Cheers >>> >>> Webko >> >> >> Thanks Tim. Just gave it a go but it made no difference. This more- >> or-less >> confirms for me that it's not FX or PHP doing it, but rather, >> something on >> the FM side - most likely the XML interface. Luckily it's only an >> internal >> page that us technical staff use, so it's no biggie from that >> perspective, >> but I'm still stumped about the 'why'. >> >> >> -- >> Kevin Futter >> Webmaster, St. Bernard's College >> http://www.sbc.melb.catholic.edu.au/ >> >> >> >> ##################################################################### >> ################ >> This e-mail message has been scanned for Viruses and Content and >> cleared >> by MailMarshal >> >> ##################################################################### >> ################ >> >> This e-mail and any attachments may be confidential. You must not >> disclose or use the information in this e-mail if you are not the >> intended recipient. If you have received this e-mail in error, >> please notify us immediately and delete the e-mail and all copies. >> The College does not guarantee that this e-mail is virus or error >> free. The attached files are provided and may only be used on the >> basis that the user assumes all responsibility for any loss, >> damage or consequence resulting directly or indirectly from the >> use of the attached files, whether caused by the negligence of the >> sender or not. The content and opinions in this e-mail are not >> necessarily those of the College. >> _______________________________________________ >> >> FX.php_List mailing list >> FX.php_List@mail.iviking.org >> http://www.iviking.org/mailman/listinfo/fx.php_list >> > > > ------------------------------ > > _______________________________________________ > FX.php_List > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > > End of FX.php_List Digest, Vol 45, Issue 7 > ****************************************** > ---------- Sam Laundon SmilePix "Picturing the Perfect Smile" http://www.smilepix.com 866-532-1843 From dbengston at preservationstudio.com Thu Apr 10 11:26:32 2008 From: dbengston at preservationstudio.com (Dale Bengston) Date: Thu Apr 10 11:26:56 2008 Subject: [FX.php List] FX/FM escaping quotes with a backslash? In-Reply-To: References: Message-ID: <2BFB973D-B753-45A2-B478-A5026AD3F7B7@preservationstudio.com> We ran into something similar a few weeks back, where different server configs would place different variants of \" and \' in MySQL database fields via FX.php (although FX wasn't causing the problem). We started trapping the server settings, thusly and removing slashes accordingly. We're looking at the value of get_magic_quotes_gpc(). http://us.php.net/manual/en/function.get-magic-quotes-gpc.php Hope this helps, Dale On Apr 9, 2008, at 11:22 PM, Kevin Futter wrote: > On 10/04/08 1:39 PM, "Tim 'Webko' Booth" wrote: > >>> >>> I've been all over my code and I can't find anything that's doing >>> this, so >>> I'm assuming it's either FX (not likely) or FM's XML interface. If >>> it's the >>> latter, the only thing I can think of is that the submitting page is >>> encoded >>> as ISO-8859-1 rather than UTF-8, and FM is 'handling' that by >>> escaping >>> non-ASCII characters. An educated but rather wild guess, really. >> >> I've had this occur every now and again, but never delved too deeply >> into why - the places it happened were my own testing pages, so I >> basically ignored it ;-) >> >> Maybe you could apply a stripslashes to it before inserting and see >> if >> that makes a difference? >> >> Cheers >> >> Webko > > Thanks Tim. Just gave it a go but it made no difference. This more- > or-less > confirms for me that it's not FX or PHP doing it, but rather, > something on > the FM side - most likely the XML interface. Luckily it's only an > internal > page that us technical staff use, so it's no biggie from that > perspective, > but I'm still stumped about the 'why'. > > -- > Kevin Futter > Webmaster, St. Bernard's College > http://www.sbc.melb.catholic.edu.au/ > > > ##################################################################################### > This e-mail message has been scanned for Viruses and Content and > cleared > by MailMarshal > ##################################################################################### > > This e-mail and any attachments may be confidential. You must not > disclose or use the information in this e-mail if you are not the > intended recipient. If you have received this e-mail in error, > please notify us immediately and delete the e-mail and all copies. > The College does not guarantee that this e-mail is virus or error > free. The attached files are provided and may only be used on the > basis that the user assumes all responsibility for any loss, damage > or consequence resulting directly or indirectly from the use of the > attached files, whether caused by the negligence of the sender or > not. The content and opinions in this e-mail are not necessarily > those of the College. > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list From kfutter at sbc.melb.catholic.edu.au Thu Apr 10 17:58:07 2008 From: kfutter at sbc.melb.catholic.edu.au (Kevin Futter) Date: Thu Apr 10 17:57:58 2008 Subject: [FX.php List] FX/FM escaping quotes with a backslash? In-Reply-To: <2BFB973D-B753-45A2-B478-A5026AD3F7B7@preservationstudio.com> Message-ID: On 11/04/08 3:26 AM, "Dale Bengston" wrote: > We ran into something similar a few weeks back, where different server > configs would place different variants of \" and \' in MySQL database > fields via FX.php (although FX wasn't causing the problem). We started > trapping the server settings, thusly and removing slashes accordingly. > We're looking at the value of get_magic_quotes_gpc(). > > http://us.php.net/manual/en/function.get-magic-quotes-gpc.php > > Hope this helps, > Dale Brilliant Dale, thanks! That indeed was the problem! Ironic that our own internal tech webserver would fall victim to this... -- Kevin Futter Webmaster, St. Bernard's College http://www.sbc.melb.catholic.edu.au/ ##################################################################################### This e-mail message has been scanned for Viruses and Content and cleared by MailMarshal ##################################################################################### This e-mail and any attachments may be confidential. You must not disclose or use the information in this e-mail if you are not the intended recipient. If you have received this e-mail in error, please notify us immediately and delete the e-mail and all copies. The College does not guarantee that this e-mail is virus or error free. The attached files are provided and may only be used on the basis that the user assumes all responsibility for any loss, damage or consequence resulting directly or indirectly from the use of the attached files, whether caused by the negligence of the sender or not. The content and opinions in this e-mail are not necessarily those of the College. From dbengston at preservationstudio.com Thu Apr 10 21:04:04 2008 From: dbengston at preservationstudio.com (Dale Bengston) Date: Thu Apr 10 21:04:26 2008 Subject: [FX.php List] FX/FM escaping quotes with a backslash? In-Reply-To: References: Message-ID: <390B1DD6-9BA4-4A02-8D43-470A48E85566@preservationstudio.com> All right! Dale On Apr 10, 2008, at 6:58 PM, Kevin Futter wrote: > On 11/04/08 3:26 AM, "Dale Bengston" > > wrote: > >> We ran into something similar a few weeks back, where different >> server >> configs would place different variants of \" and \' in MySQL database >> fields via FX.php (although FX wasn't causing the problem). We >> started >> trapping the server settings, thusly and removing slashes >> accordingly. >> We're looking at the value of get_magic_quotes_gpc(). >> >> http://us.php.net/manual/en/function.get-magic-quotes-gpc.php >> >> Hope this helps, >> Dale > > Brilliant Dale, thanks! That indeed was the problem! Ironic that our > own > internal tech webserver would fall victim to this... > > -- > Kevin Futter > Webmaster, St. Bernard's College > http://www.sbc.melb.catholic.edu.au/ > > > ##################################################################################### > This e-mail message has been scanned for Viruses and Content and > cleared > by MailMarshal > ##################################################################################### > > This e-mail and any attachments may be confidential. You must not > disclose or use the information in this e-mail if you are not the > intended recipient. If you have received this e-mail in error, > please notify us immediately and delete the e-mail and all copies. > The College does not guarantee that this e-mail is virus or error > free. The attached files are provided and may only be used on the > basis that the user assumes all responsibility for any loss, damage > or consequence resulting directly or indirectly from the use of the > attached files, whether caused by the negligence of the sender or > not. The content and opinions in this e-mail are not necessarily > those of the College. > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list From jschwartz at exit445.com Mon Apr 14 10:49:41 2008 From: jschwartz at exit445.com (Jonathan Schwartz) Date: Mon Apr 14 10:50:46 2008 Subject: [FX.php List] Portals in fx.php versus API Message-ID: Hi Folks, Still assisting a colleague with an API application. Need to clarify the issue of portals for input. If a screen had to list and then collect input from multiple records on the same page, in fx.php I would use a technique I learned from the list (Steve Winter, I believe ;-) ): Create a single form from the multiple records and then process the POSTED input in a While loop when submitted. I believe that I went this way because fx.php doesn't support portals for collecting input from multiple records. Question #1: Is this correct? Question #2: Does the API support portals for collecting input from multiple records...or do I use the technique I have for fx.php? Thanks Jonathan -- Jonathan Schwartz Exit 445 Group jonathan@exit445.com http://www.exit445.com 415-381-1852 From chris at iViking.org Mon Apr 14 12:02:20 2008 From: chris at iViking.org (Chris Hansen) Date: Mon Apr 14 12:02:35 2008 Subject: [FX.php List] Portals in fx.php versus API In-Reply-To: References: Message-ID: <02DBD6B7-E072-4B24-AFC9-80152D28ED56@iViking.org> Jonathan, 1) FX.php DOES support editing multiple portals simultaneously. Simply append a . (period) followed by the portal record's RecordID to the name of each field in the portal. You will still need to pass in the RecordID of the parent record (just as you would for any other edit) so that FileMaker knows to which parent the specified children belong. Note that you can only create one portal record at a time by appending a .0 to the name of each field in the portal to be set. For example, to edit the first and last names of two portal records with RecordIDs of 22 and 9: ... $query->SetDBData('Contacts::First_Name.22', 'Bob'); $query->SetDBData('Contacts::Last_Name.22', 'Smith'); $query->SetDBData('Contacts::First_Name.9', 'Raul'); $query->SetDBData('Contacts::Last_Name.9', 'Espinoza'); ... 2) Since the FileMaker API for PHP also uses FileMaker's XML interface for communicating with FileMaker, it also supports editing multiple records in a portal at once, but of course the syntax is different. HTH --Chris On Apr 14, 2008, at 10:49 AM, Jonathan Schwartz wrote: > Hi Folks, > > Still assisting a colleague with an API application. Need to clarify > the issue of portals for input. > > If a screen had to list and then collect input from multiple records > on the same page, in fx.php I would use a technique I learned from > the list (Steve Winter, I believe ;-) ): Create a single form from > the multiple records and then process the POSTED input in a While > loop when submitted. > > I believe that I went this way because fx.php doesn't support > portals for collecting input from multiple records. Question #1: Is > this correct? > > Question #2: Does the API support portals for collecting input from > multiple records...or do I use the technique I have for fx.php? > > Thanks > > > Jonathan > > > -- > Jonathan Schwartz > Exit 445 Group > jonathan@exit445.com > http://www.exit445.com > 415-381-1852 > _______________________________________________ > FX.php_List mailing list > FX.php_List@mail.iviking.org > http://www.iviking.org/mailman/listinfo/fx.php_list > From dbengston at tds.net Mon Apr 14 12:47:58 2008 From: dbengston at tds.net (Dale Bengston) Date: Mon Apr 14 12:48:14 2008 Subject: [FX.php List] Portals in fx.php versus API In-Reply-To: References: Message-ID: <0C2A78A0-AB98-49CD-ADE9-99D07B77857F@tds.net> I can answer question 1: FX.php does support portals for retrieving data. That said, I would not d