Sunday, 25 August 2013

Change an elements CSS value within a node.js module

Change an elements CSS value within a node.js module

How can I change an HTML element CSS value from within a node.js module?
I have a raspberry pi setup with node.js and have physical buttons
(hardware) which when pressed turn on LED's but I would also like to
change the HTML on screen to reflect what happens when a button is
pressed.
I can change screen CSS using the below code in javascript but I don't
seem to be able to do the same for node.js.
var highlightItem = '#someID';
$(highlightItem).css('border-style', 'solid');
$(highlightItem).css('border-color', 'red');
Thanks

No comments:

Post a Comment