About Dragan Todorovic

Senior Consultant for SharePoint & O365 services with more than 8 years of experience. Fan of web technologies and cloud services.

Simple jQuery Autocomplete

<span class="doctype"><!doctype html></span>
<span class="tag"><<span class="title">html</span> <span class="attribute">lang</span>=<span class="value">"en"</span>></span>
<span class="tag"><<span class="title">head</span>></span>
<span class="tag"><<span class="title">meta</span> <span class="attribute">charset</span>=<span class="value">"utf-8"</span>></span>
<span class="tag"><<span class="title">title</span>></span>jQuery UI Autocomplete - Default functionality<span class="tag"></<span class="title">title</span>></span>
<span class="tag"><<span class="title">link</span> <span class="attribute">rel</span>=<span class="value">"stylesheet"</span> <span class="attribute">href</span>=<span class="value">"//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css"</span>></span>
<span class="tag"><<span class="title">script</span> <span class="attribute">src</span>=<span class="value">"//code.jquery.com/jquery-1.10.2.js"</span>></span><span class="tag"></<span class="title">script</span>></span>
<span class="tag"><<span class="title">script</span> <span class="attribute">src</span>=<span class="value">"//code.jquery.com/ui/1.11.4/jquery-ui.js"</span>></span><span class="tag"></<span class="title">script</span>></span>
<span class="tag"><<span class="title">link</span> <span class="attribute">rel</span>=<span class="value">"stylesheet"</span> <span class="attribute">href</span>=<span class="value">"/resources/demos/style.css"</span>></span>
<span class="tag"><<span class="title">script</span>></span>
$(<span class="keyword">function</span>() {
<span class="keyword">var</span> availableTags = [
<span class="string">"ActionScript"</span>,
<span class="string">"AppleScript"</span>,
<span class="string">"Asp"</span>,
<span class="string">"BASIC"</span>,
<span class="string">"C"</span>,
<span class="string">"C++"</span>,
<span class="string">"Clojure"</span>,
<span class="string">"COBOL"</span>,
<span class="string">"ColdFusion"</span>,
<span class="string">"Erlang"</span>,
<span class="string">"Fortran"</span>,
<span class="string">"Groovy"</span>,
<span class="string">"Haskell"</span>,
<span class="string">"Java"</span>,
<span class="string">"JavaScript"</span>,
<span class="string">"Lisp"</span>,
<span class="string">"Perl"</span>,
<span class="string">"PHP"</span>,
<span class="string">"Python"</span>,
<span class="string">"Ruby"</span>,
<span class="string">"Scala"</span>,
<span class="string">"Scheme"</span>
];
$( <span class="string">"#tags"</span> ).autocomplete({
source: availableTags
});
});
<span class="tag"></<span class="title">script</span>></span>
<span class="tag"></<span class="title">head</span>></span>
<span class="tag"><<span class="title">body</span>></span>
<span class="tag"><<span class="title">div</span> <span class="attribute">class</span>=<span class="value">"ui-widget"</span>></span>
<span class="tag"><<span class="title">label</span> <span class="attribute">for</span>=<span class="value">"tags"</span>></span>Tags: <span class="tag"></<span class="title">label</span>></span>
<span class="tag"><<span class="title">input</span> <span class="attribute">id</span>=<span class="value">"tags"</span>></span>
<span class="tag"></<span class="title">div</span>></span>
<span class="tag"></<span class="title">body</span>></span>
<span class="tag"></<span class="title">html</span>></span>

Click-to-Run and Window Installer on same computer?

“We’re sorry, Office Click-to-Run installer encountered a problem because you have these Windows Installer based Office programs installed on your computer”

 

Unfortunately, you can’t have Office products of the same version (like 2013 or 2016) that use two different installation technologies (Click-to-Run and Windows Installer) installed on the same computer. To fix this problem, remove the Windows Installer version of Office. Then, retry the installation of Office you were doing when you got the error message.

Outlook 2016 Search Not Working

Microsoft Outlook 2016 problem with POP & IMAP content searching? Microsoft Office 365 ProPlus installation contains Outlook 2016 as a standard application with search capabilities, but somehow many users reported problems with mail search for IMAP accounts.   I did manage to find tons of helpful notes on the web which helped me to understand the problem, and I would like to share solution in a few steps:

 

Remove Outlook 2016 from Index:

  1. Go to Outlook Settings (File | Options)
  2. Go to the Search settings
  3. Click on Indexing Options
  4. Click Modify and deselect Microsoft Outlook
  5. Click Close to dismiss dialog box
  6. Exit Outlook

Check OST and PST permissions:

  1. Find all OST and PST files that you’re using on your computer. In Windows 8, OST files are usually hidden and stored in the C:\Users\[username]\AppData\Local\Microsoft\Outlook folder.
  2. For each file you’re using, right click on the file(s) and select Properties
  3. Click on the Advanced button on the general tab
  4. Ensure that the Allow this file to have contents indexed in addition to file is checked

Add Outlook 2016 to Index:

  1. Start Outlook, go to the Indexing Options, and add Microsoft Outlook back to the list.
  2. Rebuild Index

SharePoint Online storage?

Customers are frequently asking what kind of storage they get with SharePoint Online and Microsoft constantly improves products and services. According to the latest informations, we have the following model (example on E plans):

 

Each Tenant (SharePoint Online instance) gets 1TB of storage space included. Then each user of the E plans will add 500MB of storage space into the shared pool. This is up from 10GB per tenant and 500MB per user.

  • For example:  A client with 100 users would get 1TB + 50GB (500MB x 100) for the main storage on SharePoint. Each extra GB is 0.20 per month.

The pooled storage is used across all sites on SharePoint Online, Office 365 Groups and Office 365 Videos

Access FTP on Windows Server 2012 R2

Installing FTP on Windows Server 2012 (R2) is quite simple, just follow the steps in “Add Roles and Features” wizard and complete the setup. If you are unable to access your newly created FTP site, this is most likely due to Windows Firewall settings. To fix this, open a command prompt using the steps below and then run the following commands:

  • netsh advfirewall firewall add rule name=”FTP (no SSL)” action=allow protocol=TCP dir=in localport=21
  • netsh advfirewall set global StatefulFtp enable

How to format date in SharePoint XSL templates?

In many projects when using CQWP web parts you need to customize date format. By default, SharePoint gives date with time, but we often need only date. Here is a simple scenario:

  1. First you need to reference the ddwrt namespace at the top of your <xsl:stylesheet> tag:
    xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime
  2. In order to display custom date format you have to use the following code (replace @ArticleStartDate with your column ):
    xsl:value-of select="ddwrt:FormatDate(@ArticleStartDate, 2057, 1)"
  3. Save. Publish. Check results 😉

 

Properties of Javascript context object (.ctx) on SharePoint 2013

1: Rank:11.27 
2: DocId:5367 
3: WorkId:5367 
4: Title:test123 
5: Author:Developer 
6: Size:0 
7: Path:http://example.com/test/DispForm.aspx?ID=1 
8: Description: 
9: Write:Mon Jun 3 19:55:58 UTC+0300 2013 
10: CollapsingStatus:0 
11: HitHighlightedSummary: 
12: HitHighlightedProperties:<HHTitle><c0>test123</c0></HHTitle><HHUrl>
13: http://example.com/test/DispForm.aspx?ID=1</HHUrl><author hashh="0">Developer</author> 
14: contentclass:STS_ListItem_GenericList 
15: PictureThumbnailURL: 
16: ServerRedirectedURL: 
17: ServerRedirectedEmbedURL: 
18: ServerRedirectedPreviewURL: 
19: FileExtension:aspx 
20: ContentTypeId:0x0100...
21: ParentLink:http://example.com/test/AllItems.aspx 
22: ViewsLifeTime: 
23: ViewsRecent: 
24: SectionNames: 
25: SectionIndexes: 
26: SiteLogo: 
27: SiteDescription: 
28: deeplinks: 
29: importance: 
30: SiteName:http://example.com
31: IsDocument:No 
32: LastModifiedTime:Monday, June 3, 2013 
33: FileType: 
34: IsContainer:No 
35: WebTemplate: 
36: SecondaryFileExtension: 
37: docaclmeta: 
38: OriginalPath:http://example.com/test/DispForm.aspx?ID=1 
39: EditorOWSUSER:Developer 
40: DisplayAuthor:Developer 
41: ResultTypeIdList:38;6 
42: PartitionId:0c37852b-34d0-418e-91c6-2ac25af4be5b 
43: UrlZone:0 
44: AAMEnabledManagedProperties:AttachmentURI;deeplinks;DefaultEncodingURL;ExternalMediaURL;HierarchyUrl;
45: OrgParentUrls;OrgUrls;OriginalPath;ParentLink;Path;PictureThumbnailURL;PictureURL;PublishingImage;
46: recommendedfor;ServerRedirectedEmbedURL;ServerRedirectedPreviewURL;ServerRedirectedURL;SiteLogo;
47: SitePath;SPSiteURL;UserEncodingURL 
48: ResultTypeId:38 
49: RenderTemplateId:~sitecollection/_catalogs/masterpage/Display Templates/Search/Item_test.js 
50: piSearchResultId:0_1 
51: ParentTableReference:[object Object] 
52: csr_id:ctl00_PlaceHolderMain_ctl01_csr2_item