CustomPageLink

Vote:
 
Hi! I'm trying to use the PageExtension CustomPageLink which, according to the SDK, is a Page option that makes it possible to load a page with a different template than the standard template for the page type. I have my base class which inherits from EPiServer.TemplatePage: public class GMapTemplate : EPiServer.TemplatePage { public GMapTemplate() : base(1, CustomPageLink.OptionFlag) { } } I then try to reach my .aspx which inherits from GMapTemplate by adding ?custompageid=27 to the Url. (As specified in the SDK: "This is done by setting the query string "custompageid" to the page id that you want to load".) This does not work as intended, the CurrentPage objects point to the StartPage (which is not page with id 27). Ideas would be greatly appreciated.
#15804
Mar 25, 2008 19:07
Vote:
 
Hi, You need setup optionflag on first parameter in constructor: public GMapTemplate() : base( CustomPageLink.OptionFlag,0 ) I hope this will solve your problem
#16395
Mar 25, 2008 19:08
Vote:
 
Yes, that did the trick! Thanks!
#16396
Mar 25, 2008 19:08
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.