簡體   English   中英

問題

[英]Issue with <link href hyperlink

我從整個編碼過程開始(很漂亮),但是我發現自己遇到了一個問題。

我找到了一個登陸頁面,並進行了某種程度的復制,它有一個按鈕,可以用作到另一個頁面的超鏈接,但是除了那個按鈕,我還有樣式表的代碼,就像人們必須填寫的表單一樣。 因此,您按下按鈕,表格就會彈出。

我有原始着陸頁的代碼,也有表單的代碼,但我不知道如何將它們融合在一起,請幫忙。

第一個是原始的按鈕代碼,可將人們帶到https://myimstrategy.com/50perday-2/ 我想將該網站替換為彈出的表單。 那是底部的第二個代碼,我不知道如何合並這兩個代碼。 我附加了原始按鈕的圖像。 我不想刪除它,我只想單擊該窗體時將其彈出。

非常感謝您的幫助!

 .el-content{ display: inline-block; width: auto; height: auto; min-width: 894px; min-height: 114px; } .ib2-button { color: rgb(15, 15, 15); background-color: rgb(25, 202, 6); border-color: rgb(0, 174, 0); border-radius: 5px; text-shadow: rgb(147, 138, 138) 1px 1px 0px; background-image: none; min-width: 920px; min-height: 123px; width: auto; height: auto; font-weight: bold; font-size: 80px; } 
 <div class="el-content"> <a href="https://myimstrategy.com/50perday-2/" class="ib2-button open-popup" target="_self">Claim Your Spot Now &gt;&gt;</a> </div> <link href="//app.webinarjam.net/assets/css/register_button.css" rel="stylesheet"> <div style="margin:auto;width:300px;"> <div class="embedded-joinwebinar-button"> <button type="button" class="btn btn-default css3button" title="regpopbox_35246_b21043f77c"> <span>Register now</span> </button> </div> </div> <script src="//cdnjs.cloudflare.com/ajax/libs/jquery/1.11.1/jquery.min.js" language="javascript" type="text/javascript"></script> <script src="//app.webinarjam.net/assets/js/porthole.min.js" language="javascript" type="text/javascript" async></script> <script src="//app.webinarjam.net/register.evergreen.extra.js" language="javascript" type="text/javascript" async></script> 

如果要創建一個彈出窗口,將要使用javascript。 這通常稱為模態。 這是教程的鏈接: 如何使用-CSS / JS Modal

您可以使用引導模式,或添加onclick="showForm()" ,然后將id="form"放入表單。 然后在頭標簽里放

<script>
function showForm(){
    document.getElementById("form").style.display = "inline-block"; //It must have display: none, the form, and this will make it display
}
</script>

我找不到您的圖片,但我知道了,您想在單擊按鈕時顯示一個彈出窗口。 您可以簡單地提供如下所示的href:

<link href="jsFunctionName()" class="buttonClass">Open Form</link>

並嘗試對通過jquery單擊的鏈接使用jquery對話。 https://jqueryui.com/dialog/例如

<script src="https://code.jquery.com/jquery-1.12.4.js"></script>
<script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
  <script>
  $( function jsFunctionName() {
    $("#dialog").dialog();
  } );
</script>

<div id="dialog" title="My Form">
  <form>
  </form>
</div>

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM