开发者

Dynamic theme in asp.net

i want to develop our site in such a way user can choose theme. when user will choose theme then i want show the images of our site' home page with various look and user will just choose the images and theme of our site will be change. i know how to change theme from the code behind.

my question is that how could i display the various images of my site's home page with different look which user choose. please tell me the way out. if possible give me a small code to generate the images of my site's home page with different theme attach wh开发者_Go百科ich user will choose. if anyone know any sample of such things according to my requirement then please give me the url from where i can download the sample.

thanks


I think I know what you're trying to say, and I would go about it like this:

  1. Apply a theme to your site, then run it
  2. Take a screenshot of your homepage
  3. Open Paint and paste the screenshot onto the canvas
  4. Save the image as "MySite_Theme1" or something like that

Once you have followed these steps for each of your themes, do the following to apply each preview to a button

  1. Add the screenshots to your site's Images folder.
  2. Go back into your site and create an <asp:ImageButton> for each theme. Apply ID, ImageURL, ImageAlign, runat, Height, and Width. The control should resize the image based on the button's height & width.
  3. Go to changing themes with buttons, how? for coding the code behind.

I hope this helps you out

EDIT: I would also look for the book Beginning ASP.NET in C# & VB. Wrox is the publisher. I have found that and a lot more at www.wowebook.com :)


You could use ASP.NET Themes which could be changed dynamically at runtime.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜