I found the problem.  It was due to the fact that magic_quotes was turned on
on the server and I have no access to disable it.  So I had to do a work
around as follows:

if(get_magic_quotes_gpc() == 1){
switch($REQUEST_METHOD){
case "POST":
while (list ($key, $val) = each ($HTTP_POST_VARS)) {

// Original Code was
// $$key = stripslashes($val);

// New unfinished code.  But works for now.  Could also do the same below
and probably will soon.

             switch (gettype($$key)){
                case 'integer': $$key = stripslashes($val);
                case 'double': $$key = stripslashes($val);
                case 'string': $$key = stripslashes($val);
                case 'array':
  }
}
break;
case "GET":
while (list ($key, $val) = each ($HTTP_GET_VARS)) {
$$key = stripslashes($val);
}
break;
}
}

// And Disable the check for magic quotes

// if(get_magic_quotes_gpc() == 1)
// {

//  print("Warning: magic_quotes_gpc needs to be off for FreeTrade to
function properly.<BR>\n");
//  exit();
// }


Anyway, now it works peachy.  Thanks.

Chuck

----- Original Message -----
From: "Charles Williams ( CEO ACNS )" <[EMAIL PROTECTED]>
To: "FreeTrade" <[EMAIL PROTECTED]>
Sent: Friday, March 02, 2001 10:46 AM
Subject: Re: [FreeTrade] Problems with items not posting to correct
department.


> By using the following I have verified that the array is being passed as a
> string with a value of "Array".
>
>         function dump_array($array_name){
>             switch (gettype($array_name)){
>                 case 'integer':
>                 case 'double':
>                 case 'string': echo "it's a string";
>                      echo $array_name;
>                      break;
>                 case 'array':
>                      echo '<table border="1">\n';
>                      do {
>                          echo '<tr><td align="left" valign="top">';
>                          echo key($array_name);
>                          echo '</td><td>';
>                          dump_array($array_name[key($array_name)]);
>                          echo '</td></tr>';
>                     } while (next($array_name));
>                     echo '</table>';
>                     break;
>                 default:
>                         echo 'Unknow data type.';
>                         break;
>               }
>           }
>
>
>  /*
>  ** Associate with departments.
>  */
>  if ($continueScript)
>  {  dump_array ($inputDepartment);
>   for($index = 0; $index < count($inputDepartment); $index++)
>   {
>
>    $Query = "INSERT INTO department_item VALUES (";
>    $Query .= intval($inputDepartment[$index]) . ", ";
>    $Query .= intval($item);
>    $Query .= ")";
>    if(!mysql_query($Query, $DatabaseLink))
>    {
>     $ActionResults[] = mysql_errno() . ": " . mysql_error() .
>      "   Query was: $repeatQuery";
>     $continueScript = FALSE;
>    }
>   }
>  }
>
> Any ideas what's going on here?
>
> Chuck
>
> ----- Original Message -----
> From: "Charles Williams ( CEO ACNS )" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, March 01, 2001 10:44 PM
> Subject: [FreeTrade] Problems with items not posting to correct
department.
>
>
> > hey all,
> >
> > First post after checking the archives.  Had no luck in the archives but
> did
> > find some things I want to try after I get this working.
> >
> > Problem:  When adding item to the shop it will only be added to the root
> > department (department 0).  Have tried giving a sku, delete and recreate
> > with/without sku.  Nothing works.  You can see the output here.
> >
> > http://www.acns-online.de/shop/index.php3?SCREEN=department
> >
> > Notice the Dexxa Wheel mouse at the bottom?  Well, it should be here.
> >
> >
http://www.acns-online.de/shop/index.php3?SCREEN=department&department=15
> >
> > Any ideas?
> >
> > Chuck
> >
> >
> > ==============================================
> > Charles Williams
> > (Owner)
> > Accent Computer & Network Services
> > Markt 2
> > D-95679 Waldershof
> > Tel: +49 (0) 9231 972670
> > Fax: +49 (0) 9231 972671
> > http://www.acns-online.com
> > GB/CS/O/U d-- -p+ c+++ l++ u- e+ m+ s++/ !n h---- f !g w++ t+ r x**
> > ==============================================
> >
> > **************Email Confidentiality Footer**************
> >
> > The information contained in this email and any attachments is intended
> > for the named recipients only. It may contain privileged and
confidential
> > information and if you are not the intended recipient, you must not
copy,
> > distribute or take any action in reliance on it. If you have received
this
> > email in error, please return it to the originator advising of the error
> > and delete all copies from your system.
> >
> >
> >
> >
> > ------------------------------------------------------------
> > To subscribe:    [EMAIL PROTECTED]
> > To unsubscribe:  [EMAIL PROTECTED]
> > Site:            http://www.working-dogs.com/freetrade/
> > Problems?:       [EMAIL PROTECTED]
> >
>
>
>
> ------------------------------------------------------------
> To subscribe:    [EMAIL PROTECTED]
> To unsubscribe:  [EMAIL PROTECTED]
> Site:            http://www.working-dogs.com/freetrade/
> Problems?:       [EMAIL PROTECTED]
>



------------------------------------------------------------
To subscribe:    [EMAIL PROTECTED]
To unsubscribe:  [EMAIL PROTECTED]
Site:            http://www.working-dogs.com/freetrade/
Problems?:       [EMAIL PROTECTED]

Reply via email to