i have a global variable who hold the value for routing i need to use them to refer the stylesheet like
<%: Globals.routing %> but if i use them to loading stylesheet they never work prehaps the render html soemthing goes like
<link type="text/css" rel="stylesheet" href="<%:Globals.ROOT_PATH %>jqueryui1.8.7.custom.css">
are their any right way to load stylehsheet by passing the location or href tag dynamically
Don’t use global variables for this. Use URL helpers:
Inside the
Url.Contenthelper you could use some variable to specify user specific paths for the CSS.Also make sure that the
<head>tag doesn’t have arunat="server"attribute or you might get some bad surprises.