======Javascript HTML DOM createElement() Method====== * description : Javascript HTML DOM createElement() Method * author : 오션 * email : shlim@repia.com * lastupdate : 2021-06-03 \\ =====The source of the article==== [[https://www.w3schools.com/jsref/met_document_createelement.asp|Javascript HTML DOM createElement() Method]]\\ ====Example==== %% \\ %%HTML%% 요소에는 종종 텍스트가 포함됩니다. 텍스트가 있는 버튼을 만들려면, 요소 객체의 ''%%innerText%%'' 또는 ''%%innerHTML%%'' 속성을 사용합니다.\\ ====Example==== 텍스트가 있는 버튼을 생성합니다.\\

Click the buton to make a BUTTON element with text.

=====Definition and Usage===== %%createElement()%% 메서드는 지정된 이름을 가진 요소 노드를 만듭니다.\\ \\ **Tip:** 요소가 생성된 후 %%element.appendChild()%% 또는 %%element.insertBefore()%% 메서드를 사용하여 문서에 삽입합니다.\\ =====Syntax===== document.createElement(nodename) =====Parameter Values===== | Parameter | Type | Description | | nodename | String | 필수입니다. 생성하려는 요소의 이름 | =====Technical Details===== Return Value : 요소 객체이며, 생성된 객체 노드를 나타냅니다\\ =====More Examples===== ====Example==== 텍스트가 있는 %%

%% 요소를 만들고, ''%%innerText%%''를 사용하여 텍스트를 설정한 다음, 문서에 덧붙입니다.\\

Click the button to create a P element with some text.

\\ ====Example==== %%

%% 요소를 생성하여 %%

%% 요소에 덧붙입니다.\\

Click the button to create a P element with some text, and append it to DIV.

A DIV element
{{tag>오션, Javascript HTML DOM createElement() Method}}