[FX.php List] Searching...

Baard Belsaas fmweb at belsaas.no
Mon Nov 22 16:09:09 MST 2004


It is planed that you schoud log in with IDnr and Fodt (born-date). But this
is not in work yet because I get this trole for searching number-fields.

Here is my code:
<?php
include_once('FX/FX.php');
include_once('FX/FMErrors.php');
include_once('FX/server_data.php');

$IDnr=$_POST['IDnr'];
$Fodt=$_POST['Fodt'];

$search=new FX($serverIP,$webCompanionPort);
$search->setDBData('Medlemsbase.fp7','web');
$search->AddDBParam('IDnr',$IDnr);
$searchResult=$search->FMFind();
?>
</head>

<body>
<?php
include_once("includes/header.php");
?>

Found Count: <?php echo $searchResult['foundCount']; ?><br>
Error: <?php echo $searchResult['errorCode']; ?><br>S&oslash;k: <?php echo
$IDnr; ?> <br>
        F&oslash;dt: <?php echo $Fodt; ?>
<?php
include_once("./includes/search_result_yes.php");
?>


The include-file is this:
<?php
foreach($searchResult['data'] as $key=>$searchData) {
?>
        <table width="250" border="1" cellspacing="2" cellpadding="0">
            <tr>
                <td width="100">
                    <div align="right">
                        <b>IDnr</b></div>
                </td>
                <td><?php echo $searchData['IDnr'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>F&oslash;dt</b></div>
                </td>
                <td><?php echo $searchData['Fodt'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Type medlem</b></div>
                </td>
                <td><?php echo $searchData['Type_medlem'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Navn</b></div>
                </td>
                <td><?php echo $searchData['Navn'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Medlems adresse</b></div>
                </td>
                <td><?php echo $searchData['Medlem_adresse'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Postnummer</b></div>
                </td>
                <td><?php echo $searchData['Postnr'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Poststed</b></div>
                </td>
                <td><?php echo $searchData['Poststed'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Land</b></div>
                </td>
                <td><?php echo $searchData['Land'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Mobil</b></div>
                </td>
                <td><?php echo $searchData['Mobil'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Telefon privat</b></div>
                </td>
                <td><?php echo $searchData['Tlf_priv'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Arbeidsgiver</b></div>
                </td>
                <td><?php echo $searchData['Arbeidsgiver'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Arbeidssted</b></div>
                </td>
                <td><?php echo $searchData['Arbeidssted'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Telefon arbeide</b></div>
                </td>
                <td><?php echo $searchData['Tlf_arb'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Telefaks arbeide</b></div>
                </td>
                <td><?php echo $searchData['Faks_arb'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Epost</b></div>
                </td>
                <td><?php echo $searchData['Epost'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Stillingskode</b></div>
                </td>
                <td><?php echo $searchData['Stillingskode'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Stilling</b></div>
                </td>
                <td><?php echo $searchData['Stilling'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>Stillingsprosent</b></div>
                </td>
                <td><?php echo $searchData['Stillingsprosent'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>&Aring;rsl&oslash;nn</b></div>
                </td>
                <td><?php echo $searchData['Aarslonn_100P'] [0]; ?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                        <b>L&oslash;nnsramme-alternativ</b></div>
                </td>
                <td><?php echo $searchData['Lonnsrammealternativ'] [0];
?></td>
            </tr>
            <tr>
                <td width="100">
                    <div align="right">
                  
                    </div>
                </td>
                <td><a href="edit.php?recid=<?php
                $recordDetails=explode('.',$key);
                $currentRecord=$recordDetails[0];
                echo $currentRecord;
                ?>"><img src="./images/detail.gif"></td>
            </tr>
            <?php
}
?>
    
        </table>



På 22-11-04 18:39, skrev "Dale Bengston" <dbengston at preservationstudio.com>:

> In FM6 you could get around this by storing the default language for
> indexing and storing to ASCII. That option is gone for FM7; perehaps
> Unicode produces the same results?
> 
> Also, Baard, please post your code that queries FX.
> 
> Dale
> --
> Dale Bengston | Streamline Studio, LLC | dbengston at streamline-studio.com
> Associate Member, FileMaker Solutions Alliance
> 
> On Nov 22, 2004, at 9:41 AM, Milos Vukotic wrote:
> 
>> Not just number-fields, any fields with particular characters (like
>> "@")... Look at my previous posts.
>> There is NO good work around in FM7.  Maybe after v9 everything will
>> work as it is supposed to!?
>> 
>> Cheers,
>> Milosh
>> --
>> Milos Vukotic
>> Software Engineer
>> MC Services
>> http://www.mcservices.com
>> 
>> Baard Belsaas wrote:
>> 
>>> Hello, I have made my first fx-site in FM5, and get it working!
>>> Now I have converted this to FM7. After a bit of troubles I can
>>> acsess the
>>> database from the site, and searching on a text-filed is ok. But when
>>> I
>>> search on a number-filed its "game over"; the found counter is "-1"
>>> and the
>>> current error=401.
>>> 
>>> Search is the same to number- or textfield? Or have I sleeping in my
>>> fx-lessons?
>>> 
>>> 
>>> In kindness
>>> Baard Belsaas
>>> 
>>> 
>>> _______________________________________________
>>> FX.php_List mailing list
>>> FX.php_List at mail.iviking.org
>>> http://www.iviking.org/mailman/listinfo/fx.php_list
>>> 
>>> 
>> 
>> _______________________________________________
>> FX.php_List mailing list
>> FX.php_List at mail.iviking.org
>> http://www.iviking.org/mailman/listinfo/fx.php_list
>> 
> 
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list
> 




More information about the FX.php_List mailing list