/** * este metodo se encarga de pintar el html de la vista por defcto para inmueble, que es el listado. */ public function index() { if (Session::get("auth")) { header('Location: ' . URL . 'news/'); } else { //MUETRA LOS ERRORES, EN EL MEtODO INDEX ESTA EL BLOQUE errors_row $this->initializeTpl("pagina", "Login"); $this->_tpl->assign('header_login', Idioma::get("header_login")); if (Session::get('errors')) { $arr_temp = Session::getAndDestroy('errors'); foreach ($arr_temp as $value) { $this->_tpl->newBlock('errors_row'); $this->_tpl->assign("salida", $value); } } $this->_tpl->printToScreen(); } }
<!-- in case of ajax request <form action= "#" id="form-create-todo" method="post"> <label>Content <span class="text-danger">*</span></label> <textarea name="content" class="form-control" required placeholder="What are you thinking?"></textarea> <button type="submit" name="submit" value="submit" class="btn btn-success">Create</button> </form> --> <br> <?php // display success or error messages in session if (!empty(Session::get('success'))) { echo $this->renderSuccess(Session::getAndDestroy('success')); } else { if (!empty(Session::get('errors'))) { echo $this->renderErrors(Session::getAndDestroy('errors')); } } ?> <br><hr><br> <ul id="todo-list"> <?php $todoData = $this->controller->todo->getAll(); foreach ($todoData as $todo) { ?> <li> <p> <?php echo $this->autoLinks($this->encodeHTMLWithBR($todo["content"])); ?>
" /> </div> <div class="form-group form-actions text-right"> <button type="submit" name="submit" value="submit" class="btn btn-md btn-success"> <i class="fa fa-check"></i> Send </button> </div> </form> <?php } else { echo $this->renderSuccess(Session::getAndDestroy('report-bug-success')); } ?> <?php if (!empty(Session::get('report-bug-errors'))) { echo $this->renderErrors(Session::getAndDestroy('report-bug-errors')); } ?> </div> <!-- /.col-lg-6 (nested) --> </div> <!-- /.row (nested) --> </div> <!-- /.panel-body --> </div> </div> <!-- END Newsfeed Block --> </div> <!-- /.row --> </div> <!-- /#page-wrapper -->
?> " class="btn btn-danger restore-backup" > <i class="fa fa-rotate-left"></i> </a> </span> </td> </tr> </tbody> </table> <?php if (!empty(Session::get('backup-errors'))) { echo $this->renderErrors(Session::getAndDestroy('backup-errors')); } else { if (!empty(Session::get('backup-success'))) { echo $this->renderSuccess(Session::getAndDestroy('backup-success')); } } ?> </div> <!-- /.table-responsive --> </div> <!-- /.panel-body --> </div> </div> <!-- END Newsfeed Block --> </div> <!-- /.row --> </div> <!-- /#page-wrapper -->
</div> <div class="form-group"> <input type="hidden" name="csrf_token" value="<?php echo Session::generateCsrfToken(); ?> " /> </div> <div class="form-group form-actions text-right"> <button type="submit" value="submit" class="btn btn-md btn-primary"> <i class="fa fa-upload"></i> Upload </button> </div> </form> <?php if (!empty(Session::get('profile-picture-errors'))) { echo $this->renderErrors(Session::getAndDestroy('profile-picture-errors')); } ?> </div> <!-- /.col-lg-6 (nested) --> </div> <!-- /.row (nested) --> </div> <!-- /.panel-body --> </div> </div> <!-- END Profile Block --> </div> <!-- /.row --> </div>
</div> <div class="form-group form-actions text-right"> <button type="submit" name="submit" value="submit" class="btn btn-sm btn-success"> <i class="fa fa-check"></i> Resiger </button> </div> <div class="form-group"> Have an account? <a id="link-login" href="javascript:void(0)">Login</a> </div> </fieldset> </form> <?php } else { echo $this->renderSuccess(Session::getAndDestroy('register-success')); } ?> <?php if (!empty(Session::get('register-errors'))) { echo $this->renderErrors(Session::getAndDestroy('register-errors')); } ?> </div> </div> </div> </div> </div>
<input type="hidden" name="token" value="<?php echo $this->encodeHTML($this->controller->request->query("token")); ?> " /> </div> <div class="form-group"> <input type="hidden" name="csrf_token" value="<?php echo Session::generateCsrfToken(); ?> " /> </div> <div class="form-group form-actions text-right"> <button type="submit" name="submit" value="submit" class="btn btn-md btn-success"> <i class="fa fa-check"></i> Update </button> </div> </fieldset> </form> <?php if (!empty(Session::get('update-password-errors'))) { echo $this->renderErrors(Session::getAndDestroy('update-password-errors')); } ?> </div> </div> </div> </div> </div>
</div> <div class="form-group"> <input type="hidden" name="csrf_token" value="<?php echo Session::generateCsrfToken(); ?> " /> </div> <div class="form-group form-actions text-right"> <button type="submit" name="submit" value="submit" class="btn btn-md btn-success"> <i class="fa fa-check"></i> Share </button> </div> </form> <?php if (!empty(Session::get('newsfeed-errors'))) { echo $this->renderErrors(Session::getAndDestroy('newsfeed-errors')); } ?> </div> <!-- /.col-lg-6 (nested) --> </div> <!-- /.row (nested) --> </div> <!-- /.panel-body --> </div> <hr> <!-- News Feed Block --> <div class="panel panel-default"> <!-- News Feed Title --> <div class="panel-heading">