Hello, I'm using DNN 6.1.5 and a few days ago I copied a .ascx file that stores one of the layouts for my custom skin. I uploaded a renamed copy of the file to Portas/_default/Skins/MySkin folder. (In the MySkin folder, there's files such as ThreeColumnDefault.ascx, ThreeColumnDetailed.ascx, and so on. So I copied the ThreeColumnDefault.ascx file and it's corresponding .doctype.xml file and in the copied .ascx file, I changed the html portion so that instead of 3 divs, there's only two divs. I named my new .ascx files TwoColumnDefault)
I hope this makes sense what I did...
When I went to a test page and changed the skin layout setting to the layout corresponding to the newly copied file, I got the error:
An error has occurred. DotNetNuke.Services.Exceptions.PageLoadException: The Controls collection cannot be modified because the control contains code blocks (i.e. [% ... %]). ---> System.Web.HttpException: The Controls collection cannot be modified because the control contains code blocks (i.e. [% ... %]). at System.Web.UI.ControlCollection.Add(Control child) at DotNetNuke.UI.Skins.Skin.ProcessModule(ModuleInfo module) at DotNetNuke.UI.Skins.Skin.ProcessMasterModules() at DotNetNuke.UI.Skins.Skin.OnInit(EventArgs e) at System.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Control.AddedControl(Control control, Int32 index) at System.Web.UI.ControlCollection.Add(Control child) at DotNetNuke.Framework.DefaultPage.OnInit(EventArgs e) at System.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace ---
(I changed the tags above to use [ and ] instead).
So, I looked around in the site settings and went to Host, Appearance, and the dropdown box did indeed list my newly copied skin layout. Then I went and looked in my DNN database--I just looked and I did not change anything.
When I went back to my test page, the page displayed fine and used my new layout as specified in the new .ascx file that I copied.
I'm trying to figure out what happened that caused the page to start working because I did not change anything. I'm trying to do the same thing again, via another copied .ascx skin file, but despite waiting a while, clearing the cache, and restarting the application, I still get the above error. So what is different about this time and why did it just start working the previous time (and is still working, by the way)?
I realize that this is the not the proper way to add a new skin layout but I have made many changes here and there and I'm afraid to simply reinstall the skin--I'm afraid things will get messed up.
Any help is greatly appreciated!