Portal Engine Questions on portal engine and web parts.
Version 4.x > Portal Engine > Using page name in the where condition of a repeater View modes: 
User avatar
Member
Member
ojeffery-bishopfleming.co - 8/12/2009 4:56:14 AM
   
Using page name in the where condition of a repeater
Hi,

I'd like to exclude a document from a repeater, only if a certain field within the document (in this case called 'contactKeyContact') is the same as the name of the page the repeater's on.

Scenario is I have a page with a list of contacts(taken from a repeater), but one of them is the main contact for that page and so needs to be included at the top of the page, in a separate repeater.

The page name is 'Care Homes', so the URL comes out as care-homes.aspx. The contactKeyContact field is set as Care Homes.

Is there a simple way I can do this?

Many thanks, Oli.

User avatar
Kentico Developer
Kentico Developer
kentico_helenag - 8/12/2009 11:31:13 AM
   
RE:Using page name in the where condition of a repeater
Hi Oli,

You may use the WHERE condition like this:

contactKeyContact LIKE '{%DocumentName%}'

Best regards,
Helena Grulichova