3

To integrate an external news feed, I've setup an overview page + wildcard detail page.
To load the detail page, the last URL segment contains the title and is used to get the required data externally. That way my overview + detail page works fine.

Now the actual issue.
Since it's a wildcard page, its presentation details + values are used for each detail page. Which results in the same page title, metadata, header image, ... for each news item.
I could adjust all of my renderings to check if it's used on a wildcard page, but that seems unmanageable.
I'd rather be able to adjust the wildcard page values on the go.

I found the following article which seems to describe what I require: http://www.awareweb.com/awareblog/using-sc-wildcard
I was just wondering if any of you has a similar use case and perhaps a more recent solution for this.

2 Answers 2

1

If you have output that should pull from an external piece of data and not from the current Sitecore item, then by definition you can't use renderings and logic that has been built only to look at the current Sitecore item.

As you pointed out, this likely means adjusting all your renderings. You could use controller logic to determine the current Model for a rendering and keep the same View, just the model is changed by the Controller.

You could also use separate renderings that have specific logic for this scenario, which is probably easier to build initially but does mean you have repetition of your View, and possibly Model and Controller.

0

You can try usign my module for wildcards https://vladimirhil.com/2016/02/22/wildcards-module-for-sitecore-7-using-content-search-api/

I use it on at least 3 projects seems to be all ok.

In regards to your question - your renderings should use RendeingItem or PageItem properties of the rendering model for reading fields.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.