问题标签 [tag-it]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
jquery-ui - JqueryUI tagit - 如何禁止出现新的输入文本字段?
对于 JqueryUI tag-it 小部件,我想完全防止出现新的额外文本输入字段。我正在使用现有标签预先填充,我只想允许人们删除标签但不能输入它们。
我可以将新字段设为只读,但该字段在 IE 中仍然可见,并且在 IE 和 Firefox 中单击小部件区域会导致光标聚焦在该字段上。
我想做的是完全摆脱额外的输入字段。
似乎没有与 .tagit() 方法关联的 tagit 属性。我还能做些什么来防止创建额外的字段吗?
谢谢,
道格
web-applications - tag-it 自动完成标记中的 minLength
有没有办法在tag-it中支持 minLength (仅在输入 minLength 字符后才开始建议)?
另外,我可以处理建议框的css吗?
jquery - Tag-It Jquery - 但无法让水印工作
我正在使用 Tag-it 生成
我遇到的问题是在输入字段上分配水印。在 Visual Studio 中,我看到以下内容:-
在萤火虫我看到这个: -
jquery - Tag-It 自动完成不会触发焦点列表
我已经启动并运行了这个 Tag-it 插件,但我必须纠正一个缺陷。
当鼠标进入输入字段时,它不显示标签列表,即使有showAutocompleteOnFocus:true,
属性。
到目前为止我有这个代码
类别回声呈现如下
任何帮助将非常感激!
提前致谢!
javascript - 应用 jquery 插件后的成功函数(tag-it)
我想知道在应用插件后有什么方法可以进行一些操作例如,
我想要这样的东西:
jquery - 发送 ID 但显示标签
我正在使用 jQuery 插件Tag-It来处理自动建议和标记。我正在使用Ajax
运行良好的调用获取数据。
目前的数据以以下格式返回:
例如:
这一切顺利。
我想要做的是让用户点击返回的标签,并将数据存储在隐藏字段中,如下所示:
我似乎无法弄清楚该怎么做,有没有人有这方面的经验并能够指出我正确的方向?
jquery - 如何使用标记它
我从 这里使用 tagit 库 我创建了正常工作的 tagit,我创建了如下数组:
在使用标签时,所有选项都可以正确选择..我希望标签“4”在选择任何选项之前必须显示为默认选择我该怎么做..
附加信息:
源中有一个选项可用于创建新标签
它也不适合我....
javascript - jQuery Tagit! Not working
I am using the jQuery tagit! library to create a user "Skills" input form. I figured this would be an extremely quick and simple setup like most jQuery libraries, however I am having a tremendous amount of trouble with this one. I tried following the source code on the example below, but I cannot get it to work even with the direct source code.
I am using the script found here: https://github.com/aehlke/tag-it/blob/master/README.markdown
Here is the javascript that is initializing the tag-it library in the header:
And here is the <ul>
element that is supposed to turn into an input field when the tag-it.js library is called:
I am including all these files to get this to work:
All the files are being called correctly and I am not receiving any errors. There is NO input form where the <ul>
tags are unless I create one manually
Does anyone have a clue as to why this isn't working? Do I need to manually add an input field and assign a specific ID or class to it?
EDIT: This has been solved. The code posted is all 100% correct, I had an error in the jquery selector before tag-it initialization.
php - 将 jQuery tag-it 输入保存为 php 数组
我正在使用 jQuery Tag-it!为我的用户创建一个“技能”输入表单。我有 tag-it 的 UI 工作,但我无法让用户输入到 PHP 数组中。我正在尝试序列化这个数组并将其保存到 mysql 数据库中以便稍后显示,但我什至无法将数据放入数组中。
这是javascript初始化标签:
这是HTML:
这是创建应该存储用户输入的输入字段的javascript:
这是获取用户输入的 PHP —— 这是不工作的部分。我无法从表单中检索任何数据:
当我提交表单时,mysqli 查询执行并且在数据库中我看到“N;” 序列化数组应该在哪里。
如何将 jQuery Tag-it 值放入可以序列化并保存到 mysql 数据库的 PHP 数组中?
javascript - 检查外部 JSON 中是否存在单词
我正在使用tag-it,因此用户可以为他们的帖子创建标签。
它目前允许他们输入任何内容,但我有一个 JSON 形式的禁用词列表。我怎么能在 tagit 插件中实现这一点,所以当用户输入的单词匹配一个被禁止的单词时,它会抛出一个错误。
如何检查 swearWords.json 中是否存在 ui.tag?
这是我当前的代码:
swearWords.json
使用 François Wahl 的答案,我设法得到了一个可行的解决方案......
还可以在 var 中获取外部 json