mamamusings
  • Posts: 1
  • Joined: 04/08/2012
Is there any documentation available for creating new themes? I see nothing related to themes under the "documentation" link, and Google isn't much more helpful. We've got yaf.net integrated into our .net application, but right now it sticks out like a sore thumb. At a minimum we need to be able to insert our own header and footer, and change the colors and typography. This doesn't seem as though it would be rocket science, but I really hate to start hacking at files without first reviewing some documentation as to what does what.

Thanks...
Sponsor
squirrel
  • Posts: 925
  • Joined: 14/01/2010
Originally Posted by: mamamusings 

Is there any documentation available for creating new themes? I see nothing related to themes under the "documentation" link, and Google isn't much more helpful. We've got yaf.net integrated into our .net application, but right now it sticks out like a sore thumb. At a minimum we need to be able to insert our own header and footer, and change the colors and typography. This doesn't seem as though it would be rocket science, but I really hate to start hacking at files without first reviewing some documentation as to what does what.

Thanks...



YAF's themes are seperated into a subfolder under the "~/themes" folder inside YAF. They are mainly CSS driven - so a copy of firebug and a little time and you can modify the appearance quite easily. Recommeded copy theme folder to new name folder, and copy theme XML file in ~/themes folder to a new name. Edit theme's XML file to reflect new folder name for that theme. Then you can choose that theme in YAF and begin modifying, and if make mistake, can choose back to another theme so forum stays online, etc. Can also enable personal themes, create a dummy user, and set the 'new theme' to that dummy user's account so you can develop without disturbing rest of users.

Not much documentation on theme editing - but they are pretty straight forward if you have CSS experience.

To add content to pages, such as all pages, I used modifications to default.aspx - that will affect ALL pages in YAF. It is essentially the 'template' file for the site -- and YAF runs as a .NET control in that page. If you need to change individual pages, there is way to do it using the theme folder. Check out the XML for the YAFMobile theme and the ./Mobilepages folder - theme's XML file supports overriding pages individually - might be useful for working with pages and not 'overwriting' core code -- then when new version upgrade, you can just update your theme files and not have to worry about changing core code.
If you can't find it using the forum search, try my signature link -- searches this site using Google: Google is my Friend 
Users browsing this topic
    Forum Jump  
    • You cannot post new topics in this forum.
    • You cannot reply to topics in this forum.
    • You cannot delete your posts in this forum.
    • You cannot edit your posts in this forum.
    • You cannot create polls in this forum.
    • You cannot vote in polls in this forum.

    About Us

    The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

    Powered by Resharper Donate with PayPal button

    Project Twitter Updates

    Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved