Portal Engine Questions on portal engine and web parts.
Version 5.x > Portal Engine > Subscribe to a topic and display results based on subscription View modes: 
User avatar
Member
Member
smuhajir-hotmail - 9/16/2011 11:36:44 AM
   
Subscribe to a topic and display results based on subscription
Hi,
Im looking for some guidance or insight into how to approach this. I believe there are two pieces to this, any insight as to where I should look for more info or how to go about implementing these features would be greatly appreciated.
1) Allow a user to subscribe to a topic or discussion. Keep a count of the user base for these topics or discussions. Similar to "Subscribe to post" on this page below.
2) While searching, display the results based on the user count as relevance to the search field. In other words, display the number of users that have subscribed to that article or topic.

Pls let me know if there are readily available features that I could use or if I need to get into custom search provider and custom tables for these.
Let me know if this makes sense or if you need more information.
Thanx in advance.

User avatar
Kentico Support
Kentico Support
kentico_radekm - 9/19/2011 1:34:18 AM
   
RE:Subscribe to a topic and display results based on subscription
Hello.

1. For some modules, like blogs or forums, this functionality is implemented by default. If you want for subscribe to any document in general (covering create/update/delete changes), you can use Content subscription: http://devnet.kentico.com/docs/devguide/subscribing_users_to_content_changes_notifications.htm

2. Are you using SQL Search or Smart search? Do you want to bypass default Smart search relevance by some other value? It is possible using “Search sort” property, however this property is limited only to fields (columns) of given document type. So, you would need to have a custom field in given document type and store number of subscribers within.

Best Regards,
Radek Macalik

User avatar
Member
Member
smuhajir-hotmail - 9/19/2011 8:01:26 AM
   
RE:Subscribe to a topic and display results based on subscription
Thanx Radek. Let me ask this another way and I'll answer your questions in the process as well.
Yes, I would like to use the smart search capability if possible and maybe even tweak with some custom fields etc..
What if I want to use a "Like" feature that some of the other forums have indicating that I like that topic or approve of the response in that topic? Was initially thinking we could use subscription event for this. But now Im wondering if there is a way to keep it seperated?
So, the idea would be to have a "Like" button on a topic that the user would click. The search would bypass the content rating feature, but would display the number of likes for that content from the smart search feature?
Thank you for your time, hope you can point me in the right direction,
REgards,
Shak

User avatar
Kentico Support
Kentico Support
kentico_radekm - 9/26/2011 1:54:17 AM
   
RE:Subscribe to a topic and display results based on subscription
Hello.

It is possible to use Smart search for custom field, too. For more info, please see following link: http://devnet.kentico.com/docs/devguide/smart_search_search_syntax.htm

I believe you can still use approach I suggested. At first, you need to extend given document type by extra column, where given number (“Like index”) will be stored. This can be done in Site Manager / Development / Document types / edit / Fields tab. Then, you can develop a custom web part / User control (http://devnet.kentico.com/docs/devguide/developing_web_parts.htm) and increase Like index in code-behind, when button is clicked. This can be done in API (http://devnet.kentico.com/docs/devguide/update_document.htm).

In code-behind, you can get current TreeNode and get and increase value of given field via SetValue / GetValue method. Then, you can search this field according to first link I provided.

Best Regards,
Radek Macalik