Question : cakephp3 form control plus traditional php form
Answered by : the-great-man
<div style="display:flex;"> <?php foreach ($product['product_images'] as $productImg) : ?> <div class="container parent"> <div class="row"> <div class='col text-center'> <input type="radio" class="d-none imgbgchk" value="<?= $productImg->id ?>" , name="product_image_id" , controller="ProductOptions" , action="add" , id="<?= $productImg->id ?>"> <label for="<?= $productImg->id ?>"> <?php $imgPath = $this->Url->build('/', true) . 'file/image/products/' . $productImg->product_id . DS . 'small' . DS . $productImg->image; echo $this->Html->image($imgPath, ['width' => '100']); ?> <div class="tick_container"> <div class="tick"><i class="fa fa-check"></i></div> </div> </label> </div> </div> </div> <?php endforeach; ?> </div>
Source : | Last Update : Thu, 30 Jun 22
Question : cakephp create form in different action
Answered by : alimon-pito
echo $this->Form->create($article, ['url' => ['action' => 'publish']]);
Source : https://book.cakephp.org/4/en/views/helpers/form.html | Last Update : Tue, 26 Jul 22