无法编辑Html输入文本

时间:2018-06-14 07:54:05

标签: html5

Add-Type -AssemblyName System.Windows.Forms
Add-Type -AssemblyName System.Drawing

$Exchange_Manager = New-Object Windows.Forms.Form

#Session Initation 1
#1  Set Credentials Button
    $Set_Credential = New-Object System.Windows.Forms.Button
    $Set_Credential.Top = "5"
    $Set_Credential.Left = "5"
    $Set_Credential.Anchor = "Left,Top"
    $Set_Credential.Text = 'Set Credentials'
    $Set_Credential.add_Click({
         $UserCredential = Get-Credential
    })
    $Exchange_Manager.Controls.Add($Set_Credential)
#2  Current Credentials

#3  Connect to Exchange Online
    $Exchange_Connect = New-Object System.Windows.Forms.Button
    $Exchange_Connect.Top = "5"
    $Exchange_Connect.Left = "150"
    $Exchange_Connect.Anchor ="Left,Top"
    $Exchange_Connect.Text = 'Connect' 
    $Exchange_Connect.add_Click({
        $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential "$UserCredential" -Authentication Basic -AllowRedirection
        Import-PSSession $Session
    })
    $Exchange_Manager.Controls.Add($Exchange_Connect)










#Information
#1  Set Credentials Button
    $Mailboxes = New-Object System.Windows.Forms.Button
    $Mailboxes.Top = "50"
    $Mailboxes.Left = "5"
    $Mailboxes.Anchor = "Left,Top"
    $Mailboxes.Text = 'Get All Mailboxes'
    $Mailboxes.add_Click({
         Get-Mailbox |Select-Object DisplayName, Alias | Sort-Object -Property DisplayName | Out-gridview
    })
    $Exchange_Manager.Controls.Add($Mailboxes)




$Exchange_Manager.ShowDialog()

您好我遇到了一个奇怪的问题,即该部分内的输入字段不起作用。已检查删除css,删除部分标记。如果您在页眉或页脚中创建输入文本,那么它可以正常工作。

Textarea工作正常,问题在于输入文本和省下拉选择类型。

1 个答案:

答案 0 :(得分:0)

我只解决了提到的问题。我对内联和主要CSS进行了一些更改和代码。因此设计也发生了变化。我放置了两个单独的部分,一个用于接收者信息,另一部分用于发送者信息。我只编码了接收器部分。我要附加的代码不包含发送方部分。

<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
               <title>OrderForm</title>
    <style>
        header{
            background-color:brown;
            color:cadetblue;
            text-align:center;
            height:100px;
            width:100%;
            border: none;
        }
        section {
            height: auto;
            width: 100%;
            overflow: hidden;
            zoom: 1;
            border: none;
        }
        footer {
            background-color: brown;
            color: cadetblue;
            text-align: center;
            height: 50px;
            width: 100%;
            border: none;
        }
    </style>
</head>

背部                                           我们的快递名称                                        收货人信息:                             收件人姓名:                              

        <span style="margin-left:10px;">
            Receiver's Tel:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            <input type="text" id="receiverTel" style="font-size:20px;height:25px;"/>
        </span>
        </div>

        <br>
        <br>

        <div id="2" style="padding: 30px;">
            To:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            Province&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            <select id="receiverProvince">
                <option value="null">Select</option>
                <option value="ShanDong">ShanDong</option>
            </select>
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            City&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            <select id="receiverCity">
                <option value="null">Select</option>
                <option value="QingDao">QingDao</option>
            </select>
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            Street &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

            <select id="receiverStreet" onchange=getreceive()>
                <option value="null">Select</option>
                <option value="1">ShiNan</option>
                <option value="2">LaoShan</option>
                <option value="3">LiCang</option>
                <option value="4">HuangDao</option>
                <option value="5">ChengYang</option>

            </select>
            </div>

            <br>
            <br>

            <div id="3">
            Detailed Address:
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            <textarea id="receiverAddress" style="height:100px;width:250px;font-size:20px;text-align:center">
                Please write down your receiver's address.
            </textarea>
            </div>

            <br />
            <br />

           <div>
          Time for courier to come:
           <textarea id="comingTime" style="font-size:20px;height:25px;"></textarea>
           </div>

       </section>

     <section>  
     </section>
<footer>
    <h2 style="padding:10px;font-size:25px;">By our group</h2><p id="message"></p>

</footer>