SPUtility.MakeBrowserCacheSafeLayoutsUrl method (String, Boolean)
Returns a new URL that will not be cached by the browser when the associated file changes. The file name must be relative to the layouts directory in the file system. For example, if an URL contains "layouts/images" it is relative to the layouts directory but the images directory is not under the layouts directory in the file system and therefore it cannot be used with this method.
Namespace: Microsoft.SharePoint.Utilities
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'Declaration
Public Shared Function MakeBrowserCacheSafeLayoutsUrl ( _
name As String, _
localizable As Boolean _
) As String
'Usage
Dim name As String
Dim localizable As Boolean
Dim returnValue As String
returnValue = SPUtility.MakeBrowserCacheSafeLayoutsUrl(name, _
localizable)
public static string MakeBrowserCacheSafeLayoutsUrl(
string name,
bool localizable
)
Parameters
name
Type: System.StringThe name of the file relative to the layouts directory.
localizable
Type: System.BooleanA Boolean value that determines whether or not to include the layouts directory. If true, the language directory is included.
Return value
Type: System.String
The full URL to the file relative to the domain (site).