I need quick help, its urgent for my job, pls help me.
I need to change the font color, font size & font face of some text assigned in a div. To do so I have a form select option menu at the top, adn below the menu three's 3/4 divs with some text. I need to change text properties of the div from select menu, and the page must not refresh. Its actually a little version of text editor.
I'll be glad if someone solves it ASAP.
koyel555
0
Light Poster
Recommended Answers
Jump to PostYou need to look into JavaScript and DOM. Give you DIV an id and then you can import the DIV as an object with:
div = document.getElementById('div_id');
Then you can change the styles with:
document.getElementById('div_id').color = '#999999';
See this page for …
Jump to PostBut not forgetting ".style"
document.getElementById('div_id').style.color = '#999999';
But I'm sure FlashCreations knows that really.
Koyel555, I think you might need to give your controls some more thought. You say there are several divs and several factors (font, color, size) but you only mention one control - …
All 5 Replies
FlashCreations
20
Posting Whiz
Airshow
416
WiFi Lounge Lizard
Team Colleague
FlashCreations
20
Posting Whiz
Airshow
416
WiFi Lounge Lizard
Team Colleague
FlashCreations
20
Posting Whiz
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.