API Questions on Kentico API.
Version 6.x > API > How to display search keyword in transformation? View modes: 
User avatar
Member
Member
tony@3t - 2/9/2012 9:13:21 AM
   
How to display search keyword in transformation?
In the search result page, I want to display like this - Your search for "keyword" returned 10 results. I found search API has "searchtext", but how can I make it displayed in transformation?

Thanks!

Tony

User avatar
Kentico Support
Kentico Support
kentico_janh - 2/10/2012 4:41:28 AM
   
RE:How to display search keyword in transformation?
Hello,

I suppose, that you don't want to display this text for every single item in your transformation, but only once before the smart search result, so I suggest you to fill this text to a Content before property of the smart search result web part. And finaly, you can get the information about the keyword, which is searched, from a querystring parameter, because the keyword is contained in the URL of a search result page.

Best regards,
Jan Hermann

User avatar
Member
Member
tony@3t - 2/10/2012 1:51:08 PM
   
RE:How to display search keyword in transformation?
I used {%searchtext%} to get the keyword in static text. Thanks for the tips!