I have experienced the same thing. The problem is the getter on the Property method.
There is a solution:)
You can add you own logic on the getter, based on the default getter.
public class SyncPagesOnPublish : PlugInAttribute
{
public static void Start()
{
PropertyDataCollection.GetHandler = EPiFixes.FetchDataFrom.OwnPropertyHandler;//override Property["xyz"]
}
}
public class FetchDataFrom
{
public static PropertyData OwnPropertyHandler(string name, PropertyDataCollection properties)
{
PropertyData prop = PropertyGetHandler.DefaultPropertyHandler(name, properties);
if (prop != null && prop.IsNull && !prop.IsDynamicProperty)
{
//Lagt til så man ikke får engelsk ingress på franske sider
if (!prop.IsLanguageSpecific)
{
PropertyData data = properties.Get("PageShortcutType");
if (((data == null) || (data.Value == null)) ||
(((PageShortcutType)data.Value) != PageShortcutType.FetchData))
return prop;
data = properties.Get("PageShortcutLink");
if (data == null)
return prop;
PageReference pageLink = (PageReference)data.Value;
if (!PageReference.IsValue(pageLink))
return prop;
if (properties.Get("PageLink") != null && (properties.Get("PageLink") is PropertyPageReference))
{
if (pageLink.CompareToIgnoreWorkID((properties.Get("PageLink") as PropertyPageReference).PageLink))
return prop;
}
PageData page = DataFactory.Instance.GetPage(pageLink, LanguageSelector.MasterLanguage());
if (page != null)
{
data = page.Property.Get(name);
if (data != null)
return data;
}
}
}
return prop;
}
This problem has been reported as a bug in R2SP2. It's fixed in CMS6 RC1.
Bug: #30205 non language specific properties and shortcut/external link
You can check the bug report on our public bug list http://world.episerver.com/Support/Bug-List/
/Stefan
We are having a problem with images (URL to image property) not working when we use the feature “Fetch data from page in EPiServer CMS” in combination with multi language pages.
What we do is create a page witch has page property “URL to image”. This property has unselected “Unique value per language”. Then we create another page that gets its data from the first page using the Link type: “Fetch data from page” under the tab “Shortcut/External Link” So far so god – the image(s) will show up on the new page. Then we create a new language version of the latter page and the image(s) disappear (Other fields/properties will show up nicely).
Are we doing something wrong or is this a bug?
Step by step to reproduce our problem:
And an alternative way to get the same problem:
We are using EPiServer CMS 5.2
Any help/input are appreciated