[FX.php List] Creating new portal record via form

Marisa Smith marisa at datasmithconsulting.net
Fri Aug 12 03:36:45 MDT 2005


I'm trying to add data to a portal using a form.  In order to do this, I
have put a form field on my page:

<input type="text" name="pledge_designations::agencyid.0" value="">

When I look at the URL passed in the request, a "_0" has been substituted
for the ".0" before the portal row number, which makes the request invalid:

http://username:password@192.168.0.3:80/fmi/xml/FMPXMLRESULT.xml?-db=unitedw
ay.fp7&-lay=pledges&-max=50&action=edit&screen=3&-recid=&plat=pledges&pledge
_designations::agencyid_0=3&-edit

Any idea why this is happening?

Here's the code I am using to perform the record edit:

    $mod_main = new FX($serverIP, $webCompanionPort, $dataServerType);
    $mod_main->FMUseCURL(false);
    $mod_main->SetDBData($_SESSION['db_filename'], $layout);
    $mod_main->SetDBPassword($password,$DBUser=$user);
    //loop through POST vars and add them to the edit query
   
    foreach ($_POST as $key => $value)
        { 
        
        $mod_main->AddDBParam($key,$value);
        }
         $a_result=$mod_main->FMEdit();
        
         
I have tried printing out the $_POST variables before they are submitted and
the substitution appears to happen before they hit FX, but I cannot find
anything on Google to help me figure out why this is happening.

I am using FMSA7v3 and PhP 4.3.6 on OS 10.3
 
---------------------------------------------------------------------
Marisa Smith, President
DataSmith Consulting, LLC
9206 Huron River Drive
Dexter, MI 48130
Phone & Fax: (734) 426-8077
Cell: (734) 834-2638
http://www.datasmithconsulting.net
Filemaker Solutions Alliance Associate Member




More information about the FX.php_List mailing list