DeanWhitehouse Posted June 29, 2008 Share Posted June 29, 2008 I have made this function to laod a different style sheet when they change a drop down box. <script type="text/javascript"> function preview() { var theme =document.reg.theme.value; document.getElementById("style").href = theme; } </script> <html> <body> <select id="theme" name="theme" onChange="preview()"> <option value="original.css">Original</option> <option value="classic.css">Classic</option> <option value="dark.css">Dark</option> <option value="light.css">Light</option> <option value="modern.css">Modern</option> </select> </body> </html> My problem is that there is a lsight delay before it loads the next style sheet. Is there any way to preload the style sheets? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.