APIs
优质
小牛编辑
132浏览
2023-12-01
load
You can invoke this method to load data
when data
is empty.
It wouldn't reload data if they are already exists.
Parameter
- flag - [String] - the
at
char - data - [Array] - data to storage
Example
$inputor.atwho('load', '@', [{name: 'one'}, {nick: 'two'}]);
run
Run it!
Parameter
empty
Example
$.getJSON(url, params, function(data) { $inputor.atwho('load',':', data).atwho('run'); });
destroy
destroy it.
Parameter
empty
Example
$inputor.atwho('destroy');
setIframe
To set iframe element which the text field belongs to.
Parameter
- iframe - [DOM] - iframe element
Example
$textField.atwho('setIframe', iframe); $textField.atwho({at: '@', data: ['Peter', 'Anne']});
isSelecting
Check if the dropdown menu is showing, which means there is a suggestions for you. Examine the example in examples/tinyMCE.html
to see how to use it.
Parameter
empty
Return
true | false
Example
$inputor.atwho('isSelecting');
hide
hide the view
Parameter
empty
Example
$inputor.atwho('hide');