<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>JSEDLAK &#187; SharePoint</title>
	<atom:link href="http://jsedlak.org/tag/sharepoint/feed/" rel="self" type="application/rss+xml" />
	<link>http://jsedlak.org</link>
	<description></description>
	<lastBuildDate>Wed, 01 Sep 2010 00:44:02 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Theming SharePoint (6 of Infinite)</title>
		<link>http://jsedlak.org/2008/07/21/theming-sharepoint-6-of-infinite/</link>
		<comments>http://jsedlak.org/2008/07/21/theming-sharepoint-6-of-infinite/#comments</comments>
		<pubDate>Mon, 21 Jul 2008 12:50:14 +0000</pubDate>
		<dc:creator>John Sedlak</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[SharePoint]]></category>

		<guid isPermaLink="false">http://jsedlak.com/?p=63</guid>
		<description><![CDATA[The SharePoint Happenings Blog has a great post about customizing forms for your lists. I am using this to get rid of certain fields that I do not want to be entered when a new item is added. For instance, I default the Status field to &#8220;In Development&#8221; (Open/Assigned) and force the user to pick [...]]]></description>
			<content:encoded><![CDATA[<p>The SharePoint Happenings Blog has a great post about <a href="http://sharepoint07.wordpress.com/2008/02/05/customize-the-newformaspx/"><b>customizing forms</b></a> for your lists. I am using this to get rid of certain fields that I do not want to be entered when a new item is added. For instance, I default the Status field to &#8220;In Development&#8221; (Open/Assigned) and force the user to pick this by hiding the field.</p>
]]></content:encoded>
			<wfw:commentRss>http://jsedlak.org/2008/07/21/theming-sharepoint-6-of-infinite/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Theming SharePoint (4 of Infinite)</title>
		<link>http://jsedlak.org/2008/07/10/theming-sharepoint-4/</link>
		<comments>http://jsedlak.org/2008/07/10/theming-sharepoint-4/#comments</comments>
		<pubDate>Thu, 10 Jul 2008 11:46:53 +0000</pubDate>
		<dc:creator>John Sedlak</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[SharePoint]]></category>

		<guid isPermaLink="false">http://jsedlak.com/?p=57</guid>
		<description><![CDATA[Michael O&#8217;Donovan brings us a blog post about custom (left) navigation in SharePoint. That is what I will be tackling today so I can move away from the ugly Tables and use a more common UL/LI scheme. Here is my class: ?View Code CSHARP1 2 3 4 5 6 7 8 9 10 11 12 [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://blogs.msdn.com/modonovan">Michael O&#8217;Donovan</a> brings us a blog post about <a href="http://blogs.msdn.com/modonovan/archive/2008/05/30/custom-navigation-in-sharepoint-the-full-monty.aspx"><b>custom (left) navigation</b></a> in SharePoint. That is what I will be tackling today so I can move away from the ugly Tables and use a more common UL/LI scheme.</p>
<p>Here is my class:</p>

<div class="wp_codebox_msgheader wp_codebox_hide"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p57code4'); return false;">View Code</a> CSHARP</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p574"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
</pre></td><td class="code" id="p57code4"><pre class="csharp" style="font-family:monospace;"><span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System.Collections</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System.Globalization</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System.ComponentModel</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System.Security.Permissions</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System.Web</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System.Web.UI</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System.Web.UI.WebControls</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System.Xml</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">System.Xml.XPath</span><span style="color: #008000;">;</span>
<span style="color: #0600FF; font-weight: bold;">using</span> <span style="color: #008080;">Microsoft.SharePoint.Utilities</span><span style="color: #008000;">;</span>
&nbsp;
<span style="color: #0600FF; font-weight: bold;">namespace</span> MMOinsite<span style="color: #008000;">.</span><span style="color: #0000FF;">SharePoint</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Components</span>
<span style="color: #008000;">&#123;</span>
    <span style="color: #008000;">&#91;</span>AspNetHostingPermission<span style="color: #008000;">&#40;</span>SecurityAction<span style="color: #008000;">.</span><span style="color: #0000FF;">LinkDemand</span>, Level<span style="color: #008000;">=</span>AspNetHostingPermissionLevel<span style="color: #008000;">.</span><span style="color: #0000FF;">Minimal</span><span style="color: #008000;">&#41;</span>,
     AspNetHostingPermission<span style="color: #008000;">&#40;</span>SecurityAction<span style="color: #008000;">.</span><span style="color: #0000FF;">InheritanceDemand</span>, Level<span style="color: #008000;">=</span>AspNetHostingPermissionLevel<span style="color: #008000;">.</span><span style="color: #0000FF;">Minimal</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">&#93;</span>
    <span style="color: #0600FF; font-weight: bold;">public</span> <span style="color: #6666cc; font-weight: bold;">class</span> ListNavigation <span style="color: #008000;">:</span> HierarchicalDataBoundControl
    <span style="color: #008000;">&#123;</span>
        <span style="color: #0600FF; font-weight: bold;">private</span> XmlDocument navigationTree<span style="color: #008000;">;</span>
        <span style="color: #0600FF; font-weight: bold;">private</span> <span style="color: #6666cc; font-weight: bold;">string</span> currentNodeKey <span style="color: #008000;">=</span> <span style="color: #6666cc; font-weight: bold;">string</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Empty</span><span style="color: #008000;">;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">private</span> <span style="color: #6666cc; font-weight: bold;">string</span> linkClass <span style="color: #008000;">=</span> <span style="color: #666666;">&quot;NavLeftLink&quot;</span><span style="color: #008000;">;</span>
        <span style="color: #0600FF; font-weight: bold;">private</span> <span style="color: #6666cc; font-weight: bold;">string</span> listItemClass <span style="color: #008000;">=</span> <span style="color: #666666;">&quot;NavLeftListItem&quot;</span><span style="color: #008000;">;</span>
        <span style="color: #0600FF; font-weight: bold;">private</span> <span style="color: #6666cc; font-weight: bold;">string</span> listClass <span style="color: #008000;">=</span> <span style="color: #666666;">&quot;NavLeftList&quot;</span><span style="color: #008000;">;</span>
        <span style="color: #0600FF; font-weight: bold;">private</span> <span style="color: #6666cc; font-weight: bold;">string</span> linkSelectedClass <span style="color: #008000;">=</span> <span style="color: #666666;">&quot;NavLeftListItemSelected&quot;</span><span style="color: #008000;">;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">private</span> <span style="color: #6666cc; font-weight: bold;">bool</span> appendLevel <span style="color: #008000;">=</span> <span style="color: #0600FF; font-weight: bold;">false</span><span style="color: #008000;">;</span>
        <span style="color: #0600FF; font-weight: bold;">private</span> <span style="color: #6666cc; font-weight: bold;">string</span> appendLevelClass <span style="color: #008000;">=</span> <span style="color: #666666;">&quot;NavLeftListItem&quot;</span><span style="color: #008000;">;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">protected</span> <span style="color: #0600FF; font-weight: bold;">override</span> <span style="color: #6666cc; font-weight: bold;">void</span> PerformDataBinding<span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span>
        <span style="color: #008000;">&#123;</span>
            <span style="color: #0600FF; font-weight: bold;">base</span><span style="color: #008000;">.</span><span style="color: #0000FF;">PerformDataBinding</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            <span style="color: #008080; font-style: italic;">// Oh god, no data source! ABORT!</span>
            <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span><span style="color: #008000;">!</span>IsBoundUsingDataSourceID <span style="color: #008000;">&amp;&amp;</span> <span style="color: #008000;">&#40;</span>DataSource <span style="color: #008000;">==</span> <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">&#41;</span>
                <span style="color: #0600FF; font-weight: bold;">return</span><span style="color: #008000;">;</span>
&nbsp;
            HierarchicalDataSourceView view <span style="color: #008000;">=</span> GetData<span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span>view <span style="color: #008000;">==</span> <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span>
                <span style="color: #0600FF; font-weight: bold;">throw</span> <span style="color: #008000;">new</span> InvalidOperationException<span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;Cannot get any data from the data source control.&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            IHierarchicalEnumerable enumerable <span style="color: #008000;">=</span> view<span style="color: #008000;">.</span><span style="color: #0600FF; font-weight: bold;">Select</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
            <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span>enumerable <span style="color: #008000;">!=</span> <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span>
            <span style="color: #008000;">&#123;</span>
                navigationTree <span style="color: #008000;">=</span> <span style="color: #008000;">new</span> XmlDocument<span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
                navigationTree<span style="color: #008000;">.</span><span style="color: #0000FF;">LoadXml</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;&lt;nodes&gt;&lt;/nodes&gt;&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
                <span style="color: #0600FF; font-weight: bold;">try</span>
                <span style="color: #008000;">&#123;</span>
                    AddNavigationItem<span style="color: #008000;">&#40;</span>navigationTree<span style="color: #008000;">.</span><span style="color: #0000FF;">DocumentElement</span>, enumerable, <span style="color: #FF0000;">1</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
                <span style="color: #008000;">&#125;</span>
                <span style="color: #0600FF; font-weight: bold;">finally</span> <span style="color: #008000;">&#123;</span> <span style="color: #008000;">&#125;</span>
&nbsp;
                ViewState<span style="color: #008000;">&#91;</span><span style="color: #666666;">&quot;navXml&quot;</span><span style="color: #008000;">&#93;</span> <span style="color: #008000;">=</span> navigationTree<span style="color: #008000;">.</span><span style="color: #0000FF;">OuterXml</span><span style="color: #008000;">;</span>
            <span style="color: #008000;">&#125;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">private</span> <span style="color: #6666cc; font-weight: bold;">void</span> AddNavigationItem<span style="color: #008000;">&#40;</span>XmlElement currentNode, IHierarchicalEnumerable enumerable, <span style="color: #6666cc; font-weight: bold;">int</span> depth<span style="color: #008000;">&#41;</span>
        <span style="color: #008000;">&#123;</span>
            <span style="color: #0600FF; font-weight: bold;">foreach</span> <span style="color: #008000;">&#40;</span><span style="color: #6666cc; font-weight: bold;">object</span> item <span style="color: #0600FF; font-weight: bold;">in</span> enumerable<span style="color: #008000;">&#41;</span>
            <span style="color: #008000;">&#123;</span>
                IHierarchyData data <span style="color: #008000;">=</span> enumerable<span style="color: #008000;">.</span><span style="color: #0000FF;">GetHierarchyData</span><span style="color: #008000;">&#40;</span>item<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
                NavigationItem navItem <span style="color: #008000;">=</span> BuildNavigationItem<span style="color: #008000;">&#40;</span>data, depth<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
                XmlElement newNavElement <span style="color: #008000;">=</span> BuildNavigationNode<span style="color: #008000;">&#40;</span>currentNode, navItem<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
                currentNode<span style="color: #008000;">.</span><span style="color: #0000FF;">AppendChild</span><span style="color: #008000;">&#40;</span>newNavElement<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
                <span style="color: #0600FF; font-weight: bold;">if</span><span style="color: #008000;">&#40;</span>data<span style="color: #008000;">.</span><span style="color: #0000FF;">HasChildren</span><span style="color: #008000;">&#41;</span>
                <span style="color: #008000;">&#123;</span>
                    IHierarchicalEnumerable newEnumerable <span style="color: #008000;">=</span> data<span style="color: #008000;">.</span><span style="color: #0000FF;">GetChildren</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
                    <span style="color: #0600FF; font-weight: bold;">if</span><span style="color: #008000;">&#40;</span>newEnumerable <span style="color: #008000;">!=</span> <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span>
                        AddNavigationItem<span style="color: #008000;">&#40;</span>newNavElement, newEnumerable, depth <span style="color: #008000;">+</span> <span style="color: #FF0000;">1</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
                <span style="color: #008000;">&#125;</span>
            <span style="color: #008000;">&#125;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">private</span> NavigationItem BuildNavigationItem<span style="color: #008000;">&#40;</span>IHierarchyData data, <span style="color: #6666cc; font-weight: bold;">int</span> depth<span style="color: #008000;">&#41;</span>
        <span style="color: #008000;">&#123;</span>
            NavigationItem tmpNavItem <span style="color: #008000;">=</span> <span style="color: #008000;">new</span> NavigationItem<span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            <span style="color: #0600FF; font-weight: bold;">try</span>
            <span style="color: #008000;">&#123;</span>
                INavigateUIData navNode <span style="color: #008000;">=</span> <span style="color: #008000;">&#40;</span>INavigateUIData<span style="color: #008000;">&#41;</span>data<span style="color: #008000;">;</span>
&nbsp;
                tmpNavItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Title</span> <span style="color: #008000;">=</span> navNode<span style="color: #008000;">.</span><span style="color: #0000FF;">Value</span><span style="color: #008000;">;</span>
                tmpNavItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Url</span> <span style="color: #008000;">=</span> navNode<span style="color: #008000;">.</span><span style="color: #0000FF;">NavigateUrl</span><span style="color: #008000;">;</span>
                tmpNavItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Level</span> <span style="color: #008000;">=</span> depth<span style="color: #008000;">;</span>
&nbsp;
                <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span>currentNodeKey<span style="color: #008000;">.</span><span style="color: #0000FF;">Length</span> <span style="color: #008000;">==</span> <span style="color: #FF0000;">0</span><span style="color: #008000;">&#41;</span>
                <span style="color: #008000;">&#123;</span>
                    SiteMapDataSource dataSource <span style="color: #008000;">=</span> GetDataSource<span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span> <span style="color: #0600FF; font-weight: bold;">as</span> SiteMapDataSource<span style="color: #008000;">;</span>
&nbsp;
                    <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span>dataSource <span style="color: #008000;">!=</span> <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span>
                        <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span>dataSource<span style="color: #008000;">.</span><span style="color: #0000FF;">Provider</span><span style="color: #008000;">.</span><span style="color: #0000FF;">CurrentNode</span> <span style="color: #008000;">!=</span> <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span>
                            currentNodeKey <span style="color: #008000;">=</span> dataSource<span style="color: #008000;">.</span><span style="color: #0000FF;">Provider</span><span style="color: #008000;">.</span><span style="color: #0000FF;">CurrentNode</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Url</span><span style="color: #008000;">.</span><span style="color: #0000FF;">ToLower</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
                <span style="color: #008000;">&#125;</span>
&nbsp;
                <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span><span style="color: #6666cc; font-weight: bold;">string</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Compare</span><span style="color: #008000;">&#40;</span>tmpNavItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Url</span>, currentNodeKey, <span style="color: #0600FF; font-weight: bold;">true</span>, CultureInfo<span style="color: #008000;">.</span><span style="color: #0000FF;">InvariantCulture</span><span style="color: #008000;">&#41;</span> <span style="color: #008000;">==</span> <span style="color: #FF0000;">0</span><span style="color: #008000;">&#41;</span>
                    tmpNavItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Selected</span> <span style="color: #008000;">=</span> <span style="color: #0600FF; font-weight: bold;">true</span><span style="color: #008000;">;</span>
            <span style="color: #008000;">&#125;</span>
            <span style="color: #0600FF; font-weight: bold;">catch</span> <span style="color: #008000;">&#40;</span>Exception ex<span style="color: #008000;">&#41;</span>
            <span style="color: #008000;">&#123;</span>
                <span style="color: #0600FF; font-weight: bold;">throw</span> ex<span style="color: #008000;">;</span>
            <span style="color: #008000;">&#125;</span>
&nbsp;
            <span style="color: #0600FF; font-weight: bold;">return</span> tmpNavItem<span style="color: #008000;">;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">private</span> NavigationItem BuildNavigationItem<span style="color: #008000;">&#40;</span>XmlNode node<span style="color: #008000;">&#41;</span>
        <span style="color: #008000;">&#123;</span>
            NavigationItem tmpNavItem <span style="color: #008000;">=</span> <span style="color: #008000;">new</span> NavigationItem<span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            tmpNavItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Title</span> <span style="color: #008000;">=</span> node<span style="color: #008000;">.</span><span style="color: #0000FF;">Attributes</span><span style="color: #008000;">&#91;</span><span style="color: #666666;">&quot;title&quot;</span><span style="color: #008000;">&#93;</span><span style="color: #008000;">.</span><span style="color: #0000FF;">InnerText</span><span style="color: #008000;">;</span>
            tmpNavItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Url</span> <span style="color: #008000;">=</span> node<span style="color: #008000;">.</span><span style="color: #0000FF;">Attributes</span><span style="color: #008000;">&#91;</span><span style="color: #666666;">&quot;url&quot;</span><span style="color: #008000;">&#93;</span><span style="color: #008000;">.</span><span style="color: #0000FF;">InnerText</span><span style="color: #008000;">;</span>
            tmpNavItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Selected</span> <span style="color: #008000;">=</span> Convert<span style="color: #008000;">.</span><span style="color: #0000FF;">ToBoolean</span><span style="color: #008000;">&#40;</span>node<span style="color: #008000;">.</span><span style="color: #0000FF;">Attributes</span><span style="color: #008000;">&#91;</span><span style="color: #666666;">&quot;isSelected&quot;</span><span style="color: #008000;">&#93;</span><span style="color: #008000;">.</span><span style="color: #0000FF;">InnerText</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
            tmpNavItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Level</span> <span style="color: #008000;">=</span> Convert<span style="color: #008000;">.</span><span style="color: #0000FF;">ToInt32</span><span style="color: #008000;">&#40;</span>node<span style="color: #008000;">.</span><span style="color: #0000FF;">Attributes</span><span style="color: #008000;">&#91;</span><span style="color: #666666;">&quot;level&quot;</span><span style="color: #008000;">&#93;</span><span style="color: #008000;">.</span><span style="color: #0000FF;">InnerText</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            <span style="color: #0600FF; font-weight: bold;">return</span> tmpNavItem<span style="color: #008000;">;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">private</span> XmlElement BuildNavigationNode<span style="color: #008000;">&#40;</span>XmlElement parentNode, NavigationItem navItem<span style="color: #008000;">&#41;</span>
        <span style="color: #008000;">&#123;</span>
            XmlElement tmpNode <span style="color: #008000;">=</span> navigationTree<span style="color: #008000;">.</span><span style="color: #0000FF;">CreateElement</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;node&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            tmpNode<span style="color: #008000;">.</span><span style="color: #0000FF;">SetAttribute</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;url&quot;</span>, navItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Url</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
            tmpNode<span style="color: #008000;">.</span><span style="color: #0000FF;">SetAttribute</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;title&quot;</span>, navItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Title</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
            tmpNode<span style="color: #008000;">.</span><span style="color: #0000FF;">SetAttribute</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;level&quot;</span>, navItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Level</span><span style="color: #008000;">.</span><span style="color: #0000FF;">ToString</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
            tmpNode<span style="color: #008000;">.</span><span style="color: #0000FF;">SetAttribute</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;isSelected&quot;</span>, navItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Selected</span><span style="color: #008000;">.</span><span style="color: #0000FF;">ToString</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            <span style="color: #0600FF; font-weight: bold;">return</span> tmpNode<span style="color: #008000;">;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">protected</span> <span style="color: #0600FF; font-weight: bold;">override</span> <span style="color: #6666cc; font-weight: bold;">void</span> Render<span style="color: #008000;">&#40;</span>HtmlTextWriter writer<span style="color: #008000;">&#41;</span>
        <span style="color: #008000;">&#123;</span>
            <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span>navigationTree <span style="color: #008000;">==</span> <span style="color: #0600FF; font-weight: bold;">null</span> <span style="color: #008000;">&amp;&amp;</span> ViewState<span style="color: #008000;">&#91;</span><span style="color: #666666;">&quot;navXml&quot;</span><span style="color: #008000;">&#93;</span> <span style="color: #008000;">!=</span> <span style="color: #0600FF; font-weight: bold;">null</span><span style="color: #008000;">&#41;</span>
            <span style="color: #008000;">&#123;</span>
                navigationTree <span style="color: #008000;">=</span> <span style="color: #008000;">new</span> XmlDocument<span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
                navigationTree<span style="color: #008000;">.</span><span style="color: #0000FF;">LoadXml</span><span style="color: #008000;">&#40;</span>ViewState<span style="color: #008000;">&#91;</span><span style="color: #666666;">&quot;navXml&quot;</span><span style="color: #008000;">&#93;</span><span style="color: #008000;">.</span><span style="color: #0000FF;">ToString</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
            <span style="color: #008000;">&#125;</span>
&nbsp;
            XmlNodeList nodeList <span style="color: #008000;">=</span> navigationTree<span style="color: #008000;">.</span><span style="color: #0000FF;">SelectNodes</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;nodes/node&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span>nodeList<span style="color: #008000;">.</span><span style="color: #0000FF;">Count</span> <span style="color: #008000;">&gt;</span> <span style="color: #FF0000;">0</span><span style="color: #008000;">&#41;</span>
            <span style="color: #008000;">&#123;</span>
                WriteListStart<span style="color: #008000;">&#40;</span>writer<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
                <span style="color: #0600FF; font-weight: bold;">foreach</span> <span style="color: #008000;">&#40;</span>XmlNode node <span style="color: #0600FF; font-weight: bold;">in</span> nodeList<span style="color: #008000;">&#41;</span>
                <span style="color: #008000;">&#123;</span>
                    Render<span style="color: #008000;">&#40;</span>node, writer<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
                <span style="color: #008000;">&#125;</span>
                WriteListEnd<span style="color: #008000;">&#40;</span>writer<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
            <span style="color: #008000;">&#125;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">protected</span> <span style="color: #0600FF; font-weight: bold;">virtual</span> <span style="color: #6666cc; font-weight: bold;">void</span> WriteListStart<span style="color: #008000;">&#40;</span>HtmlTextWriter writer<span style="color: #008000;">&#41;</span>
        <span style="color: #008000;">&#123;</span>
            writer<span style="color: #008000;">.</span><span style="color: #0000FF;">Write</span><span style="color: #008000;">&#40;</span><span style="color: #6666cc; font-weight: bold;">string</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Format</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;&lt;ul class=<span style="color: #008080; font-weight: bold;">\&quot;</span>{0}<span style="color: #008080; font-weight: bold;">\&quot;</span>&gt;&quot;</span>, ListClass<span style="color: #008000;">&#41;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">protected</span> <span style="color: #0600FF; font-weight: bold;">virtual</span> <span style="color: #6666cc; font-weight: bold;">void</span> WriteListEnd<span style="color: #008000;">&#40;</span>HtmlTextWriter writer<span style="color: #008000;">&#41;</span>
        <span style="color: #008000;">&#123;</span>
            writer<span style="color: #008000;">.</span><span style="color: #0000FF;">Write</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;&lt;/ul&gt;&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">protected</span> <span style="color: #0600FF; font-weight: bold;">virtual</span> <span style="color: #6666cc; font-weight: bold;">void</span> Render<span style="color: #008000;">&#40;</span>XmlNode navNode, HtmlTextWriter writer<span style="color: #008000;">&#41;</span>
        <span style="color: #008000;">&#123;</span>
            NavigationItem navItem <span style="color: #008000;">=</span> BuildNavigationItem<span style="color: #008000;">&#40;</span>navNode<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            writer<span style="color: #008000;">.</span><span style="color: #0000FF;">Write</span><span style="color: #008000;">&#40;</span>
                <span style="color: #6666cc; font-weight: bold;">string</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Format</span><span style="color: #008000;">&#40;</span>
                    <span style="color: #666666;">&quot;&lt;li class=<span style="color: #008080; font-weight: bold;">\&quot;</span>{0}{1}<span style="color: #008080; font-weight: bold;">\&quot;</span>&gt;&quot;</span>,
                    ListItemClass,
                    <span style="color: #008000;">&#40;</span>AppendLevel<span style="color: #008000;">&#41;</span> <span style="color: #008000;">?</span> <span style="color: #6666cc; font-weight: bold;">string</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Format</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot; {0}{1}&quot;</span>, AppendLevelClass, navItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Level</span><span style="color: #008000;">&#41;</span> <span style="color: #008000;">:</span> <span style="color: #666666;">&quot;&quot;</span>
                <span style="color: #008000;">&#41;</span>
            <span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            writer<span style="color: #008000;">.</span><span style="color: #0000FF;">Write</span><span style="color: #008000;">&#40;</span>
                <span style="color: #6666cc; font-weight: bold;">string</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Format</span><span style="color: #008000;">&#40;</span>
                    <span style="color: #666666;">&quot;&lt;a class=<span style="color: #008080; font-weight: bold;">\&quot;</span>{0}<span style="color: #008080; font-weight: bold;">\&quot;</span> href=<span style="color: #008080; font-weight: bold;">\&quot;</span>{1}<span style="color: #008080; font-weight: bold;">\&quot;</span>&gt;{2}&lt;/a&gt;&quot;</span>,
                    <span style="color: #008000;">&#40;</span>navItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Selected</span><span style="color: #008000;">&#41;</span> <span style="color: #008000;">?</span> LinkSelectedClass <span style="color: #008000;">:</span> LinkClass,
                    navItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Url</span>,
                    navItem<span style="color: #008000;">.</span><span style="color: #0000FF;">Title</span>
                <span style="color: #008000;">&#41;</span>
            <span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
            <span style="color: #0600FF; font-weight: bold;">if</span> <span style="color: #008000;">&#40;</span>navNode<span style="color: #008000;">.</span><span style="color: #0000FF;">ChildNodes</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Count</span> <span style="color: #008000;">&gt;</span> <span style="color: #FF0000;">0</span><span style="color: #008000;">&#41;</span>
            <span style="color: #008000;">&#123;</span>
                WriteListStart<span style="color: #008000;">&#40;</span>writer<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
                XmlNodeList nodeList <span style="color: #008000;">=</span> navNode<span style="color: #008000;">.</span><span style="color: #0000FF;">SelectNodes</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;node&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
                <span style="color: #0600FF; font-weight: bold;">foreach</span> <span style="color: #008000;">&#40;</span>XmlNode childNode <span style="color: #0600FF; font-weight: bold;">in</span> nodeList<span style="color: #008000;">&#41;</span>
                    Render<span style="color: #008000;">&#40;</span>childNode, writer<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
                WriteListEnd<span style="color: #008000;">&#40;</span>writer<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
            <span style="color: #008000;">&#125;</span>
&nbsp;
            writer<span style="color: #008000;">.</span><span style="color: #0000FF;">Write</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;&lt;/li&gt;&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">public</span> <span style="color: #6666cc; font-weight: bold;">string</span> ListClass
        <span style="color: #008000;">&#123;</span>
            get <span style="color: #008000;">&#123;</span> <span style="color: #0600FF; font-weight: bold;">return</span> listClass<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
            set <span style="color: #008000;">&#123;</span> listClass <span style="color: #008000;">=</span> value<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">public</span> <span style="color: #6666cc; font-weight: bold;">string</span> LinkSelectedClass
        <span style="color: #008000;">&#123;</span>
            get <span style="color: #008000;">&#123;</span> <span style="color: #0600FF; font-weight: bold;">return</span> linkSelectedClass<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
            set <span style="color: #008000;">&#123;</span> linkSelectedClass <span style="color: #008000;">=</span> value<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">public</span> <span style="color: #6666cc; font-weight: bold;">string</span> LinkClass
        <span style="color: #008000;">&#123;</span>
            get <span style="color: #008000;">&#123;</span> <span style="color: #0600FF; font-weight: bold;">return</span> linkClass<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
            set <span style="color: #008000;">&#123;</span> linkClass <span style="color: #008000;">=</span> value<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">public</span> <span style="color: #6666cc; font-weight: bold;">string</span> ListItemClass
        <span style="color: #008000;">&#123;</span>
            get <span style="color: #008000;">&#123;</span> <span style="color: #0600FF; font-weight: bold;">return</span> listItemClass<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
            set <span style="color: #008000;">&#123;</span> listItemClass <span style="color: #008000;">=</span> value<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">public</span> <span style="color: #6666cc; font-weight: bold;">bool</span> AppendLevel
        <span style="color: #008000;">&#123;</span>
            get <span style="color: #008000;">&#123;</span> <span style="color: #0600FF; font-weight: bold;">return</span> appendLevel<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
            set <span style="color: #008000;">&#123;</span> appendLevel <span style="color: #008000;">=</span> value<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
        <span style="color: #008000;">&#125;</span>
&nbsp;
        <span style="color: #0600FF; font-weight: bold;">public</span> <span style="color: #6666cc; font-weight: bold;">string</span> AppendLevelClass
        <span style="color: #008000;">&#123;</span>
            get <span style="color: #008000;">&#123;</span> <span style="color: #0600FF; font-weight: bold;">return</span> appendLevelClass<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
            set <span style="color: #008000;">&#123;</span> appendLevelClass <span style="color: #008000;">=</span> value<span style="color: #008000;">;</span> <span style="color: #008000;">&#125;</span>
        <span style="color: #008000;">&#125;</span>
    <span style="color: #008000;">&#125;</span>
<span style="color: #008000;">&#125;</span></pre></td></tr></table></div>

<p>But how do we install it? Good question John. Why thank you John! Copy it to your server. Open the GAC (C:\WINDOWS\assembly) and drag and drop. Now perform an IISRESET and add the control to your master page in the usual way:</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p57code5'); return false;">View Code</a> HTML</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p575"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
</pre></td><td class="code" id="p57code5"><pre class="html" style="font-family:monospace;">&lt;%@ Register Tagprefix=&quot;asp&quot; Namespace=&quot;MMOinsite.SharePoint.Components&quot; Assembly=&quot;MMOinsite.SharePoint.Components, Version=1.0.0.0, Culture=neutral, PublicKeyToken=abb33cdce6ddaae1&quot; %&gt;
&nbsp;
...
&nbsp;
&lt;Sharepoint:SPNavigationManager id=&quot;QuickLaunchNavigationManager&quot;
    runat=&quot;server&quot;
    QuickLaunchControlId=&quot;QuickLaunchMenu&quot;
    ContainedControl=&quot;QuickLaunch&quot;
    EnableViewState=&quot;false&quot; &gt;
    &lt;div&gt;
        &lt;SharePoint:DelegateControl runat=&quot;server&quot; ControlId=&quot;QuickLaunchDataSource&quot;&gt;
            &lt;Template_Controls&gt;
                &lt;asp:SiteMapDataSource
                    SiteMapProvider=&quot;SPNavigationProvider&quot;
                    ShowStartingNode=&quot;False&quot;
                    id=&quot;QuickLaunchSiteMap&quot;
                    StartingNodeUrl=&quot;sid:1025&quot;
                    runat=&quot;server&quot;
                /&gt;
            &lt;/Template_Controls&gt;
        &lt;/SharePoint:DelegateControl&gt;
        &lt;asp:ListNavigation id=&quot;CustomListNavigation&quot; DataSourceId=&quot;QuickLaunchSiteMap&quot; runat=&quot;server&quot; /&gt;
    &lt;/div&gt;
&lt;/SharePoint:SPNavigationManager&gt;</pre></td></tr></table></div>

<p>It is important to note that the UL/LI scheme is <i>incredibly</i> flexible. You can make them horizontal, drop down menus or keep them as standard vertical lists. Once the control is in place, the designer (CSS for the win here) can take over. For this reason, this type of navigation scheme can also make its way to the top navigation bar. But I will leave that up to you as I have got to get back to work!</p>
<p><b>Update (9:58):</b> Here are the CSS styles I use with setting AppendLevel to true in the control tag of the master page. There is some pretty wacky CSS going on here and I am sure it can be cleaned up, but it works in IE7 and is a good place to start.</p>

<div class="wp_codebox_msgheader wp_codebox_hide"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p57code6'); return false;">View Code</a> HTML</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p576"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
</pre></td><td class="code" id="p57code6"><pre class="html" style="font-family:monospace;">.NavLeftLink{
	color: #2D2D2D;
}
&nbsp;
.NavLeftListItem{
	background: #F2F8FF;
	margin-left: 0px;
	padding: 0px;
	width: 100%;
}
&nbsp;
.NavLeftListItem2{
}
&nbsp;
.NavLeftListItem a{
	padding: 2px 0px 2px 5px;
	border-top: solid 1px #25475A;
	width: 100%;
}
&nbsp;
.NavLeftListItem a:hover{
	background: #D4F7B9;
}
&nbsp;
.NavLeftListItem1 a{
	background: #BACCD6;
	font-size: 1.2em;
	font-weight: bold;
	border-bottom: solid 1px #25475A;
	margin-bottom: 1px;
}
&nbsp;
.NavLeftListItem2 a{
	background: #F2F8FF;
	border: 0px;
	padding-left: 20px;
	font-size: 1em;
	font-weight: normal;
	background-image: url(/_layouts/images/navBullet.gif);
	background-repeat: no-repeat;
	background-position: 5px top;
}
&nbsp;
.NavLeftListItem2 a:hover{
	background-image: url(/_layouts/images/navBullet.gif);
	background-repeat: no-repeat;
	background-position: 5px top;
}
&nbsp;
.NavLeftListItemSelected{
	background: #D4F7B9;
}
&nbsp;
.NavLeftList{
	margin-top: 0px;
	margin-left: 0px;
	list-style: none;
	border-bottom: solid 1px #25475A;	
}
&nbsp;
.NavLeftList .NavLeftList{
	border: 0px;
}</pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://jsedlak.org/2008/07/10/theming-sharepoint-4/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Theming SharePoint (3 of Infinite)</title>
		<link>http://jsedlak.org/2008/07/09/theming-sharepoint-3-of-infinite/</link>
		<comments>http://jsedlak.org/2008/07/09/theming-sharepoint-3-of-infinite/#comments</comments>
		<pubDate>Thu, 10 Jul 2008 01:22:30 +0000</pubDate>
		<dc:creator>John Sedlak</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[SharePoint]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[FireFox]]></category>

		<guid isPermaLink="false">http://jsedlak.com/?p=55</guid>
		<description><![CDATA[A short one here. When you are going to start theming SharePoint and need to figure out exactly what styles need to be changed, the best tool you can ever get is one like the Web Developer extension for FireFox. Now I hate FireFox, especially 3.x, but I run 2.x at work for the sole [...]]]></description>
			<content:encoded><![CDATA[<p>A short one here. When you are going to start theming SharePoint and need to figure out exactly what styles need to be changed, the best tool you can ever get is one like the Web Developer extension for FireFox. Now I hate FireFox, especially 3.x, but I run 2.x at work for the sole purpose of the WebDev extension. Right click on the page, select &#8220;Select CSS&#8221; under the CSS menu and click away. It will automatically pull CSS styles from the included sheets that pertain to the selected element. This will save hours of time digging through core.css and the page&#8217;s source HTML. Trust me.</p>
<p>You may be asking &#8220;What else will he post about?&#8221; Well, I plan to go through the actual creation of a master page file for the theme from <a href="http://focusedgames.com">Focused Games</a> but first I have to figure out a few things like how to redo how SharePoint outputs stuff (tables &#8211; blegh!). Yeah, I am going that far because I am sick of seeing SharePoint sites that look like SharePoint. In between here and there I will keep touching on the general tidbits of information that may help.</p>
]]></content:encoded>
			<wfw:commentRss>http://jsedlak.org/2008/07/09/theming-sharepoint-3-of-infinite/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Theming SharePoint (2 of Infinite)</title>
		<link>http://jsedlak.org/2008/07/09/theming-sharepoint-2-of-infinite/</link>
		<comments>http://jsedlak.org/2008/07/09/theming-sharepoint-2-of-infinite/#comments</comments>
		<pubDate>Wed, 09 Jul 2008 14:47:30 +0000</pubDate>
		<dc:creator>John Sedlak</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[SharePoint]]></category>
		<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://jsedlak.com/?p=54</guid>
		<description><![CDATA[Here is a good blog post about theming the SharePoint top navigation. Today&#8217;s post is all about CSS, so pull out your favorite design books&#8230; and then light them on fire because they will be of no use here. You&#8217;ll want to start off by pulling and probably printing the core.css file that is provided [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://blogs.vertigo.com/personal/rbiggs/Blog/Lists/Posts/Post.aspx?List=02949b85%2Da29d%2D4682%2Dabdb%2Da065bff28a03&#038;ID=6"><b>Here</b></a> is a good blog post about theming the SharePoint top navigation. Today&#8217;s post is all about CSS, so pull out your favorite design books&#8230; and then light them on fire because they will be of no use here. You&#8217;ll want to start off by pulling and probably printing the core.css file that is provided with SharePoint. It may also be a good idea to print the source code of your new non-designed master page. Why? This will give you an idea of what HTML code SharePoint produces and what CSS classes it uses.</p>
<p>Once that is done, go ahead and create a new CSS file in the &#8220;Style Library&#8221; of your site. Go into site settings for the main site and override the style sheet with that file. This can be found at the bottom. Now you are good to go! Almost&#8230; more to come soon.</p>
<p>Here is a little of the CSS you may be employing. This applies to the &#8220;Upload Document&#8221; style pages and gets rid of the background images and borders:</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p54code8'); return false;">View Code</a> HTML</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p548"><td class="line_numbers"><pre>1
2
3
4
5
6
7
</pre></td><td class="code" id="p54code8"><pre class="html" style="font-family:monospace;">div.ms-areaseparatorright,div.ms-areaseparatorleft,.ms-nav,td.ms-bodyareapagemargin,td.ms-pagebottommarginleft,
td.ms-pagebottommargin,td.ms-titlearealeft,div.ms-titleareaframe,td.ms-areaseparatorleft,td.ms-titleareaframe,
.ms-titlearearight .ms-areaseparatorright,td.ms-pagebottommarginright,td.ms-sitetitle,td.ms-globalTitleArea
{
	border-color: #000;
	background: transparent;
}</pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://jsedlak.org/2008/07/09/theming-sharepoint-2-of-infinite/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Theming SharePoint (1 of Infinite)</title>
		<link>http://jsedlak.org/2008/07/08/theming-sharepoint-1-of-infinite/</link>
		<comments>http://jsedlak.org/2008/07/08/theming-sharepoint-1-of-infinite/#comments</comments>
		<pubDate>Tue, 08 Jul 2008 14:32:29 +0000</pubDate>
		<dc:creator>John Sedlak</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[SharePoint]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Master Pages]]></category>

		<guid isPermaLink="false">http://jsedlak.com/?p=53</guid>
		<description><![CDATA[I am beginning to do themes (master pages) for some SharePoint sites, so here is part 1 of an infinite number of parts (because of how difficult theming SP is) of &#8220;Theming SharePoint.&#8221; Assumptions: Theming will be done in several ways. Any advanced theming will include modifying core template pages. The amount of modification is [...]]]></description>
			<content:encoded><![CDATA[<p>I am beginning to do themes (master pages) for some SharePoint sites, so here is part 1 of an infinite number of parts (because of how difficult theming SP is) of &#8220;Theming SharePoint.&#8221;</p>
<p><b>Assumptions:</b></p>
<ul>
<li>Theming will be done in several ways.</li>
<li>Any advanced theming will include modifying core template pages.</li>
<li>The amount of modification is directly related to the number of work arounds needed.</li>
<li>This is going to suck.</li>
</ul>
<p><b>Initial Steps</b></p>
<ol>
<li>Copy default.master from main site catalog directory. Rename and open.</li>
<li>Erase everything.</li>
<li>Open default.master in new window.</li>
<li>Add each individual part, one by one to the page without any layouts.
<ol>
<li>I started with the header, copy pretty much everything over.</li>
<li>Remove all table tags and __designer: attributes.</li>
<li>Remove all div, p, b, and style tags.</li>
</ol>
</li>
</ol>
<p>After doing this, you should have a horrible looking page with all the content on it. The important piece here is to get the content working so it is possible to figure out what place holders do what. Next post will be about layouts, the CSS hacks and more.</p>
<p><b>Update (18:25):</b> Added more detail to the last step. Basically strip everything but the place holders and the controls inside of them.</p>
]]></content:encoded>
			<wfw:commentRss>http://jsedlak.org/2008/07/08/theming-sharepoint-1-of-infinite/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing SharePoint 2007 on Windows Server 2008</title>
		<link>http://jsedlak.org/2008/06/19/installing-sharepoint-2007-on-windows-server-2008/</link>
		<comments>http://jsedlak.org/2008/06/19/installing-sharepoint-2007-on-windows-server-2008/#comments</comments>
		<pubDate>Fri, 20 Jun 2008 04:08:02 +0000</pubDate>
		<dc:creator>John Sedlak</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[SharePoint]]></category>
		<category><![CDATA[WS2008]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Active Directory]]></category>

		<guid isPermaLink="false">http://jsedlak.com/?p=42</guid>
		<description><![CDATA[Ben Curry has made an excellent post about installing SharePoint 2007 on WS2008 by slipstreaming SP1 updates. I am now running SharePoint and AD on my internal server!]]></description>
			<content:encoded><![CDATA[<p><a href="http://mindsharpblogs.com/ben/archive/2007/12/16/3837.aspx">Ben Curry</a> has made an excellent post about installing SharePoint 2007 on WS2008 by slipstreaming SP1 updates. I am now running SharePoint and AD on my internal server!</p>
<div style="text-align:center;"><a href='http://jsedlak.com/wp-content/uploads/2008/06/moss01.jpg'><img src="http://jsedlak.com/wp-content/uploads/2008/06/moss01-290x300.jpg" alt="MOSS" title="moss01" width="290" height="300" class="alignnone size-medium wp-image-43" /></a></div>
]]></content:encoded>
			<wfw:commentRss>http://jsedlak.org/2008/06/19/installing-sharepoint-2007-on-windows-server-2008/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hosting A Page Inside A SharePoint Page</title>
		<link>http://jsedlak.org/2008/05/28/hosting-a-page-inside-a-sharepoint-page/</link>
		<comments>http://jsedlak.org/2008/05/28/hosting-a-page-inside-a-sharepoint-page/#comments</comments>
		<pubDate>Wed, 28 May 2008 23:54:01 +0000</pubDate>
		<dc:creator>John Sedlak</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Coding]]></category>
		<category><![CDATA[SharePoint]]></category>
		<category><![CDATA[ASP.NET]]></category>

		<guid isPermaLink="false">http://jsedlak.com/?p=19</guid>
		<description><![CDATA[One of the tasks I had recently was to get not only a web page into a SharePoint page but also pass in parameters from the Query String. Let&#8217;s say I am going to create the page at http://localhost/sharepoint/mypage.aspx in a normal way. In order to host a page inside that SharePoint page, we can [...]]]></description>
			<content:encoded><![CDATA[<p>One of the tasks I had recently was to get not only a web page into a SharePoint page but also pass in parameters from the Query String. Let&#8217;s say I am going to create the page at http://localhost/sharepoint/mypage.aspx in a normal way. In order to host a page inside that SharePoint page, we can use a Page Viewer Web Part, but this limits what can be done. Instead, we can create a custom web part to do the work&#8230;</p>
<div style="text-decoration: line-through;">Please excuse me if the code isn&#8217;t exactly correct. I do not have the code in front of me right now and will update it when I do.</div>
<p><br/></p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p19code10'); return false;">View Code</a> CSHARP</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p1910"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
</pre></td><td class="code" id="p19code10"><pre class="csharp" style="font-family:monospace;"><span style="color: #0600FF; font-weight: bold;">public</span> <span style="color: #6666cc; font-weight: bold;">class</span> CustomWebPart <span style="color: #008000;">:</span> WebPart <span style="color: #008000;">&#123;</span>
    <span style="color: #0600FF; font-weight: bold;">public</span> <span style="color: #0600FF; font-weight: bold;">override</span> <span style="color: #6666cc; font-weight: bold;">void</span> Render<span style="color: #008000;">&#40;</span>HtmlTextWriter writer<span style="color: #008000;">&#41;</span><span style="color: #008000;">&#123;</span>
        <span style="color: #6666cc; font-weight: bold;">string</span> rawUrl <span style="color: #008000;">=</span> Context<span style="color: #008000;">.</span><span style="color: #0000FF;">Request</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Url</span><span style="color: #008000;">.</span><span style="color: #0000FF;">OriginalString</span><span style="color: #008000;">;</span>
        <span style="color: #6666cc; font-weight: bold;">int</span> index <span style="color: #008000;">=</span> rawUrl<span style="color: #008000;">.</span><span style="color: #0000FF;">IndexOf</span><span style="color: #008000;">&#40;</span><span style="color: #666666;">&quot;?&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
        <span style="color: #6666cc; font-weight: bold;">string</span> query <span style="color: #008000;">=</span> <span style="color: #6666cc; font-weight: bold;">String</span><span style="color: #008000;">.</span><span style="color: #0000FF;">Empty</span><span style="color: #008000;">;</span>
        <span style="color: #0600FF; font-weight: bold;">if</span><span style="color: #008000;">&#40;</span>index <span style="color: #008000;">!=</span> <span style="color: #008000;">-</span><span style="color: #FF0000;">1</span><span style="color: #008000;">&#41;</span> query <span style="color: #008000;">=</span> rawUrl<span style="color: #008000;">.</span><span style="color: #0000FF;">Substring</span><span style="color: #008000;">&#40;</span>index<span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
&nbsp;
        writer<span style="color: #008000;">.</span><span style="color: #0000FF;">Write</span><span style="color: #008000;">&#40;</span>
            <span style="color: #666666;">&quot;&lt;iframe src='http://localhost/sharepoint/myOtherPage.aspx&quot;</span> <span style="color: #008000;">+</span> query <span style="color: #008000;">+</span> <span style="color: #666666;">&quot;' width='100%' height='765px'/&gt;&quot;</span>
        <span style="color: #008000;">&#41;</span><span style="color: #008000;">;</span>
    <span style="color: #008000;">&#125;</span>
<span style="color: #008000;">&#125;</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://jsedlak.org/2008/05/28/hosting-a-page-inside-a-sharepoint-page/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
