November Happy Hour will be moved to Thursday December 5th.

Fetching data from another page

Vote:
 
Hi! As i wrote in a previous post I'm making some final adjustments to a site built on EPiServer 4.50 and I am new to both EPiServer and C#. I now need the ability to fetch some content from other pages on the same site. For instance if I have a page structure such as this: Home -- Contact information ---- Main office ---- Smaller office 1 ---- Smaller office 2 and the "Main office" page contains a textproperty with the adress, I would like to show/import that to a textproperty on the "Home" page. Then everytime I update the textproperty on the "Main office" page it would automaticly get updated on the "Home" page. I've been trying to find solutions to this on both this forum and in the different pdf's published on this site but so far I haven't managed to figure out how to do this. Any help would be appreciated! I should also mentioned that I've installed EPiFields which i guess could provide the solution for this but I haven't been able to create a page that provides fields that I can use on other pages. I have of course looked at the samples that go along with EPiFields but all I can find there is dataproviders that fetch either external HTML-data or XML and SQL data.
#12567
Mar 28, 2006 11:04
Vote:
 
Use the Property WebControl, add a property to the pagetype that Home is of type PageReference(Sida). The property control will display the information in the PropertyName from source page Pointed out in PageLinkProperty. /HAXEN
#14519
Mar 28, 2006 14:42
Vote:
 
Thank you! One problem though: When browsing in edit mode content that is "imported" from another page is not shown. It does show when viewing the public, published site and also in edit mode directly after saving the specific page. While the functionality works, which is the most important thing, it could make it harder for the editor. What could be wrong? If this is a bug or made by design, is there a workaround?
#14520
Mar 30, 2006 8:32
Vote:
 
I haven't seen that problem so I don't know if it's by design or not. But another way to do it that I would probably have choosen is to have the property as a dynamic property, so you can set it for all or part of the page structure. In that way the property exists on all pagetypes and can be implemented in the framework. Drawback though if set in the page structure there is no way to have it removed/cleared below in the structure. That is by design for dynamic properties. /HAXEN
#14521
Mar 30, 2006 13:52
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.