MOON
Server: Apache
System: Linux server1.studioinfinity.com.br 2.6.32-954.3.5.lve1.4.90.el6.x86_64 #1 SMP Tue Feb 21 12:26:30 UTC 2023 x86_64
User: artinside (517)
PHP: 7.4.33
Disabled: exec,passthru,shell_exec,system
Upload Files
File: //home/artinside/sites.artinside.com.br/iande/themes/web/batch.php
<?php $this->layout("_theme");
$this->insert("views/page-title", ["pageTitle" => $pageTitle, "breadcrumb" => $breadcrumb]);
?>
<section id="content">
    <div class="content-wrap">

        <div class="section nomargin nobg notoppadding nobottommargin">
            <div class="container clearfix">
                <div class="col-lg-8 center-col center">
                    <small class="text-muted uppercase t300 ls3 d-block">Lote de Produtos</small>
                    <h2 class="t700 ls0 mb-3" style="font-size: 48px; line-height: 1.2">Consulta de Lote</h2>
                        <p class="center">Digite abaixo o Lote do produto para ter acesso a validade do produto.</p>
                    <form id="widget-subscribe-form" action="<?= url("lote")?>" role="form" method="post" class="nobottommargin">
                        <div class="input-group input-group-lg">
                            <input type="text" name="batch_number" class="form-control required addnum" placeholder="Número do Lote" autocomplete="off" >
                            <div class="input-group-append">
                                <button type="submit" class="btn text-white bgcolor px-4" id="inputGroup-sizing-lg">Consultar</button>
                            </div>
                        </div>
                    </form>
                </div>

            </div>
        </div>
        <div class="ajax_fragment">

        </div>

        <div class="footer-stick">
            <?= $this->insert("views/newsletter-widget")?>
        </div>
    </div>
</section><!-- #content end -->



<?php $this->start("scripts"); ?>
<script>


    $('.addnum').keyup(function(){
        var valor_bruto = $('.addnum').val().replace(/[^\d]/g, '');
        var valor = parseInt(0 + valor_bruto);
        var novoValor = pad(valor, 10);
        $('.addnum').val(novoValor);
    });


    $(document).ready(function() {
        $('.addnum').focus(function() { $(this).select(); } );
    });

    function pad (str, max) {
        str = str.toString();
        str = str.length < max ? pad("0" + str, max) : str; // zero à esquerda
        str = str.length > max ? str.substr(0,max) : str; // máximo de caracteres
        return str;
    }



</script>
<?php $this->end(); ?>