#1 (permalink)  
Old 09-07-2008, 12:11 AM
Registered User
 
Join Date: Apr 2007
Location: Australia
Posts: 20
text box data loaded from external css

Is it posbile to declare an id # in an external CSS which contains text that I want to display in a text box. ?

rob
Reply With Quote

  #2 (permalink)  
Old 09-07-2008, 10:48 AM
curtiss's Avatar
Moderator
 
Join Date: May 2003
Posts: 1,438
No, not really. CSS is intended to control the appearance of a page. It has nothing to do with the content. There are some tricks you can use to add a small bit of content to various items, but implementation within browsers is still very spotty (and not supported at all within IE, yet).

It sounds to me as though you are actually looking for something that you would need to use either Javascript or a server-side script (like PHP, .NET, perl, etc.) to do.
__________________
I hate Internet Explorer! Anyone with me?
Reply With Quote
  #3 (permalink)  
Old 09-09-2008, 05:44 AM
Registered User
 
Join Date: Apr 2007
Location: Australia
Posts: 20
I understand CSS is not the answer now... However a work around which I got seems to achieve what I was looking for.. Thanks Scott

// Begin Javascript Include file owValues.js/////////////////////////////
device1 = new Object;
device1.parameter1 = 25;
device1.parameter2 = "some owfs read value";
device1.parameter3 = "some owfs read value";

device2 = new Object;
device2.parameter1 = 59;

device3 = new Object;
device3.parameter1 = 63;
// End Javascript Include file owValues.js/////////////////////////////


To output the owfs read values in your HTML, you'd do something like:

// Begin HTML file display.htm/////////////////////////////
<HTML>
<HEAD>
<SCRIPT language="javascript" src="owValues.js"></SCRIPT>

</HEAD>
<BODY>

<h3>Here are the owfs values</h3>

<SCRIPT language="javascript">
document.write('<p>Device1 Temp: ' + device1.parameter1 + '</p>');
document.write('<p>Device2 Temp: ' + device2.parameter1 + '</p>');
</SCRIPT>
<DIV> some more web content goes here. You can output OWFS data from your include file anywhere you like.</DIV>
<DIV>The memory pages of device1 contents:
<B>
<SCRIPT language="javascript">
document.write(device1.parameter2);
</SCRIPT>
</B>
</DIV>
</BODY>
</HTML>
// End HTML file display.htm/////////////////////////////
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

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 On
Pingbacks are On
Refbacks are On
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Advantages of external stylesheets? curtiss Programming and Scripting 6 06-06-2008 10:16 PM
css stylesheet issue cross browsers?????? rjennings_76 Programming and Scripting 2 05-23-2008 06:20 PM
CSS Tips & Tricks - Tutorials and more... Webnauts Programming and Scripting 12 06-20-2007 10:35 PM
external style sheet css blaster12 Programming and Scripting 7 06-21-2006 12:54 PM
css external sheet ammy Programming and Scripting 10 01-05-2006 12:04 PM


All times are GMT -5. The time now is 04:41 AM.

 
Bitrix
Clicky Web Analytics
CloudContacts
Maxtango


Subscribe to our feed | add to myYahoo!

Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.2.0
© 1997-2007 HTMLCenter