Skip to content
Dimitris Krestos edited this page May 15, 2017 · 20 revisions

Table of Contents


Default Options

$('#search').hideseek({
      list:           '.hideseek-data',
      nodata:         '',
      attribute:      'text',
      matches:        false,
      highlight:      false,
      ignore:         '',
      navigation:     false,
      ignore_accents: false,
      hidden_mode:    false,
      min_chars:      1
});

"list" option

  • The list that holds the data
  • options: element class
$('#search').hideseek({
	list: '.hideseek-data'
});

"nodata" option

  • The text that appears when no results are available
  • options: plain text
$('#search').hideseek({
	nodata: ''
});

"attribute" option

  • Where to search
  • options: text, alt, title
$('#search').hideseek({
	attribute: 'text'
});

"matches" option

  • Matches user's query and data against regular expressions
  • options: hash object
$('#search').hideseek({
	matches: { '^ale$': 'male' }
});

"highlight" option

  • Highlight the matched portion of text (wraps with <mark class="highlight"> tag)
  • options: false, true
$('#search').hideseek({
	highlight: false
});

"ignore" option

  • Ignore elements with specific class or id (<li class="ignore-me">element</li>)
  • options: class_name
$('#search').hideseek({
	ignore: '.ignore-me'
});

"navigation" option

  • Enables the selection by using the key arrows (up - down)
  • and selects the item with the return key, if the item is a link
  • the it redirects else fills the input with the item's text
  • options: false, true
$('#search').hideseek({
	navigation: false
});

"ignore_accents" option

  • Ignore accented characters (<li>Michèle</li>)
  • options: false, true
$('#search').hideseek({
	ignore_accents: true
});

"hidden_mode" option

  • Hides the list and shows only the query results
  • options: false, true
$('#search').hideseek({
	hidden_mode: true
});

"min_chars" option

  • Sets the minimum required characters to search
  • options: integer
  • default: 1
$('#search').hideseek({
	min_chars: 3
});

Clone this wiki locally