0

テーブルの右側に画像があるテーブルが欲しいです。

これが私が望むものです(ペイントで行いました):

ここに画像の説明を入力

これが私のhtmlです:(「jsp」の「if」は気にしないでください)。たとえば、コードの最後の行 (「if」の後):<td class="noborder"><img src="img/refresh.png" class="refreshButton" alt="Refresh" id="sameRightsAsRefresh" href="Javascript:void;"></img></td>

そしてここにcssがあります:

table td,table th 
{
    border: 1px ridge black;
    padding: 3px;
}

td.noborder {
    border:0
}

SameRightsAs、ユーザー名、および姓の右側でボタンを更新したいと考えています。

完全なコード:

<!-- FIRST TABLE : REQUESTOR -->
            <form id="form" method="post" action="mainServlet?command=FillBlanks&amp;">
                <p class="tableHead">Request For:</p>
                <table class="requestor">

                    <tr>
                        <td class="reqCellLabel">Username:</td>
                        <td class="reqCellAnswer" id="oracleUsername"><input id="oracleUsernameText" class="reqCellAnswer" onchange="fillBlanks(this.id,this.value)"
                            type="text" name="Requestor" <%if( Integer.parseInt(request.getParameter("isCreation")) == 1){%> readonly <%}%>></input></td>
                    </tr>
                    <tr>
                        <td class="reqCellLabel">Oracle Employee #:</td>
                        <td class="reqCellAnswer" id="oracleEmployeeNumber"><input id="oracleEmployeeNumberText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                    </tr>
                    <tr>
                        <td class="reqCellLabel">Last name:</td>
                        <td class="reqCellAnswer" id="lastName"><input id="lastNameText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                    </tr>

                    <tr>
                        <td class="reqCellLabel">First name:</td>
                        <td class="reqCellAnswer" id="firstName"><input id="firstNameText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                    </tr>

                    <tr>
                        <td class="reqCellLabel">Timezone:</td>
                        <td class="reqCellAnswer" id="timeZone"><input id="timeZoneText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                    </tr>

                    <tr>
                        <td class="reqCellLabel">Default Printer:</td>
                        <td class="reqCellAnswer" id="defaultPrinter"><input id="defaultPrinterText" class="reqCellAnswer"
                            type="text" name="Requestor"  value=""></input></td>
                    </tr>
                    <tr>
                        <td class="reqCellLabel">Employee is a buyer ?</td>
                        <td class="reqCellAnswer" id="employeeIsBuyer"><input id="employeeIsBuyerText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                    </tr>
                    <tr>
                        <td class="reqCellLabel">Same rights as :</td>
                        <td class="reqCellAnswer" id="sameRightsAs"><input id="sameRightsAsText" name="sameRightsAsText" class="reqCellAnswer" onchange="sameRightsAs(this.id,this.value)"
                            type="text" name="Requestor" <%if( Integer.parseInt(request.getParameter("isCreation")) == 0){%> disabled <%}%>></input></td>
                        <%if( Integer.parseInt(request.getParameter("isCreation")) == 1){%> <td class="noborder"><img src="img/refresh.png" class="refreshButton" alt="Refresh" id="sameRightsAsRefresh" href="Javascript:void;"></img></td><%}%>
                    </tr>
                </table>

            </form>
</body
4

1 に答える 1

0

このようなもの?すべてのテキスト フィールドに同じ名前が付けられていることに注意してください。フォームを送信すると、最後のフィールドが受け入れられる値になりますが、これは一例です。

<table class="requestor">

                    <tr>
                        <td class="reqCellLabel">Username:</td>
                        <td class="reqCellAnswer" id="oracleUsername"><input id="oracleUsernameText" class="reqCellAnswer" onchange="fillBlanks(this.id,this.value)"
                            type="text" name="Requestor"></input></td>
                        <td class="noborder" id="oracleUsername"><img src="refresh.jpg" width="16" height="16" /></td>
                    </tr>
                    <tr>
                        <td class="reqCellLabel">Oracle Employee #:</td>
                        <td class="reqCellAnswer" id="oracleEmployeeNumber"><input id="oracleEmployeeNumberText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                        <td class="noborder" id="oracleEmployeeNumber">&nbsp;</td>
                    </tr>
                    <tr>
                        <td class="reqCellLabel">Last name:</td>
                        <td class="reqCellAnswer" id="lastName"><input id="lastNameText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                        <td class="noborder" id="lastName">&nbsp;</td>
                    </tr>

                    <tr>
                        <td class="reqCellLabel">First name:</td>
                        <td class="reqCellAnswer" id="firstName"><input id="firstNameText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                        <td class="noborder" id="firstName">&nbsp;</td>
                    </tr>

                    <tr>
                        <td class="reqCellLabel">Timezone:</td>
                        <td class="reqCellAnswer" id="timeZone"><input id="timeZoneText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                        <td class="noborder" id="timeZone">&nbsp;</td>
                    </tr>

                    <tr>
                        <td class="reqCellLabel">Default Printer:</td>
                        <td class="reqCellAnswer" id="defaultPrinter"><input id="defaultPrinterText" class="reqCellAnswer"
                            type="text" name="Requestor"  value=""></input></td>
                        <td class="noborder" id="defaultPrinter">&nbsp;</td>
                    </tr>
                    <tr>
                        <td class="reqCellLabel">Employee is a buyer ?</td>
                        <td class="reqCellAnswer" id="employeeIsBuyer"><input id="employeeIsBuyerText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                        <td class="noborder" id="employeeIsBuyer">&nbsp;</td>
                    </tr>
                    <tr>
                        <td class="reqCellLabel">Same rights as :</td>
                        <td class="reqCellAnswer" id="sameRightsAs"><input id="employeeIsBuyerText" class="reqCellAnswer"
                            type="text" name="Requestor" ></input></td>
                        <td class="noborder" id="sameRightsAs"><img src="refresh.jpg" alt="" width="16" height="16" /></td>

                    </tr>
                </table>
于 2013-02-22T16:28:20.440 に答える