Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
Change part of the CSS iwth an <input> box?
Old 06-28-2009, 09:21 PM Change part of the CSS iwth an <input> box?
Physicsguy's Avatar
404 - Title not found

Latest Blog Post:
Challenges
Posts: 824
Name: Scott
Location: Ontario
Trades: 0
Hi,

I'm trying to make a resizable DIV, where you can type in the width and height, and it'll change automatically, before your eyes (without having to reload the page)

Is there a way to do this? Let's just say I have a square that is 100 x 100px. There are two text boxes below it, one showing the height, the other, the width. In the height box, you delete 100 and put in 200. Now the box is 100 x 200px. It does this by changing the box's (the DIV) CSS, because my box has a CSS property that shows how big it is. This CSS file is external, so it's something.css.

Is this possible? I think it is, but I've searched and found nothing.

Thanks!
__________________
Check out my
Please login or register to view this content. Registration is FREE

Last edited by Physicsguy; 06-28-2009 at 09:23 PM..
Physicsguy is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 06-29-2009, 01:20 AM Re: Change part of the CSS iwth an <input> box?
GeekSpecialties's Avatar
Super Talker

Posts: 132
Name: Leonard
Location: Minnesota, USA
Trades: 0
I think you'll need a javascript solution, something like this.
http://www.shawnolson.net/a/503/alte...avascript.html
GeekSpecialties is offline
Reply With Quote
View Public Profile Visit GeekSpecialties's homepage!
 
Old 06-29-2009, 11:01 AM Re: Change part of the CSS iwth an <input> box?
Physicsguy's Avatar
404 - Title not found

Latest Blog Post:
Challenges
Posts: 824
Name: Scott
Location: Ontario
Trades: 0
That works, thanks!!!

I have a problem, though. I'm trying to make a text box in which you type in a number, and click Submit, and a DIV changes it's height or width to what you entered.

Here's my try (look at the source)
http://www.execulink.com/~kayes/physicsguy/web/editor/dragndropeditor.html
I don't get it (the blue box at the bottom is what I'm working on, but all of them at the end will be like that)

It looks like it should work, right? Just a text box in a form, then you click submit, it includes what you typed in (the same concept as my generators) and changes it with the javascript!

Yet it doesn't work! Help!

Thanks
__________________
Check out my
Please login or register to view this content. Registration is FREE

Last edited by Physicsguy; 06-30-2009 at 04:30 PM..
Physicsguy is offline
Reply With Quote
View Public Profile
 
Old 06-30-2009, 04:30 PM Re: Change part of the CSS iwth an <input> box?
Physicsguy's Avatar
404 - Title not found

Latest Blog Post:
Challenges
Posts: 824
Name: Scott
Location: Ontario
Trades: 0
Can anyone help me with my problem above?
__________________
Check out my
Please login or register to view this content. Registration is FREE
Physicsguy is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Change part of the CSS iwth an <input> box?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.19695 seconds with 12 queries