Can I use XStandard version 2 and version 3 in the same CMS?
Yes, but versions 1, 2 and 3 use different license files, so you need to serve the appropriate license file to each version. To do this, create a script that will read the HTTP User-Agent header. If this header contains the sub-string "XStandard 3", redirect to version 3 license file. If this HTTP header contains the sub-string "XStandard 2", redirect to version 2 license file. Otherwise, redirect to version 1 license file. Then point the editor to this script like this:
<param name="License" value="http://yourserver/license.asp" />
The following are 3 examples of how to do this using ASP, ASP.NET and PHP.
ASP example
<%
If InStr(1, Request.ServerVariables("HTTP_USER_AGENT").Item, "XStandard 3") > 0 Then
Response.Redirect "license3.txt"
Response.End
ElseIf InStr(1, Request.ServerVariables("HTTP_USER_AGENT").Item, "XStandard 2") > 0 Then
Response.Redirect "license2.txt"
Response.End
Else
Response.Redirect "license1.txt"
Response.End
End If
%>
Download ASP example
ASP.NET example
<%@Page language="C#" AutoEventWireup="false" ValidateRequest="false" Debug="false"%>
<%
if (Request.ServerVariables["HTTP_USER_AGENT"] != null)
{
if (Request.ServerVariables["HTTP_USER_AGENT"].IndexOf("XStandard 3") >= 0)
{
Response.Redirect("license3.txt", false);
}
else if (Request.ServerVariables["HTTP_USER_AGENT"].IndexOf("XStandard 2") >= 0)
{
Response.Redirect("license2.txt", false);
}
else
{
Response.Redirect("license1.txt", false);
}
}
%>
Download ASP.NET example
PHP example
<?php
if (isset($_SERVER["HTTP_USER_AGENT"])) {
if (strpos($_SERVER["HTTP_USER_AGENT"], "XStandard 3") !== false) {
header("Location: license3.txt");
die();
} elseif (strpos($_SERVER["HTTP_USER_AGENT"], "XStandard 2") !== false) {
header("Location: license2.txt");
die();
} else {
header("Location: license1.txt");
die();
}
}
?>
Download PHP example