c#网站WebConfig中域名引用示例介绍
更新时间:2021年9月22日 10:11 点击:1949
在WebConfig中定义如下。
public class WebConfig
{
public static string ResourceServer = @"http://www.xxx.com/"; }
在前台页面中这样调用
<script src="<% =WebConfig.ResourceServer %>/js/jquery-ui-all-min-lastest.js"
type="text/javascript"></script>
<link rel="stylesheet" type="text/css" href="<%=WebConfig.ResourceServer +"/css/style.css"%>" />
复制代码 代码如下:
public class WebConfig
{
public static string ResourceServer = @"http://www.xxx.com/"; }
在前台页面中这样调用
复制代码 代码如下:
<script src="<% =WebConfig.ResourceServer %>/js/jquery-ui-all-min-lastest.js"
type="text/javascript"></script>
<link rel="stylesheet" type="text/css" href="<%=WebConfig.ResourceServer +"/css/style.css"%>" />
相关文章
- 这篇文章主要介绍了.net中webconfig 详解,需要的朋友可以参考下...2021-09-22
- 这篇文章主要介绍了c#网站WebConfig中域名引用,需要的朋友可以参考下...2021-09-22