提交按钮不起作用

时间:2013-03-21 03:15:33

标签: php html wordpress button submit

我是新的网页设计师,并与Dreamweaver建立了联系页面。当我上传我的博客时,提交按钮不起作用,WordPress中的技术支持说我应该编辑html页面中的空白代码。有人可以帮我吗? 这是我的HTML页面(contact.html):

     <td width="49%" height="336" align="left" valign="middle">
     <form id="form1" name="form1" method="post" action=" wp-includes/pluggable.php">
     <p>
       <label for="name">Name</label>
       <input type="text" name="name" id="name" />
     </p>
     <p>&nbsp;</p>
     <p>
       <label for="email">Email</label>
       <input type="text" name="email" id="email" />
       </p>
     <p><br />
       Comment<br />
       <textarea name="comment" id="comment" cols="45" rows="5"></textarea>
       </p>
     <p>
       <input type="submit" name="submit" id="submit" value="Submit" />
       <input type="reset" name="reset" id="reset" value="Reset" />
     </p>
   </form></td>

这是我的php页面:(wp-includes / pluggable.php)我刚刚在那里输入了我的电子邮件地址:

// From email and name
// If we don't have a name from the input headers
if ( !isset( $from_name ) )
    $from_name = 'WordPress';

/* If we don't have an email from the input headers default to wordpress@$sitename
 * Some hosts will block outgoing mail from this address if it doesn't exist but
 * there's no easy alternative. Defaulting to admin_email might appear to be another
 * option but some hosts may refuse to relay mail from an unknown domain. See
 * http://trac.wordpress.org/ticket/5007.
 */

if ( !isset( $from_email ) ) {
    // Get the site domain and get rid of www.
    $sitename = strtolower( $_SERVER['SERVER_NAME'] );
    if ( substr( $sitename, 0, 4 ) == 'www.' ) {
        $sitename = substr( $sitename, 4 );
    }

    $from_email = 'some_email@somewhere.com' . $sitename;
}

1 个答案:

答案 0 :(得分:1)

尝试从以下位置删除表单操作中的空格:

<form id="form1" name="form1" method="post" action=" wp-includes/pluggable.php">

应该是这样的:

<form id="form1" name="form1" method="post" action="wp-includes/pluggable.php">