How to add custom css to list view pages and list pages
-
03 April 2012 15:49
I have bunch of SharePoint lists an views I am trying to apply same CSS to these SharePoint list and views.
I want to apply css to these lists and their views only not to the whole site pages.
Is there a way we can attach css to these specific pages through CODE.
kukdai
Semua Balasan
-
03 April 2012 17:15
One simple way will be to utilize Sharepoint Designer, if you want to do it via code only, you can create a visual webpart with your style defined in it which will over ride the OOB CSS to render your style sheet.Rahul Gupta, MCPD - SharePoint 2010
- Disarankan sebagai Jawaban oleh Aviw_ 03 April 2012 17:25
- Ditandai sebagai Jawaban oleh Qiao WeiMicrosoft Contingent Staff, Moderator 13 April 2012 11:52
- Tanda sebagai Jawaban dihapus oleh kukdai 13 April 2012 15:41
-
13 April 2012 15:44
How can you apply CSS through visula webpart to a particular site with in a site collection. I want the css to be applied with in a site and subsites and pages with in a site of a site collections and everyother site will be unchanged.
any specific function i can focus on. I want to apply the CSS to only a site and subsite and pages under that site only. other sites with in the subsite will be unchanged.
kukdai
-
13 April 2012 18:03
You can simply define a CSS class which overrides OOB CSS class and add it to the Visual Webpart, then add it to the required page only. If you want to do it for the sub site only, you can modify the master page for that site or create a new master page for that subsite only.
Also go through this sample if you are working with TeamSites: http://mosshowto.blogspot.com/2010/06/sharepoint-2010-wiki-customizing.html
Rahul Gupta, MCPD - SharePoint 2010
- Ditandai sebagai Jawaban oleh Shimin Huang 16 April 2012 6:41