doufan6544 2014-12-02 16:28
浏览 32
已采纳

通过单击一页内的特定链接显示不同的Html表单

i has file within my wordpress theme this file contains the signin, signup, lostpasswors and reset password forms with the required php codes. and in my header i have two buttons created by bootstrap codes us follow.

<div class="col-sm-3">
    <div id="user-notlogged-in" class="pull-right btn-group btn-group-lg" role="group">
        <button type="button" class="btn btn-info"><a class="signin" href="<?php echo bloginfo('url') ?>/login"><?php _e('Sign In'); ?></a></button>
        <button type="button" class="btn btn-default"><a class="signup" href="<?php echo bloginfo('url') ?>/login"><?php _e('Sign up'); ?></a></button>
    </div>
</div>

and in my login-register.php file i have above forms like below

<div id="signin-form">
</div>
<div id="signup-form">
</div>
<div id="resetpass-form">
</div>
<div id="newpass-form">
</div>

this link below contains full code in my login-register.php file login-register.php my questions

  1. i want when click on Sign In link only show me signin-form
  2. i want when click on Sign Up link only show me signup-form
  3. i want when i click on Lost Password? Link only show me resetpass-form
  4. i want when send me reset password mail and i clcik on reset password link only show me newpass-form
  • 写回答

2条回答 默认 最新

  • duanji8887 2014-12-02 16:39
    关注

    What you're looking for is some simple jquery. Try something like...

    onclick=$('#signin-form').show();
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 如何在scanpy上做差异基因和通路富集?
  • ¥20 关于#硬件工程#的问题,请各位专家解答!
  • ¥15 关于#matlab#的问题:期望的系统闭环传递函数为G(s)=wn^2/s^2+2¢wn+wn^2阻尼系数¢=0.707,使系统具有较小的超调量
  • ¥15 FLUENT如何实现在堆积颗粒的上表面加载高斯热源
  • ¥30 截图中的mathematics程序转换成matlab
  • ¥15 动力学代码报错,维度不匹配
  • ¥15 Power query添加列问题
  • ¥50 Kubernetes&Fission&Eleasticsearch
  • ¥15 報錯:Person is not mapped,如何解決?
  • ¥15 c++头文件不能识别CDialog