/    Sign up×
Community /Pin to ProfileBookmark

Help: container tag content change with data from another HTML file

hi,

I want to dynamically change the content of a container tag (DIV for example) with the data of another container tag present in a different HTML file placed in a different folder

My open HTML file is ‘A.htm’ placed in ‘Folder A’ and container id=’old_data’

My required content is inside the tag with id=’new_data’ present in file ‘B.htm’ and placed in ‘Folder B’

so, code in file A.htm may be

>

document.getElementById(‘old_data’).innerHTML = <<What Comes Here >>

Please Help. And Thank in advance.

–sssun

to post a comment
JavaScript

2 Comments(s)

Copy linkTweet thisAlerts:
@FangFeb 28.2010 — You will have to load the 'Folder B' document into a hidden iframe or object, then extract the required data from it.

Using a server side language would be a better option.
Copy linkTweet thisAlerts:
@sssunauthorMar 01.2010 — ThankQ.

I will try your idea and i'll post back

thanks again
×

Success!

Help @sssun 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 6.17,
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: @nearjob,
tipped: article
amount: 1000 SATS,

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

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...