2017-08-07 128 views
0

在我的插件中,我的表單中有一個動作,它應該帶我到一個名爲go的模板頁面,但是當我點擊它時,wordpress告訴我它不存在,但是如果我刷新該頁面然後加載去頁面。任何想法,爲什麼它不會正常加載和如何解決它?wordpress中的動作模板頁面

<form name="trailer-bulk-waste-free" method="post" action="go"> 
<input type="hidden" name="date" value="<?php echo"$date"; ?>"> 
<input type="hidden" name="pickup" value="<?php echo"$pu" ?>"> 
There is a bunch of other inputs in here but probably redundant to put. 
<p><input type="submit" name="CONTINUE" value="CONTINUE" /> 
+0

你介意包括一些代碼來幫助我們看看你在處理什麼? – Junaid

+0

我也試過有action =「go.php」,但沒有工作加上它需要一個插件才能以.php結尾模板 –

回答

-1

嘗試使用其他瀏覽器查看它是否來自瀏覽器緩存。

+0

嘗試過,並且沒有鍍鉻或E的運氣 –

0

一個簡單而直接的方法是assign the go page template to a page。假設該頁面的ID77,然後執行此操作。

<form name="trailer-bulk-waste-free" method="post" action="<?php the_permalink(77); ?>"> 
    <input type="hidden" name="date" value="<?php echo"$date"; ?>"> 
    <input type="hidden" name="pickup" value="<?php echo"$pu" ?>"> 
    There is a bunch of other inputs in here but probably redundant to put. 
    <p><input type="submit" name="CONTINUE" value="CONTINUE" /></p> 
</form> 

希望這會按照您的預期工作。

+0

好吧,甜甜不適嘗試在哪裏做我得到或如何設置頁面ID? –

+0

這是您創建並分配了「go」模板的頁面ID。它會自動生成。 [檢查這個幫助](https://www.competethemes.com/blog/find-page-id/) – Junaid