Jump to content

Recommended Posts

Fatal error: Unsupported operand types in /mnt/maindisk/var/opt/cvs/ytlhpcps.ytlhotels.com/html/training/ytlhpcps/reports/total_purchase_stock_item.qty.supp.php on line 1096

 

 

This the code..

 

 

                    $rpt_filter_by_html_rec .= "";

 

 

 

 

                foreach($description_arr as $key_d=>$val_d){

                        if ($tmp_total[$key0][$val1][$val_d]['val']['qty']){

                            $rpt_filter_by_html_rec .= "<br>";

                            $rpt_filter_by_html_rec .= "<table cellpadding='0' cellspacing='0' border='1' width='100%' class='description_row'>"; //echo "$description_arr<br /> ";

             

                  foreach($measurement_tbl_title as $key_h=>$val_h){

                                $rpt_filter_by_html_rec .= "<tr>";

                                $rpt_filter_by_html_rec .= "<td>$val_h</td>"; //print "<pre>"; print_r($val_h);print "</pre>";       

             

                        if ($key_h == 'Item'){

                          $rpt_filter_by_html_rec .= "<td style='width:50px;text-align:left;'>$val_d</td>";

                                //print "<pre>"; print_r($val_d);print "</pre>";

                                }

                       

                        elseif ($key_h == 'Measurement'){

                        foreach($measurement_arr as $key_m=>$val_m){ 

                              if ($key_m == $key_d){

                                    $rpt_filter_by_html_rec .= "<td style='width:50px;text-align:center;'>$val_m</td>";

                          //print "<pre>"; print_r($val_m);print "</pre>";

                                }}}

                       

                        elseif ($key_h == 'Avg'){

                                    $tmp_amt = $tmp_total[$key0][$val1][$val_d]['val']['amt'];

                                    $tmp_qty = $tmp_total[$key0][$val1][$val_d]['val']['qty'];

                                    $rpt_filter_by_html_rec .= "<td style='width:50px;text-align:right;'>".number_format(round($tmp_amt/$tmp_qty,2), 2, ".", ",")."</td>";-----LINE 1096

                                }

                       

                        else{

                                    $tmp_field = $tmp_total[$key0][$val1][$val_d]['val'][strtolower($key_h)];

                                    $rpt_filter_by_html_rec .= "<td style='width:50px;text-align:right;'>".number_format($tmp_field, 2, ".", ",")."</td>"; //print "<pre>"; print_r($tmp_field);print "</pre>";

                                }

                                $rpt_filter_by_html_rec .= "</tr>";

                       

                        }  //close measurement_tbl_title

                            $rpt_filter_by_html_rec .= "</table>";

              } // close if tmp_total

                         

                }  //close measurement_arr

//}}}

                } // close description_arr

            //}}

            //if(empty ($key_h)) {

            //$rpt_filter_by_html_rec .= "<td>   </td>";}

 

 

                $rpt_filter_by_html_rec .= "</td>";

            } // close foreach property_arr

        }[/s]

 

do help me please............. ;)

Link to comment
https://forums.phpfreaks.com/topic/134301-fatal-error-unsupported-operand-types/
Share on other sites

Fatal error: Unsupported operand types in /mnt/maindisk/var/opt/cvs/ytlhpcps.ytlhotels.com/html/training/ytlhpcps/reports/total_purchase_stock_item.qty.supp.php on line 1096

 

 

This the code..

 

 

                    $rpt_filter_by_html_rec .= "";

 

 

 

 

                foreach($description_arr as $key_d=>$val_d){

                        if ($tmp_total[$key0][$val1][$val_d]['val']['qty']){

                            $rpt_filter_by_html_rec .= "<br>";

                            $rpt_filter_by_html_rec .= "<table cellpadding='0' cellspacing='0' border='1' width='100%' class='description_row'>"; //echo "$description_arr<br /> ";

             

                  foreach($measurement_tbl_title as $key_h=>$val_h){

                                $rpt_filter_by_html_rec .= "<tr>";

                                $rpt_filter_by_html_rec .= "<td>$val_h</td>"; //print "<pre>"; print_r($val_h);print "</pre>";       

             

                        if ($key_h == 'Item'){

                          $rpt_filter_by_html_rec .= "<td style='width:50px;text-align:left;'>$val_d</td>";

                                //print "<pre>"; print_r($val_d);print "</pre>";

                                }

                       

                        elseif ($key_h == 'Measurement'){

                        foreach($measurement_arr as $key_m=>$val_m){ 

                              if ($key_m == $key_d){

                                    $rpt_filter_by_html_rec .= "<td style='width:50px;text-align:center;'>$val_m</td>";

                          //print "<pre>"; print_r($val_m);print "</pre>";

                                }}}

                       

                        elseif ($key_h == 'Avg'){

                                    $tmp_amt = $tmp_total[$key0][$val1][$val_d]['val']['amt'];

                                    $tmp_qty = $tmp_total[$key0][$val1][$val_d]['val']['qty'];

                                    $rpt_filter_by_html_rec .= "<td style='width:50px;text-align:right;'>".number_format(round($tmp_amt/$tmp_qty,2), 2, ".", ",")."</td>";-----LINE 1096

                                }

                       

                        else{

                                    $tmp_field = $tmp_total[$key0][$val1][$val_d]['val'][strtolower($key_h)];

                                    $rpt_filter_by_html_rec .= "<td style='width:50px;text-align:right;'>".number_format($tmp_field, 2, ".", ",")."</td>"; //print "<pre>"; print_r($tmp_field);print "</pre>";

                                }

                                $rpt_filter_by_html_rec .= "</tr>";

                       

                        }  //close measurement_tbl_title

                            $rpt_filter_by_html_rec .= "</table>";

              } // close if tmp_total

                         

                }  //close measurement_arr

//}}}

                } // close description_arr

            //}}

            //if(empty ($key_h)) {

            //$rpt_filter_by_html_rec .= "<td>   </td>";}

 

 

                $rpt_filter_by_html_rec .= "</td>";

            } // close foreach property_arr

        }[/s]

 

do help me please............. ;)

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.