CI 3 formv alidation error |
Hello The following script in red is causing a validation error with the form, is there an alternative way for writing this line of code. for some resason i am getting error Item Title is required and all the variable names a re correct i just cant understand. <div class="control-group"> <label class="control-label" for="item_title">Item Title </label> <div class="controls"> <input type="text" class="span6" id="item_title" value ="<?php $item_title; ?>"> the script below is on the same form and it works fine saves to the data base when the above script the view is disabled can someone help me. <div class="control-group hidden-phone"> <label class="control-label" for="textarea2">Textarea WYSIWYG</label> <div class="controls"> <textarea class="cleditor" id="textarea2" rows="3" name ="item_discription"><?php echo $item_discription;?></textarea> </div> </div>
Hey Vincent,
Busted for doing David Connelly's shop tutorials! I don't understand what you mean by 'the view is disabled'. But what you should try is to echo $item_title. Change PHP Code: <input type="text" class="span6" id="item_title" value ="<?php $item_title; ?>"> into PHP Code: <input type="text" class="span6" id="item_title" value ="<?php echo $item_title; ?>"> Does that help? -Roger |
Welcome Guest, Not a member yet? Register Sign In |