Content Preview: rss
1088 days ago
Recently, we had a question on plugging a custom DataEngine into Sitecore: http://sdn5.sitecore.net/SDN5/Forum/ShowPost.aspx?PostID=529 While the DataEngine itself is not pluggable, the individual commands making up the engine is. That allows you to override any command in the engine. To illustrate what the engine actually does, here is the code for DataEngine.GetItem: public Item GetItem(ID itemId, Language language, Version version) { GetItemCommand command = Commands.GetItemPrototype.Clone(); command.Initialize(itemId, language, version); return command.Execute(); } All methods look like this (with different command prototypes). To override the behaviour of the GetItemCommand, all you need to do is to assign your own class to the GetItemPrototype property. In V5.3, you have to do this in code (in a hook, for instance). In V5.3.1 you will be able to do it directly from web.config. For the hook, ...
1088 days ago
In V5.3 it is possible to completely disable security for all descendants of WebControl (including XslFile). Simply set the property 'DisableSecurity' to 'true' on the control. For XSLT files, we have created two new XSL controls that can be used to enable and disable security for specific sections in an XSLT file. An example is provided below: <xsl:template match="*" mode="main"> <h2>Security enabled</h2> <sc:enableSecurity> <xsl:for-each select="item"> Child <xsl:value-of select="position()"/><br/> <sc:text field="@name"/><br/> <br/> </xsl:for-each> </sc:enableSecurity> <h2>Security disabled</h2> <sc:disableSecurity> <xsl:for-each select="item"> Child <xsl:value-of select="position()"/><br/> <sc:text field="@name"/><br/> ...
1096 days ago
<sc:image> now supports the following attributes ( bold indicates default values): field => The name of the image field (same as V5.2). select => The xpath to the item. (same as V5.2 with '.' as the default value). allowStretch => Allow stretching the image beyond its original size? Legal values: [true false ]. Same as the 'as' parameter for media URLs. backgroundColor => Background color for the border added when an image is strecthed beyond its original size (and allowStretch=false). Legal values: Color names (ie. red, blue, etc.) and HTML hex color codes (ie. CE55E2). Same as the 'bc' parameter for media URLs. database => The name of the database to pull the image from? Legal values are any of the defined database names. The default value is the content database of the current site (if no content database is defined, the regular site database is ...
1452 days ago
The following will apply to the release build of Sitecore 5.1.1 In Sitecore you can create special 'proxy' items that serve as links between different items. The items being linked may come from different databases. For instance, say I have the following structure: A -B -C -D -E -F Now I want to expose E and its children below B such that E can be found both below B and below C. The way to do it is: Start the Sitecore Shell Select 'Deactivate proxies' from the database menu (in the lower right corner next to the clock) Open the Content Editor Navigate to B Create a new item below B from the template 'Proxy' Fill in the field 'Target item' with the ID of E Save Select 'Activate proxies' from the database menu E will now appear below B and its data and children will be shown when it is selected. The E below B is shown in a different color to signify that it is only a 'shadow' of the real E. A -B ...



