Symfony variable passing from action to view

theduigirls

New Member
Hello I have the following proble:I have the action class of a view in Symfony, action.class.php, in there i have this code:\[code\]foreach ($images as $i => $img) { if (strstr($request->getFileType($img), 'image')) { $enter = true; $name = Util::processImages($request, $img, 'app_uploads_temp_dir'); if ($name != '') { $userimages[$i] = $name; $this->uploads[$i] = true; $this->message = 'Image loaded'; } }}\[/code\]And in my view I want to render an upload field or a message depending on the case:\[code\]<div class="fotoupload"> <?php if ( !isset($this->uploads[1]) ): ?> <?php echo label_for('photosec1', 'Imagen 2:') ?> <?php echo input_file_tag('photosec1') ?> <?php else: ?> <span><?php $this->message ?></span> <?php endif ?></div>\[/code\]but $this->message is not set, neither is $message or any variable passed from the action, can someone tell me why this happen and how could I solve it??
 
Back
Top