------------------------------------- -------- ------------- ------------------
オブジェクトプロパティ
ウィンドウ //ウィンドウ自体
window.self //このウィンドウを参照 window=window.self
window.name //ウィンドウに名前を付けます
window.defaultStatus // ウィンドウのステータスバー情報を設定します
window.location / /URL アドレス、これを設定します。プロパティは新しいページを開くことができます
-------------------------------------- ----- ---------- --------
オブジェクトメソッド
window.alert("text") //プロンプトメッセージダイアログボックス
window.confirm("text") //確認ダイアログボックス
window.prompt("text") //キーボード入力必須ダイアログボックス
window.setIntervel("action" ,time) //Every 指定した時間 (ミリ秒) ごとに操作を実行します
window.clearInterval() // 時間設定をクリアする機能はサイクルを終了することです
Window.setTimeout(action, time) //指定時間(ミリ秒)経過後 )操作を実行
window.open() //新しいウィンドウを開く
window.close() //ウィンドウを閉じる
----------- -------- ---------------------------------- -------- ---------- --
メンバー オブジェクト
window.event
window.document //詳細はドキュメント オブジェクトを参照
window.history
window.screen
window.navigator
window.external
------------------------------------- ----------- -------------------
window.history object
window.history.length //ページ数seen
history.back( ) //後退
history.forward() //進行
history.go(i) //履歴の i 番目のページに進むか戻ります
//i>0 進歩、私 -------------------------------------- ------------- ------- -------------------
window.screen オブジェクト
ウィンドウ.screen.width //画面の幅
window.screen.height //画面の高さ
window.screen.colorDepth //画面の色の深さ
window.screen.availWidth //利用可能な幅
ウィンドウ。 screen.availHeight //利用可能な高さ(タスクバーの高さを除く)
-------------------------------- ---------------- ---- -------------------
window.external オブジェクト
ウィンドウ.external.AddFavorite("Address", "Title" ) // ウェブサイトをお気に入りに追加
---------------------------- ------------ ---------- -------------------
window.navigator オブジェクト
window.navigator.appCodeName //ブラウザコード名
window.navigator.appName //ブラウザプログラム名
window.navigator.appMinorVersion //ブラウザパッチバージョン
window.navigator.cpuClass //cpuタイプ x86
window.navigator.platform //オペレーティング システムの種類 win32
window.navigator.plugins
window.navigator.opsProfile
window.navigator.userProfile
window.navigator.systemLanguage //顧客システムlanguage zh-cn 簡体字中国語
window.navigator.userLanguage //ユーザー言語、上記と同じ
window.navigator.appVersion //ブラウザのバージョン (システムバージョンを含む)
window.navigator.userAgent
window.navigator.onLine //ユーザーはオンラインですか?
window.navigator.cookieEnabled //ブラウザが Cookie をサポートしているかどうか
window.navigator.mimeTypes
============ ============ ==========================
2.オブジェクト
Object properties:
document.title //Set the document title equivalent to the HTML
document.bgColor //Set the page background color
document.fgColor //Set the foreground color ( Text color)
document.linkColor //Color of links that have not been clicked
document.alinkColor //Color of active links (focus is on this link)
document.vlinkColor //Color of links that have been clicked
document.URL //Set URL properties to open another webpage in the same window
document.fileCreatedDate //File creation date, read-only attribute
document.fileModifiedDate //File modified date, read-only attribute
document.fileSize //File size, read-only attribute
document.cookie //Set and read cookies
document.charset //Set character set Simplified Chinese: gb2312
------ -----------------------
Common object methods
document.write() //Dynamicly write content to the page
document.createElement(Tag) //Create an html tag object
document.getElementById(ID) //Get the object with the specified ID value
document.getElementsByName(Name) //Get the object with the specified Name value
document.body.appendChild(oTag)
body-body sub-object
document.body //Specifying the start and end of the document body is equivalent to
document.body.bgColor //Set or get the background color behind the object
document.body.link //Color of unclicked links
document.body.alink //Activate link (focus is on this link) above)
document.body.vlink //Color of clicked link
document.body.text //Text color
document.body.innerText //Settings...document.body.innerHTML //Set the HTML code between
...document.body.topMargin //The top margin of the page
document.body .leftMargin //Left margin of the page
document.body.rightMargin //Right margin of the page
document.body.bottomMargin //Bottom margin of the page
document.body.background //Background image
document. body.appendChild(oTag) //Dynamicly generate an HTML object
Common object events
document.body.onclick="func()" //Clicking the object with the mouse pointer is triggered
document. body.onmouseover="func()" //Triggered when the mouse pointer moves to the object
document.body.onmouseout="func()" //Triggered when the mouse pointer moves out of the object
location-location sub-object
document.location.hash // The part after #
document.location.host // Domain name port number
document.location.hostname // Domain name
document.location.href // Full URL
document.location.pathname // Directory part
document.location.port // Port number
document.location.protocol // Network protocol (http:)
document.location.search // ? The part after the number
Common object events
documeny.location.reload() //Refresh the web page
document.location.reload(URL) //Open a new web page
document.location .assign(URL) //Open a new web page
document.location.replace(URL) //Open a new web page
==================== ================================================== ===
selection-selection sub-object
document.selection
============================== ==========================================
images collection (in the page images):
----------------------------
a) Reference
document.images through the collection //The corresponding
tag on the page

tags on the corresponding page

tag

tag

b) Directly reference

---------------- through nane attribute ------------
c) Reference the src attribute of the image
document.images.oImage.src //document.images.name attribute.src
----- -----------------------
d) Create an image
var oImage
oImage = new Image()
document .images.oImage.
At the same time, create a
tag on the page corresponding to it to display

Sample code (dynamic creation of images):


はい、JavaScriptのエンジンコアはCで記述されています。1)C言語は、JavaScriptエンジンの開発に適した効率的なパフォーマンスと基礎となる制御を提供します。 2)V8エンジンを例にとると、そのコアはCで記述され、Cの効率とオブジェクト指向の特性を組み合わせて書かれています。3)JavaScriptエンジンの作業原理には、解析、コンパイル、実行が含まれ、C言語はこれらのプロセスで重要な役割を果たします。

JavaScriptは、Webページのインタラクティブ性とダイナミズムを向上させるため、現代のWebサイトの中心にあります。 1)ページを更新せずにコンテンツを変更できます。2)Domapiを介してWebページを操作する、3)アニメーションやドラッグアンドドロップなどの複雑なインタラクティブ効果、4)ユーザーエクスペリエンスを改善するためのパフォーマンスとベストプラクティスを最適化します。

CおよびJavaScriptは、WebAssemblyを介して相互運用性を実現します。 1)CコードはWebAssemblyモジュールにコンパイルされ、JavaScript環境に導入され、コンピューティングパワーが強化されます。 2)ゲーム開発では、Cは物理エンジンとグラフィックスレンダリングを処理し、JavaScriptはゲームロジックとユーザーインターフェイスを担当します。

JavaScriptは、Webサイト、モバイルアプリケーション、デスクトップアプリケーション、サーバー側のプログラミングで広く使用されています。 1)Webサイト開発では、JavaScriptはHTMLおよびCSSと一緒にDOMを運用して、JQueryやReactなどのフレームワークをサポートします。 2)ReactNativeおよびIonicを通じて、JavaScriptはクロスプラットフォームモバイルアプリケーションを開発するために使用されます。 3)電子フレームワークにより、JavaScriptはデスクトップアプリケーションを構築できます。 4)node.jsを使用すると、JavaScriptがサーバー側で実行され、高い並行リクエストをサポートします。

Pythonはデータサイエンスと自動化により適していますが、JavaScriptはフロントエンドとフルスタックの開発により適しています。 1. Pythonは、データ処理とモデリングのためにNumpyやPandasなどのライブラリを使用して、データサイエンスと機械学習でうまく機能します。 2。Pythonは、自動化とスクリプトにおいて簡潔で効率的です。 3. JavaScriptはフロントエンド開発に不可欠であり、動的なWebページと単一ページアプリケーションの構築に使用されます。 4. JavaScriptは、node.jsを通じてバックエンド開発において役割を果たし、フルスタック開発をサポートします。

CとCは、主に通訳者とJITコンパイラを実装するために使用されるJavaScriptエンジンで重要な役割を果たします。 1)cは、JavaScriptソースコードを解析し、抽象的な構文ツリーを生成するために使用されます。 2)Cは、Bytecodeの生成と実行を担当します。 3)Cは、JITコンパイラを実装し、実行時にホットスポットコードを最適化およびコンパイルし、JavaScriptの実行効率を大幅に改善します。

現実世界でのJavaScriptのアプリケーションには、フロントエンドとバックエンドの開発が含まれます。 1)DOM操作とイベント処理を含むTODOリストアプリケーションを構築して、フロントエンドアプリケーションを表示します。 2)node.jsを介してRestfulapiを構築し、バックエンドアプリケーションをデモンストレーションします。

Web開発におけるJavaScriptの主な用途には、クライアントの相互作用、フォーム検証、非同期通信が含まれます。 1)DOM操作による動的なコンテンツの更新とユーザーインタラクション。 2)ユーザーエクスペリエンスを改善するためにデータを提出する前に、クライアントの検証が実行されます。 3)サーバーとのリフレッシュレス通信は、AJAXテクノロジーを通じて達成されます。


ホットAIツール

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

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

Undress AI Tool
脱衣画像を無料で

Clothoff.io
AI衣類リムーバー

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

人気の記事

ホットツール

SublimeText3 Mac版
神レベルのコード編集ソフト(SublimeText3)

SecLists
SecLists は、セキュリティ テスターの究極の相棒です。これは、セキュリティ評価中に頻繁に使用されるさまざまな種類のリストを 1 か所にまとめたものです。 SecLists は、セキュリティ テスターが必要とする可能性のあるすべてのリストを便利に提供することで、セキュリティ テストをより効率的かつ生産的にするのに役立ちます。リストの種類には、ユーザー名、パスワード、URL、ファジング ペイロード、機密データ パターン、Web シェルなどが含まれます。テスターはこのリポジトリを新しいテスト マシンにプルするだけで、必要なあらゆる種類のリストにアクセスできるようになります。

SublimeText3 英語版
推奨: Win バージョン、コードプロンプトをサポート!

AtomエディタMac版ダウンロード
最も人気のあるオープンソースエディター

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

ホットトピック









