Skip to content

Instantly share code, notes, and snippets.

@janvanderhaegen
janvanderhaegen / switchtory.lightswitchsearchbox
Created March 22, 2013 15:27
JavaScript snippet to turn a "custom control" into a JQuery search box (and move it to the command bar)
(function ($) {
$.widget("switchtory.lightswitchsearchbox", {
_create: function () {
},
_init: function () {
@janvanderhaegen
janvanderhaegen / switchtory.lightswitchslider.js
Created March 6, 2013 13:58
JavaScript snippet to turn a LightSwitch List into a Slider.
/// <reference path="jquery-1.7.1.js" />
/// <reference path="jquery.mobile-1.1.1.js" />
/// <reference path="msls-1.0.0.js" />
(function ($) {
$.widget("switchtory.lightswitchSlider", {
options: {
timerInterval: 4000
},
@spdustin
spdustin / spe.jquery.SPautocomplete.js
Created October 31, 2012 21:17
WIP - jQuery Autocomplete
var acField = $('input[title="Related Task"]');
var listSvc = _spPageContextInfo.webServerRelativeUrl + "/_vti_bin/listdata.svc/";
var listSvcList = "Tasks";
var listSvcFieldQuery = "Title";
var listSvcFieldReturn = "Title";
acField.autocomplete({
source: function(req, res) {
var reqUrl =
listSvc