Skip to main content

Posts

Sitecore 2-Letter Aliases

I ran into an issue today while using the Aliases feature in Sitecore. What I was trying to do was put the following Aliases in and pointing them to some internal item. TR SR However, when I tested it out, it was returning an error in my page instead of redirecting to the corresponding target item. I tried to republish, remove any redirect logic or IIS redirects to isolate the issue, but the problem persisted.  Then it dawned on me, that Sitecore maybe using this 2 letters as a language key. Which seemed to turn out to be true. When I tried to use something like: http://hostname/en (works) http://hostname/tr (fail) - this basically translates to fetch me the Turkish content  http://hostname/sr (fail) - this basically translates to fetch me the Serbian content  So basically, SC is resolving these 2 letter links as sort of language switches.  So for now, I'd be refraining from using any two-letter combo for Aliases in the list provided in this page: https://en
Recent posts

Brightcove Index Configuration for Coveo for Sitecore

We recently moved our search provider from using Endeca and Lucene to Coveo for Sitecore. One of the areas that broke was the Brightcove index. You may follow the sample below to be able to get your Brightcove index working again:  1) In your Brightcove contentsearch config, comment out or remove the sections highlighted below 2) Replace this with the one below: 3) Check the comments in the image above to determine what to use for your DefaultIndexConfiguration 4) Comment or remove the entire section/block 5) Your final config may look something like below Hope this helps someone. Thanks for reading.

SharePoint Integration Framework (1.1.0 rev. 130613) for Sitecore - Use Cases

If you were wondering how a non-bi-directional SPIF works in different use cases, you may want to look at the table below based from my testing. # Sharepoint Changes Supported? SPIF Notes 1 Folder created Y Folder created Do not name the folder or file with special chars like "-" 2 Folder deleted Y Integration folder is deleted This deletes any items in the folder 3 Folder renamed N Rename not supported Refrain from renaming folders in Sharepoint to avoid confusion - it wont get renamed in SC Folder is still connected and any items added or updated under it gets syncd   3.1 Upload File   Y File is pulled into SC similar to #5 Still syncs even though folder name is different 4 Folder Moved? N Folder is deleted Gets recreated as a new folder in the target location and any items under it 5 File uploaded Y File is pulled to SC

Add/Allow a different media URL prefix in Sitecore (aside from tilde ~) in Sitecore 7.0

We recently had a requirement when one of our external vendors required that our media URLs should not include the "~" in the link as their system could not process those correctly. I found a few articles in the web, but most of them would suggest changing the default behavior, i.e. any "new" media item would have the 'new' replacement character though still supporting the tilde "~". Based on the web articles, I started with the following config keys and section: Media.RequestExtension Media.MediaLinkPrefix customHandlers We did not want to change any of the default behaviors, we just needed a way to make Sitecore support the additional URL media prefix. While sifting through the configuration, I chanced upon the following section: <mediaPrefixes>  According to the comment above it: Allows you to configure additional media prefixes (in addition to the prefix defined by the Media.MediaLinkPrefix setting)            The

SVG Files and Sitecore

Sitecore by default does not support the SVG image types. You'd have to incorporate the following in your web.config to be able to make SC serve the SVG as an image instead of a file for download.        <mediaType name="SVG image" extensions="svg">           <mimeType>image/svg+xml</mimeType>           <forceDownload>false</forceDownload>           <sharedTemplate>system/media/unversioned/image</sharedTemplate>           <versionedTemplate>system/media/versioned/image</versionedTemplate>           <mediaValidator type="Sitecore.Resources.Media.ImageValidator"/>           <thumbnails>             <generator type="Sitecore.Resources.Media.ImageThumbnailGenerator, Sitecore.Kernel">               <extension>png</extension>             </generator>             <width>150</width>             <height>150</height>        

Web Forms For Marketers - Custom Unique ID Field Type

I recently had a request from the business to implement a unique 8-digit (auto-incrementing) Reference number for one of their Forms. Doing a quick scan in the available Field types, I found that there wasn't any type available that fits my requirement.  I had two options to consider: Override the Save to DB action: by overriding the Execute method and replacing the AdaptedResultList with my own which queries the WFM DB and looks for the Max Reference value and returns the incremented value at that instance; this worked well but I quickly ran into an issue wherein other Save Actions (like Send Email) were still using the original AdaptedResultList and thus the experience was inconsistent. If I were to go this route, I would have to override every possible Save action which is not very good. So I concentrated with my next option:   Create my own Custom Field Type: I created my own type, did the necessary changes in the WFFM module settings like (add a new Field Type referencin

Add Export to File Functionality in Sitecore's Search Options

One of our business users was requesting for a listing of items they've already added and have it available in a format that can be opened in a spreadsheet (Excel). My initial thought was to create a blank aspx page and write all the logic to get the data in the code-behind, run it and save the resulting file to a csv then I'm done. But then it got me to think, it might be a better idea to have this functionality plugged in to Sitecore and made available for everyone to use.  Sitecore Bucket's Search Options fly-out seemed a good candidate for this feature (See image below). So doing some quick readings I got myself in to the "zone" and started implementing this quick and dirty PoC. Just to explain what it actually does. User will basically do a search, ( Note that all search options require some filters or search keyword before any of the options can be used ) clicks the Export to File, it pops up a dialog to confirm the action and executes, after w