Re: Adding default webparts to areas and web part pages in SPS
From: Brad Smith (asmodean_at_cox.net)
Date: 03/05/04
- Next message: Robert: "Re: SPS 2003 Version Control Issue?..."
- Previous message: Brad Smith: "Re: Page Viewer Web part height"
- In reply to: Anders: "Re: Adding default webparts to areas and web part pages in SPS"
- Next in thread: Anders: "Re: Adding default webparts to areas and web part pages in SPS"
- Reply: Anders: "Re: Adding default webparts to areas and web part pages in SPS"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 4 Mar 2004 20:21:59 -0500
You will only be able to add the webpart you are describing to the area and
site templates (default.aspx). The allitems.apsx pages and other admin
pages do not have webpart zones, and so cannot contain webparts. Further,
you cannot edit the pages that are in the _layouts virtual with Frontpage.
The only way you would be able to produce the effect would be to alter the
site definition templates that they are created from.
As for the custom web part pages, I haven't seen a corresponding config file
to list the default webparts for one though you can modify the site
definition template that it is created from the same as the _layouts
templates.
-Brad
"Anders" <raskpetersen@hotmail.com> wrote in message
news:547475ee.0403040756.26a04db8@posting.google.com...
> Could it be true that noone have messed around with modules in
> ONET.XML or tried to add default web parts in the templates? :-O
>
> Maybe ill get an answer if i try to rephrase my question ;-)
>
> What i need to do is to add default web parts to both area templates
> (default.aspx), list templates (fx. allitems.aspx) and any other WSS
> template that are present in the area template structure.
>
> The first part of this works fine: i can get default web parts in my
> default.aspx pages (sub areas) by customizing the <modules ..> section
> of ONET.XML for the area template. But since the web part i am
> inserting is a navigation template that is inserted into a new web
> part zone i also need the web parts to show up in lists, web part
> pages etc...
>
> Since the documentation in MSDN library and the SDK is *really* poor,
> i would be really grateful if some MVP or other guru could please help
> me out :-o
>
> Thanx
> //AndersR
>
> raskpetersen@hotmail.com (Anders) wrote in message
news:<547475ee.0402170326.5f9d5d29@posting.google.com>...
> > Hi,
> >
> > ive been working with customizing the area templates in SPS and have
> > come along way in understanding how things are connected.
> >
> > There is however one thing that i just cant get to work: adding
> > default web parts to lists, web part page templates etc.
> >
> > I have created a custom area template
> > (..60\TEMPLATE\1033\CUST_SPSTOC). In that i have added a custom
> > webpartzone (navbarzone) to wich i want to add a custom web part.
> >
> > This works fine in all "areas" but in lists
> > (CUST_SPSTOC\LISTS\somelist) and web part pages (fx. the templates in
> > CUST_SPSTOC\DOCTEMP\SMARTPGS\) the zone is there but no web parts are
> > inserted!
> >
> > I have edited the ONET.XML for the area template as follows:
> > <Module Name="Default" Url="" Path="" RootWebOnly="FALSE">
> > <File Url="default.aspx" Type="Ghostable">
> > <AllUsersWebPart WebPartZoneID="navbarzone"
> > WebPartOrder="0"><![CDATA[
> > <WebPart xmlns="http://schemas.microsoft.com/WebPart/v2" >
> > <Title>Nav webpart - DONT REMOVE</Title>
> > <Description>GetDepartmentFromAD</Description>
> > <Assembly>GetDepartmentFromAD</Assembly>
> > <TypeName>GetDepartmentFromAD.GetDepartmentFromAD</TypeName>
> >
> > <FrameType>None</FrameType>
> > <FrameState>Normal</FrameState>
> > <AllowRemove>false</AllowRemove>
> > <AllowClose>false</AllowClose>
> > <AllowZoneChange>false</AllowZoneChange>
> > <AllowMinimize>false</AllowMinimize>
> > <IsVisible>true</IsVisible>
> >
> > </WebPart>
> > ]]></AllUsersWebPart>
> > </File>
> > </Module>
> >
> > I have searched and read the CAML reference and its still a bit
> > unclear to me how you define what a <MODULE ..> really is and how you
> > get a module to add web parts certan places. I also tried inserting
> > the web part in the WebPartPopulation instead, but this didnt work
> > either.. :-S
> >
> > Any help is greatly appreciated since im on a nasty deadline (as usual
> > ;-)
> >
> > thanx
> > //AndersR
- Next message: Robert: "Re: SPS 2003 Version Control Issue?..."
- Previous message: Brad Smith: "Re: Page Viewer Web part height"
- In reply to: Anders: "Re: Adding default webparts to areas and web part pages in SPS"
- Next in thread: Anders: "Re: Adding default webparts to areas and web part pages in SPS"
- Reply: Anders: "Re: Adding default webparts to areas and web part pages in SPS"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|