473,498 Members | 1,785 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

changing text with Javascript/DHTML?

Is there a way to change the displayed text on a web page using some
combination of Javascript and DHTML? NOT in a text box. As far as I
know (with my limited knowledge) the only way you can do this is with
a textbox or images, which is not what I'd like to do. There's gotta
be a way to do this, right?
Jul 23 '05 #1
3 1379
In article <73**************************@posting.google.com >, cryan3
@earthlink.net enlightened us with...
Is there a way to change the displayed text on a web page using some
combination of Javascript and DHTML? NOT in a text box. As far as I
know (with my limited knowledge) the only way you can do this is with
a textbox or images, which is not what I'd like to do. There's gotta
be a way to do this, right?


Sure, if you're targeting recent DOM browsers. Put it in a div and use
DOM methods and/or change innerHTML (I prefer DOM methods to just
changin innerHTML).

Can't do it in older browsers very well, but even NN4 could change the
content of a layer.

Netscape/Mozilla:
<http://www.mozilla.org/docs/dom/domref/dom_el_ref.html#1021544>
MSIE:
<http://msdn.microsoft.com/library/default.asp?
url=/workshop/author/dhtml/reference/dhtml_reference_entry.asp>

--
--
~kaeli~
No one is listening until you make a mistake.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

Jul 23 '05 #2
Chris Ryan wrote:
Is there a way to change the displayed text on a web page using some
combination of Javascript and DHTML? NOT in a text box. As far as I
know (with my limited knowledge) the only way you can do this is with
a textbox or images, which is not what I'd like to do. There's gotta
be a way to do this, right?


<url: http://jibbering.com/faq/#FAQ4_15 />

--
Grant Wagner <gw*****@agricoreunited.com>
comp.lang.javascript FAQ - http://jibbering.com/faq
Jul 23 '05 #3
Chris Ryan wrote:
Is there a way to change the displayed text on a web page using some
combination of Javascript and DHTML? NOT in a text box. [...]
There's gotta be a way to do this, right?


There is. And if you would have cared to use the tool that you are
using for posting also for (re)search, you would not have had to ask.
PointedEars
Jul 23 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
2099
by: John Ryan | last post by:
I've a small bit of javascript on my site that has a from with 2 selection boxes, when you choose an option in the first box, the second one re-populates its list accordingly. But the second...
2
1539
by: pablo | last post by:
Dear NGers, I want to keep some images just left of some DIVs. But a change in text size leaves my images at the original position. Which event is generated by changing the text size from the...
3
2209
by: Craig | last post by:
Hi, What I'm trying (quite poorly) to do is make it so when a link is clicked the text inside a div or p changes. I've tried numerous things, most of which work in IE but none of which work in...
14
2464
by: Brandon Hoppe | last post by:
I'm trying to change the src of an ilayer in the parent document from a link inside the ilayer. I'm not able to get it to work. All that happens is Netscape 4 crashes. This is for Netscape 4 only....
24
3456
by: Charles Crume | last post by:
Hello; My "index.htm" page has 3 frames (content, navigation bar, and logo). I set the "SRC" of the "logo" frame to a blank gif image and then want to change it's contents after the other two...
2
5232
by: rpesq | last post by:
Hi, I Need help changing the content of a DIV. I sincerely researched the issue and have not found a solution except to scrap the idea and stick with the iframe code that I had been using. My...
20
2824
by: cwdjrxyz | last post by:
There have been fancy dhtml text effects since the early days of javascript. The rainbow text effect was one of the early ones. While some such effects may be fun on private pages, they can easily...
2
1872
by: sasperilla | last post by:
Hi, I would like to find the coordinates of a word inside a div or span tag. I know you can find the coordinates of a tag inside the DOM, but can you get the coordinates of a portion of the...
4
8500
by: Pete90 | last post by:
I am trying to change the text continously for the text inside a table but it stops after reaching the 2nd index in the array. Anyone can debug? Below are the coding: <script...
0
7121
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6993
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7197
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6881
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5456
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4899
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4584
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
1
650
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
287
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.