図に示すような効果を実現するには:
表の幅をパーセント値に設定し、その幅をページの幅に合わせて変更します。入力は td の幅全体を占めます。
メインの HTML コードは次のとおりです:
<form action=""> <table class="form"> <tr> <td colspan="3"><input type="text" placeholder="姓名" name="username" id="user"/><span></span></td> </tr> <tr> <td colspan="3"><input type="text" placeholder="公司名称" name="company" id="company"/><span></span></td> </tr> <tr> <td colspan="3"><input type="text" placeholder="国家/地区" name="area" id="area"/><span></span></td> </tr> <tr> <td colspan="3"><input type="phone" placeholder="手机" name="phone" id="phone"/><span></span></td> </tr> <tr> <td colspan="3"><input type="email" placeholder="电子邮箱" name="email" id="email"/><span></span></td> </tr> <tr> <td colspan="3"><input type="text" placeholder="确认邮箱" name="email-c" id="email-c"/><span></span></td> </tr> <tr> <td class="r-box pl8" width="37%">是否开具发票</td><td class="r-box" width="21.9%"><label for="bill_y" class="r-label checked"><input type="radio" name="bill" id="bill_y"/>是</label></td><td class="r-box"><label for="bill_n" class="r-label"><input type="radio" name="bill" id="bill_n"/>否</label></td></td> </tr> <tr> <td colspan="3"><input type="text" placeholder="抬头"/><span></span></td> </tr> <tr> <td colspan="3" class="pb6"><input type="text" placeholder="联系地址"/><span></span></td> </tr> <tr> <td colspan="3"><input type="submit" value="继续"/></td> </tr> </table></form>
メインの scss スタイルは次のとおりです:
.form{ width: 96%; margin: 0.3rem auto; font-size: 0.7rem; td{ height: 2.5rem; } input{ font-family: "Microsoft Yahei"; outline: none; color: #d8d8d8; } input[type=text],input[type=phone],input[type=email]{ border: 1px solid #e10000; height: 1.55rem; line-height: 1.55rem; padding-left: 0.4rem; width: 100%; box-sizing: border-box; background: transparent; }

Web開発におけるHTML、CSS、およびJavaScriptの役割は次のとおりです。1。HTMLは、Webページ構造の構築に使用されます。 2。CSSは、Webページの外観を美化するために使用されます。 3. JavaScriptは、動的な相互作用を実現するために使用されます。タグ、スタイル、スクリプトを通じて、これら3つは最新のWebページのコア関数を構築します。

タグのLang属性を設定することは、WebアクセシビリティとSEOを最適化する重要なステップです。 1)ラング属性をタグに設定します。 2)多言語コンテンツでは、ようなさまざまな言語パーツのLang属性を設定します。 3)「EN」、「FR」、「ZH」などのISO639-1標準に準拠する言語コードを使用します。Lang属性を正しく設定すると、Webページと検索エンジンランキングのアクセシビリティが向上します。

htmlattributeSareSientionalentionalentionalentionalentiallyance'functionalityandappearance.theyaddinformationtodefinebehavior、light、and interaction、makewebsitesteractive、responsive、andviseallyappaleal.attributeslikesrc、href、class、型、およびdoadabledransform

toreatealistinhtml、useforunorderedlistsandfororderedlists:1)forunorderedlists、wrapitemsinanduseforeachitem、renderingasabulletedlist.2)

HTMLは、明確な構造のWebサイトを構築するために使用されます。 1)Webサイト構造などのタグを使用し、定義します。 2)例は、ブログとeコマースのウェブサイトの構造を示しています。 3)誤ったラベルネスティングなどの一般的な間違いを避けてください。 4)HTTP要求を削減し、セマンティックタグを使用してパフォーマンスを最適化します。

to inertanimageintoanhtmlpage、usethetagwithsrcandaltattributes.1)usealttextforaccessibilityandseo.2)emplencesrcsetForresponsiveimages.3)applylazyloadingwithloading = "lazy" tooptimizeperformance.4)

HTMLの中心的な目的は、ブラウザがWebコンテンツを理解して表示できるようにすることです。 1。HTMLは、タグなどのタグを介してWebページの構造とコンテンツを定義します。 3.HTMLは、ユーザーの相互作用をサポートするフォーム要素を提供します。 4. HTMLコードの最適化は、HTTP要求の削減やHTMLの圧縮など、Webページのパフォーマンスを改善できます。

htmltagsareSterenceforwebdevelovementasyStheStructureanhandhancewebpages.1)theydefineLayout、semantics、and-interactivity.2)semanticagsimprovecessibility.3)opeusofusofagscanoptimizeperformanceandensurecross-brows-compativeation。


ホットAIツール

Undresser.AI Undress
リアルなヌード写真を作成する AI 搭載アプリ

AI Clothes Remover
写真から衣服を削除するオンライン AI ツール。

Undress AI Tool
脱衣画像を無料で

Clothoff.io
AI衣類リムーバー

Video Face Swap
完全無料の AI 顔交換ツールを使用して、あらゆるビデオの顔を簡単に交換できます。

人気の記事

ホットツール

mPDF
mPDF は、UTF-8 でエンコードされた HTML から PDF ファイルを生成できる PHP ライブラリです。オリジナルの作者である Ian Back は、Web サイトから「オンザフライ」で PDF ファイルを出力し、さまざまな言語を処理するために mPDF を作成しました。 HTML2FPDF などのオリジナルのスクリプトよりも遅く、Unicode フォントを使用すると生成されるファイルが大きくなりますが、CSS スタイルなどをサポートし、多くの機能強化が施されています。 RTL (アラビア語とヘブライ語) や CJK (中国語、日本語、韓国語) を含むほぼすべての言語をサポートします。ネストされたブロックレベル要素 (P、DIV など) をサポートします。

VSCode Windows 64 ビットのダウンロード
Microsoft によって発売された無料で強力な IDE エディター

メモ帳++7.3.1
使いやすく無料のコードエディター

MantisBT
Mantis は、製品の欠陥追跡を支援するために設計された、導入が簡単な Web ベースの欠陥追跡ツールです。 PHP、MySQL、Web サーバーが必要です。デモおよびホスティング サービスをチェックしてください。

ゼンドスタジオ 13.0.1
強力な PHP 統合開発環境
