<% '************************************************************** ' Software name: PowerEasy SiteWeaver ' Web: http://www.powereasy.net ' Copyright (C) 2005-2008 佛山市动易网络科技有限公司 版权所有 '************************************************************** '强制浏览器重新访问服务器下载页面,而不是从缓存读取页面 Response.Buffer = True Response.Expires = -1 Response.ExpiresAbsolute = Now() - 1 Response.Expires = 0 Response.CacheControl = "no-cache" Dim DownloadUrl, FileExt DownloadUrl = PE_Content.GetDownloadUrl() DownloadUrl = Replace(DownloadUrl, " ", " ") Set PE_Content = Nothing Call CloseConn If DownloadUrl = "ErrorDownloadUrl" Then Response.End FileExt = LCase(Mid(DownloadUrl, InStrRev(DownloadUrl, ".") + 1)) If InStr(DownloadUrl, "://") <= 0 Then DownloadUrl = "http://" & Trim(Request.ServerVariables("HTTP_HOST")) & DownloadUrl End If Select Case FileExt Case "wmv", "mpg", "asf", "mp3", "mpeg", "avi" ShowMediaPlayer (DownloadUrl) Case "rm", "ra", "ram" ShowRealPlayer (DownloadUrl) Case Else '方法一可以解决下载地址中的中文名在另存为对框中的乱码问题,但只能直接点击下载 'Response.write "" '方法二可以使用“目标另存为”,但会有中文乱码问题 Response.Redirect DownloadUrl End Select Function ShowMediaPlayer(strUrl) %> <% End Function Function ShowRealPlayer(strUrl) %>
<% End Function %>