My problem is this. I have the variables $ qr1, $ qr2 and $ qr3, as you can see in the code below, which are only valid when I send the data via post. But I need them to be hidden from the user so they do not think they made a mistake when they entered the page. How can I do this in this code?
<form class="recipiente coluna margem-topo-100" method="post">
<input type="text" name="code" required />
<input type="submit" value="Gerar QR Code" />
<input type="hidden" name="gerar" value="s" />
</form>
<?php
if(isset($_POST['gerar'])) {
require_once "phpqrcode/qrlib.php";
$valor = $_POST['code'];
$code = $valor;
QRcode::png($code, "Imagem_QRCODE_L.png", QR_ECLEVEL_L, 3);
QRcode::png($code, "Imagem_QRCODE_M.png", QR_ECLEVEL_M, 5);
QRcode::png($code, "Imagem_QRCODE_H.png", QR_ECLEVEL_H, 10);
$qr1 = '<img src="Imagem_QRCODE_L.png"/>';
$qr2 = '<img src="Imagem_QRCODE_M.png"/>';
$qr3 = '<img src="Imagem_QRCODE_H.png"/>';
}
?>
<section class="texto-centro margem-topo-50">
<?=$qr1?>
<?=$qr2?>
<?=$qr3?>
</section>