Trying to access array offset on value of type bool
/usr/hosting/bgpijace.rs/www/yii/protected/models/Barcena.php(229)
217 * @param $pijacaId 218 * @param $namirnicaId 219 */ 220 221 public function vratiCenu($barometarId,$pijacaId,$namirnicaId) 222 { 223 224 $sql = 'SELECT cena_min, cena_max from wp_barcena 225 where barometar_id = :barometarId AND pijaca_id = :pijacaId AND namirnica_id = :namirnicaId'; 226 227 $cene = Yii::app()->db->createCommand($sql)->bindValues(array(':barometarId'=>$barometarId,':pijacaId'=>$pijacaId,':namirnicaId'=>$namirnicaId))->queryRow(); 228 229 if($cene['cena_min'] != $cene['cena_max']) 230 { 231 if($cene['cena_min'] && $cene['cena_max']) 232 { 233 $string = sprintf('%s-%s',$cene['cena_min'],$cene['cena_max']); 234 } 235 else 236 { 237 238 $string = $cene['cena_min']?$cene['cena_min']:$cene['cena_max']; 239 } 240 241
63 echo "<td class='tg-0lax tg-02ax'>".$pijaca->naziv."</td>"; 64 65 foreach($aktivneNamirnice as $aktivnaNamirnica) 66 { 67 68 echo "<td class='tg-0lax tg-03ax'>".$model->vratiCenu($model->barometar_id,$pijaca->pijaca_id,$aktivnaNamirnica->namirnica_id)."</td>"; 69 } 70 echo "</tr>"; 71 72 } 73
121 $data=$_data_; 122 if($_return_) 123 { 124 ob_start(); 125 ob_implicit_flush(false); 126 require($_viewFile_); 127 return ob_get_clean(); 128 } 129 else 130 require($_viewFile_); 131 }
090 { 091 $widgetCount=count($this->_widgetStack); 092 if(($renderer=Yii::app()->getViewRenderer())!==null && $renderer->fileExtension==='.'.CFileHelper::getExtension($viewFile)) 093 $content=$renderer->renderFile($this,$viewFile,$data,$return); 094 else 095 $content=$this->renderInternal($viewFile,$data,$return); 096 if(count($this->_widgetStack)===$widgetCount) 097 return $content; 098 else 099 { 100 $widget=end($this->_widgetStack);
867 */ 868 public function renderPartial($view,$data=null,$return=false,$processOutput=false) 869 { 870 if(($viewFile=$this->getViewFile($view))!==false) 871 { 872 $output=$this->renderFile($viewFile,$data,true); 873 if($processOutput) 874 $output=$this->processOutput($output); 875 if($return) 876 return $output; 877 else
780 */ 781 public function render($view,$data=null,$return=false) 782 { 783 if($this->beforeRender($view)) 784 { 785 $output=$this->renderPartial($view,$data,true); 786 if(($layoutFile=$this->getLayoutFile($this->layout))!==false) 787 $output=$this->renderFile($layoutFile,array('content'=>$output),true); 788 789 $this->afterRender($view,$output); 790
70 71 72 $this->render('index',array( 73 'model'=>$model, 74 'pijace'=>$pijace, 75 'aktivneNamirnice'=>$aktivneNamirnice, 76 )); 77 78 } 79 80 /**
44 $controller=$this->getController(); 45 $method=new ReflectionMethod($controller, $methodName); 46 if($method->getNumberOfParameters()>0) 47 return $this->runWithParamsInternal($controller, $method, $params); 48 49 $controller->$methodName(); 50 return true; 51 } 52 }
303 { 304 $priorAction=$this->_action; 305 $this->_action=$action; 306 if($this->beforeAction($action)) 307 { 308 if($action->runWithParams($this->getActionParams())===false) 309 $this->invalidActionParams($action); 310 else 311 $this->afterAction($action); 312 } 313 $this->_action=$priorAction;
281 * @see runAction 282 */ 283 public function runActionWithFilters($action,$filters) 284 { 285 if(empty($filters)) 286 $this->runAction($action); 287 else 288 { 289 $priorAction=$this->_action; 290 $this->_action=$action; 291 CFilterChain::create($this,$action,$filters)->run();
260 { 261 if(($parent=$this->getModule())===null) 262 $parent=Yii::app(); 263 if($parent->beforeControllerAction($this,$action)) 264 { 265 $this->runActionWithFilters($action,$this->filters()); 266 $parent->afterControllerAction($this,$action); 267 } 268 } 269 else 270 $this->missingAction($actionID);
277 { 278 list($controller,$actionID)=$ca; 279 $oldController=$this->_controller; 280 $this->_controller=$controller; 281 $controller->init(); 282 $controller->run($actionID); 283 $this->_controller=$oldController; 284 } 285 else 286 throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".', 287 array('{route}'=>$route===''?$this->defaultController:$route)));
136 foreach(array_splice($this->catchAllRequest,1) as $name=>$value) 137 $_GET[$name]=$value; 138 } 139 else 140 $route=$this->getUrlManager()->parseUrl($this->getRequest()); 141 $this->runController($route); 142 } 143 144 /** 145 * Registers the core application components. 146 * This method overrides the parent implementation by registering additional core components.
180 public function run() 181 { 182 if($this->hasEventHandler('onBeginRequest')) 183 $this->onBeginRequest(new CEvent($this)); 184 register_shutdown_function(array($this,'end'),0,false); 185 $this->processRequest(); 186 if($this->hasEventHandler('onEndRequest')) 187 $this->onEndRequest(new CEvent($this)); 188 } 189 190 /**
33 YiiBase::autoload($className); 34 } 35 } 36 spl_autoload_unregister(array('YiiBase', 'autoload')); 37 spl_autoload_register(array('Yii','autoload')); 38 Yii::createWebApplication($config)->run();
233 $exception_msg=""; 234 235 try { 236 237 238 eval($content_to_eval); 239 } catch (Throwable $e) { // For PHP 7 and later 240 $exception_occur = 1; 241 $exception_msg = $e->getMessage(); 242 } 243 catch (Exception $e) { // For PHP 5
429 return $return; 430 } 431 432 $content = isset( $m[5] ) ? $m[5] : null; 433 434 $output = $m[1] . call_user_func( $shortcode_tags[ $tag ], $attr, $content, $tag ) . $m[6]; 435 436 /** 437 * Filters the output created by a shortcode callback. 438 * 439 * @since 4.7.0
268 } 269 270 $content = do_shortcodes_in_html_tags( $content, $ignore_html, $tagnames ); 271 272 $pattern = get_shortcode_regex( $tagnames ); 273 $content = preg_replace_callback( "/$pattern/", 'do_shortcode_tag', $content ); 274 275 // Always restore square braces so we don't break things like <!--[if IE ]>. 276 $content = unescape_invalid_shortcodes( $content ); 277 278 // Only remove the filter if it was added in this scope.
319 320 // Avoid the array_slice() if possible. 321 if ( 0 === $the_['accepted_args'] ) { 322 $value = call_user_func( $the_['function'] ); 323 } elseif ( $the_['accepted_args'] >= $num_args ) { 324 $value = call_user_func_array( $the_['function'], $args ); 325 } else { 326 $value = call_user_func_array( $the_['function'], array_slice( $args, 0, $the_['accepted_args'] ) ); 327 } 328 } 329 } while ( false !== next( $this->iterations[ $nesting_level ] ) );
200 } 201 202 // Pass the value to WP_Hook. 203 array_unshift( $args, $value ); 204 205 $filtered = $wp_filter[ $hook_name ]->apply_filters( $value, $args ); 206 207 array_pop( $wp_current_filter ); 208 209 return $filtered; 210 }
251 * 252 * @since 0.71 253 * 254 * @param string $content Content of the current post. 255 */ 256 $content = apply_filters( 'the_content', $content ); 257 $content = str_replace( ']]>', ']]>', $content ); 258 echo $content; 259 } 260 261 /**
21 22 <?php ivanina_tema_post_thumbnail(); ?> 23 24 <div class="entry-content"> 25 <?php 26 the_content(); 27 28 wp_link_pages( array( 29 'before' => '<div class="page-links">' . esc_html__( 'Pages:', 'ivanina-tema' ), 30 'after' => '</div>', 31 ) );
807 do_action( 'wp_before_load_template', $_template_file, $load_once, $args ); 808 809 if ( $load_once ) { 810 require_once $_template_file; 811 } else { 812 require $_template_file; 813 } 814 815 /** 816 * Fires after a template file is loaded. 817 *
740 break; 741 } 742 } 743 744 if ( $load && '' !== $located ) { 745 load_template( $located, $load_once, $args ); 746 } 747 748 return $located; 749 } 750
201 * @param string[] $templates Array of template files to search for, in order. 202 * @param array $args Additional arguments passed to the template. 203 */ 204 do_action( 'get_template_part', $slug, $name, $templates, $args ); 205 206 if ( ! locate_template( $templates, true, false, $args ) ) { 207 return false; 208 } 209 } 210 211 /**
21 <?php 22 // Start the loop. 23 while ( have_posts() ) : the_post(); 24 25 // Include the page content template. 26 get_template_part( 'template-parts/content', 'page' ); 27 28 // If comments are open or we have at least one comment, load up the comment template. 29 if ( comments_open() || get_comments_number() ) : 30 comments_template(); 31 endif;
101 * 102 * @param string $template The path of the template to include. 103 */ 104 $template = apply_filters( 'template_include', $template ); 105 if ( $template ) { 106 include $template; 107 } elseif ( current_user_can( 'switch_themes' ) ) { 108 $theme = wp_get_theme(); 109 if ( $theme->errors() ) { 110 wp_die( $theme->errors() ); 111 }
14 15 // Set up the WordPress query. 16 wp(); 17 18 // Load the theme template. 19 require_once ABSPATH . WPINC . '/template-loader.php'; 20 21 }
12 * @var bool 13 */ 14 define( 'WP_USE_THEMES', true ); 15 16 /** Loads the WordPress Environment and Template */ 17 require __DIR__ . '/wp-blog-header.php';