How can i know if a given SPWeb is a SearchCenter site programmatically

556 views Asked by At

I have a SPWeb object and I want to know whether or not this is a SearchCenter site. How can I know it programmatically. Is there some setting to check or a guid to match etc?

2

There are 2 answers

2
Lars Fastrup On

A SearchCenter is created from a special site template that you can identify from the WebTemplate property on the SPWeb object. It will carry the value 'SRCHCEN'.

0
Kasper On

I am not sure, but the Feature ID GUID shown here might be a global one.