/    Sign up×
Community /Pin to ProfileBookmark

adding text in a DIV layer

Hi friends,

I have such a tag <div id=”MnS”></div>, i use CSS to format this tag.I want to fill in this tag at “page onload” with a Javascript. With javascript i can create a table and fill in it but i couldn’t manage to create a div or fill in an existing div tag. If there is somebody to tell me how to add text in a div tag with scripting i’ll be greatefull

Thanx
Ayhan

to post a comment
JavaScript

2 Comments(s)

Copy linkTweet thisAlerts:
@A1ien51Jul 17.2006 — Basic idea:

document.getElementById("YourId").innerHTML = "foobar";

Eric
Copy linkTweet thisAlerts:
@ayhanauthorJul 17.2006 — That is wonderfull Thanks a lot
×

Success!

Help @ayhan spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.24,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...