PHP notice

Undefined index: product

/var/sentora/hostdata/mihai/public_html/cloud_papionne_com/protected/controllers/MakitoController.php(90)

078         $criteria->addCondition("idExternal='" . $product['ref'] . "'");
079         $criteria->addCondition('idUser=3');
080         $productModel = Product::model()->resetScope()->find($criteria);
081 
082         if ($productModel) {
083             echo $product['ref'] . " exists";
084         }
085 
086         $xmlUrl = "https://frontal.makito.es/epages/Makito.sf/?ObjectPath=/Shops/Makito&ViewAction=ViewXML&tipocatalogo=producto&product=" . $product['ref'] . "&pagina=1&pszinternal=" . $xmlKey . "&ldl=" . $lang;
087         $xml = new JsonSerializer($xmlUrl, 0, true);
088         $product = json_decode(json_encode($xml, JSON_PRETTY_PRINT), 1);
089 
090         if ($product['product'] == "....nothing") {
091             echo " ";
092             exit;
093         }
094 
095 
096         $idExternal = $product['product']['ref'];
097         $code = $product['product']['productcode'];
098         $name = $product['product']['description'];
099         $imagesAndColors = array();
100 
101         if (array_key_exists('image', $product['product']['images'])) // only one image is defined  - see ref: 9350
102         {

Stack Trace

#12
+
 /var/sentora/hostdata/mihai/public_html/cloud_papionne_com/index.php(13): CApplication->run()
08 defined('YII_DEBUG') or define('YII_DEBUG',true);
09 // specify how many levels of call stack should be shown in each log message
10 defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);
11 
12 require_once($yii);
13 Yii::createWebApplication($config)->run();
2020-05-25 20:51:16 Apache Yii Framework/1.1.14
Product not found