hey everyone.! i have a n application where i have a color picker (jquery) i will get the value the user choosen color . then i will put that into to session variable. Now i want the contents of the external stylesheet to be modified based on the color which is selected .

Example :


in external "style.css" i have like .topbox{ background:#dedede;}

now after the user selects the the color picker ,the value of background sholud be over written

You can't modify the contents of an external stylesheet with JavaScript. You can, however, add inline css to the appropriate tags within your page in order to overwrite styles that have been added with external stylesheets.

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.