We are planning to use multiple skins in our ML 8.0.1.2 install.
Instead of www.websitename.com?skinid=2
Can skin ID's be descriptive?
Like www.websitename.com?skinid=winter
or www.websitename.com?skinid=21pfx
We are planning to use multiple skins in our ML 8.0.1.2 install.
Instead of www.websitename.com?skinid=2
Can skin ID's be descriptive?
Like www.websitename.com?skinid=winter
or www.websitename.com?skinid=21pfx
I'm afraid that's not possible out of the box. SkinID is an integer you can't obviously use an alphanumeric unless you'll modify the source.
Hi
If you created a lookup table of skin names to values, e.g.
spring 1
summer 2
autumn (or fall!) 3
winter 4
Then you might be able to modify App_Code\SkinBase.cs (at about line 402 in V9) to retrieve the skin name from the URL, lookup the ID of the skin and then apply the skin.
Something like this to replace the existing code:
String m_SkinName = CommonLogic.QueryStringCanBeDangerousContent("skin id");
if (m_SkinName != "")
{
m_SkinID = LookupSkinID(m_SkinName);
}
[You'd obviously have to write the LookupSkinID method.]
If you wanted to take the simple route, you could simply have a switch statement to lookup the skin names and return an id rather than go to the trouble of creating a database table and access/editing routines.
Adam
Last edited by webopius; 11-04-2010 at 02:11 PM. Reason: Fix my terrible typing
Webopius.com: ASPDotNetStorefront web development and ecommerce project management
Webopius is now a Sage Pay Approved Partner