Portal Engine Questions on portal engine and web parts.
Version 7.x > Portal Engine > Shared News suggestions View modes: 
User avatar
Member
Member
vcarter - 9/4/2013 2:30:14 PM
   
Shared News suggestions
I have a central repository for all client news on their primary site. This news is categorized by business unit and region. On one of my subordinate sites, I created a query repeater to pull the news from the main site. I opted to do this over linked documents since linking would still require link creation on the sub site and I wanted it to be a dynamic process.

So I have this working just fine, and now I am thinking about how to display the news. I would like to keep the visitor on the current site when showing the news detail, however, since the news exists elsewhere it obviously links back to its origin.

My though was to create a detail page template on the sub site that gets the detail information by leveraging the URL selected(essentially the document name).

What I am wondering is if there is a way to fudge the alias path so that any item coming from the sub site with "news" in the URL followed by something else would go to the detail page, but still show the full manufactured URL.

So I have:

http://MainSite.com/NewsRoom/Article1.aspx

and I want

http://SubSite/NewsRoom/Article1.aspx

without having to create linked pages for each article. Any macro suggestions, maybe something I can use in the alias path for my news page that might do this?

Hope this makes sense.

User avatar
Kentico Support
Kentico Support
kentico_jurajo - 9/5/2013 2:29:50 AM
   
RE:Shared News suggestions
Hi,

I am afraid but you will have to either create some custom transformaiton function that will get the data from the main site and link them somehow to the subsite or, use linked documents. The data are obviously not present for the "subsite" content and context, so the system won't find given URL path because it does not exist.

You can e.g. use custom event handler to create the linked document automatically when the original is created.

Best regards,
Juraj Ondrus

User avatar
Member
Member
vcarter - 9/6/2013 12:13:33 PM
   
RE:Shared News suggestions
That is what I figured, thank you for the response.

User avatar
Kentico Legend
Kentico Legend
Brenden Kehren - 9/5/2013 9:54:30 AM
   
RE:Shared News suggestions
Couldn't you use a query repeater and specify a custom query in your news doc type using View_CONTENT_News_Joined query and specify in the where clause what site name/id you'd like to use? Your custom query could look like this
SELECT ##TOPN## ##COLUMNS## FROM View_CONTENT_News_Joined WHERE ##WHERE##
Of course the News doc type would have to be available to all sites you are accessing.

User avatar
Member
Member
vcarter - 9/6/2013 12:12:50 PM
   
RE:Shared News suggestions
FroggEye, yeah that is what I am doing, the filtered data list works perfectly, I am trying to fool Kentico into using a generated URL so that things like breadcrumbs and detail links appear as if the news actually exists on my sub site.

It's all about tweaking the user experience at this point. I am going to keep trying and will update should I find a solution.

User avatar
Kentico Legend
Kentico Legend
Brenden Kehren - 9/8/2013 11:02:07 PM
   
RE:Shared News suggestions
Not sure about the breadcrumbs but you can create your own URL with a custom macro/function. For instance you could look at the current site and maybe a node ID and generate the URL as needed. Off the top of my head I'm not sure but this method might already exist. As far as the breadcrumbs, you'd have to use a repeater or another webpart vs. the breadcrumbs webpart.

User avatar
Member
Member
vcarter - 9/9/2013 8:19:32 AM
   
RE:Shared News suggestions
Hmm, I have some ideas for the breadcrumb, but I am pretty sure a page can match a pattern as an alias, so I could just generate the link as usual, since my detail page is pulling from a query anyway.

So http://sub-site/News/Article1/ would be fine. So long as the Document URL path/pattern was looking for something like:

http://sub-site/News/{pattern here}/

Now I just need to figure out what pattern to use. And for the breadcrumbs, I guess I could use a transformation to append the current article to the end of the crumbs list as a non link...