/    Sign up×
Community /Pin to ProfileBookmark

iframe in asp.net

i have created an html editor using html and javascript. i have used iframe here. i want to store this iframe content to my database in asp.net with oracle as backend.when i use iframe.innertext ..but its not working…please anyone can help me ??

to post a comment
JavaScript

2 Comments(s)

Copy linkTweet thisAlerts:
@gil_davisOct 31.2007 — The IFRAME is a window and has a DOM just like any window. It is a very bad idea to use a reserved word (iframe) as an identifier. However, tryiframe.document.getElementsByTagName["body"][0].innerHTMLIf that doesn't work, tell us how you are putting the data into the IFRAME.

BTW, "innerText" is an IE only property that you should avoid.
Copy linkTweet thisAlerts:
@niranjanaauthorOct 31.2007 — i will explain what i am doing actually...

i am creating a blog like application in asp.net with vb.net as code behind.

there, for posting blogs i want to create an html editor . i have successfully created the editor using html and javascript. but the problem comes when i was about to insert the data from an iframe to oracle table. in code behind i have used the code like this...

dim cn as new oledbconnection("provider=msdaora.1;user id=scott;password=tiger;data source=ora")

dim s as string

s="insert into blog values(' " +iview.innertext+ " ')

dim cmd as new oledbcommand(s,cn)

cmd.executenonquery()

blog->table name

iview->iframe id(i have made iframe as server control using runat=server)

but whenever i run the application empty value is inserted into the database

it is not taking the content inside my iframe...

this is the problem...can you help me

thanks & regards

niranjana
×

Success!

Help @niranjana 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.13,
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,
)...