Delen via


Custom Master Page and List

As mentioned in my last blog Setting up Permissions MOSS 2007 & Installing Custom Master Page today I have been making some changes to our master page.

I did not want to stay with the general look and feel of SharePoint, so using a basic template I have created a custom master page for our school/college.

It has taken me a while to pick up ASP.NET and C# but I have got there in the end, I still have allot of changes to make to our master page but it is now at a stable version.

I have taken away the left hand navigation bar as the only site we were going to use this on was Staff and Student sites, and as the custom master page is allot bigger then a default SharePoint master page having the left hand menu did take up more space which it really did not have to.

So, I ditched the Left hand nav bar by taking out the ASP Code/Headers on the master page BUT these have to still be on the master page for it to work so they have to be hidden, I wont go into too much detail at this stage as I will do a full blog post on creating and editing a master page.

Hide unwanted content

Open your masterpage in Microsoft Office Sharepoint Designer which is available free from: Download SPD from Microsoft Office Online

To hide content at the bottom of the master page after </form> insert the following code:

_______________________________________________________________________________________________

<!--
\\\\\\\\\\\\\\\\\
Everything in this panel is hidden
\\\\\\\\\\\\\\\\\
-->
<asp:Panel Visible="false" id="hide_away" runat="server">

_______________________________________________________________________________________________

*Do not add the above code every time you want to hide content, only add the below*

_______________________________________________________________________________________________

<!--
**************************************************************************************************************************************
Top Nav Bar  REPLACE WITH NAME OF CONTENT
**************************************************************************************************************************************
-->
<asp:ContentPlaceHolder id="PlaceHolderTopNavBar" runat="server">
</asp:ContentPlaceHolder>
<!--

REPLACE CODE WITH CORRECT CODE FOR CONTENT YOUR HIDING
**************************************************************************************************************************************
Top Nav Bar
**************************************************************************************************************************************
-->

________________________________________________________________________________________________

Custom Master Page

This master page will be used through-out our learning platform, but for our portal I have decided to use the default SharePoint master page and just change the CSS, once I have completed the development of the learning platform and the staff/students/parents are using it with no problems I will the work on a new master page for our portal.

I have attached a preview of my master page at it's current development stage, but please understand this is only a draft I will be making more changes over the next few days, once I have completed the master page to a professional standard I will blog about the completed product and explain how you could do this yourself.

I need to create a proper version of the main header, so the images mould together properly giving a more professional feel for our school/college at the moment that was just a test to see how it looked with images and without. After showing a few members of staff it appears the master page with an image header is the best out of the two so I will create a new image to sit there tomorrow.

So what have I done with the subject links, as I don't have a left nav bar anymore? ?

Well, after speaking with another school who has been looking at the same idea it was decided we were going to create a list of subjects and then using the "I need to..." webpart we inserted a drop down list of subjects that students/staff can click on to find there subject and then click on "go" to navigate to there subject area.

I have only created Mathematics and ICT & Business subject sub-sites at the moment but I have included the list on the print screen attached if you're interested on how it looks.

I personally think this is far better then having a long list down the left hand side of your page, this way it gives us a larger content area for us to work with.

What is next?

So tomorrow, I will be continue to develop my master page as it has a few slight bugs in it at the moment and I will continue to create the content for the staff site hopefully moving on to the student's site later on in the afternoon.

In tomorrows blog I will also explain how you can create a list and display it as a drop down select list like I have done.

If you have any questions please feel free to contact me

James.