Skip to content
Philipp Zumstein edited this page Mar 15, 2016 · 7 revisions

Bare-bones example

A basic example of it's use is the bare-bones example Search by Example page.

Reference implementation

See the relevant files in the reference implementation for a more complete example:

Full configuration options example

Identical options to Search By Name

	var searchByExample = new CSLEDIT_SearchByExample($('#mainContainer'), {
		// If this isn't present - the "Edit" buttons won't appear
		editStyle_func : function (styleId) {
			// do something with the styleId
		},

		// If this isn't present, the "View Code" buttons won't appear
		viewCode_func :	function (styleId) {
			// do something with the styleId
		},

		// If this isn't present, the "Install" buttons won't appear
		installStyle_func : function (styleId) {
			// do something with the styleId
		}
	});