Jump to content

Recommended Posts

Posted

boa noite,

tenho um form com um botão com visibility:hidden, e queria em certa altura alterar para visivel com php, é possivel?

<input type="submit" name="register" value="register" style="visibility:hidden" />

tentei usar uma variavel $style com valor hidden e visible mas não consegui que funcionasse. Provavelmente não é tão simples assim... tentei procurar no google e n encontrei nada

podem dar-me uma ajudita?

Posted

sim, foi isso que tentei fazer

$style = "hidden";

<input type="submit" name="register" value="register" style="visibility:<?php echo $hidden; ?>" />

também tentei com $style = "visibility:hidden"

bem o mais certo é usar js então..

Posted

não, ele faz a validação se o user existe, se não existir carrega a pagina outra vez e pede para registar...

???

<?php

$style = 'hidden';

?>

<input type="submit" name="register" value="register" style="visibility:<?= $style ?>" />

Fazes echo do $style, não é do hidden.

estava a dormir ainda quando postei  🙂 eu fiz echo à var... mas não estava a dar porque declarei o valor com " "... com ' ' já funcionou  :wallbash:

obrigado a ambos  😉

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.