Action route Prestashop FORM 1.7.x

Viewed 28

I find myself learning to develop modules in PrestaShop but not capturing data from a form to work on it in the back

<form action="{$smarty.server.HTTP_HOST}{$smarty.server.REQUEST_URI}" method="post">

<fieldset class="form-group">
<div class="form-group form-group-lg">
 <label class="form-control-label" for="input2">Ingresa tu codigo de seguimiento</label>
 <textarea required name="comment" class="form-control" id="comment"></textarea>
 </fieldset>

<br>
 <input type="submit"  class="btn btn-primary" value="Buscar">
</div>

enter image description here

This is the function where it should receive the data but I don't know why it doesn't work.

 public function getWidgetVariables($hookname, array $configuration){
        if(Tools::isSubmit('comment')){
            return Tools::getAllValues();
        }  
    }

What am I doing wrong? (im using xampp to run in local)

0 Answers
Related