Posts

Showing posts from October, 2011

Advertisement.

TransHimalaya.in

Everest Helicopter Tour for a day

Book exciting packages at www.transhimalaya.in

ASP.Net Having common menu without using master pages

ASP.Net Having common menu without using master pages : I want to have common html code snippest which can be shared by all pages without using the master page concept.
Many of u have asked

is there an equivalent to PHP include files in ASP.net?This method is similar to include tag of php which fetch common html tag stored in a text file to any web page.

My common html code portion will be put on a class file in App_Code folder which is accessible to all. Changing here will reflect everywhere...



1. Now put a label on ur all aspx page where u wanna have common html code like:


   <!-- menu -->


    <asp:Label ID="lblMenu" runat="server" Text="Label"></asp:Label>


<div id="copyright">Copyright © 2011 <a href="http://apycom.com/">NTPC Limited</a></div> 

<!-- end #menu -->


2. Change the Labels Text programmatic-ally in page load event of every page

Imports common  'Where makemenu public function i…

way to override a CSS style of: table td{}

way to override a CSS style of: table td{}

I have a table rendered through css stylesheet.
table id="table-3">....
/table>


This applies it to all tables in my project. Somewhere my user want a different td. So to override default table td css i used this in my td tag:


td style='background-color: lime'>


It can also be override by using inline span tag


span style='background-color: lime'>



You can overide css by specifying !Impartent like below
background-color: lime!important;

- Vinod K

Google+ Followers