[eluser]Mike DeFelice[/eluser]
The field that you are adding the tags to, does it have the id "tags" ? Besides that, everything looks correct.
I tested it and it seemed to work fine
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html >
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
[removed][removed]
[removed]
$(document).ready(function() {
$(function() {
$(".tag").click(function()
{
var $clickText = $(this).text()
$("#tags").val($("#tags").val() + $clickText);
return false;
});
});
});
[removed]
</head>
<body>
<ul>
<li class="tag">Test</li>
<li class="tag">Test2</li>
</ul>
<input type="text" id="tags" />
</body></html>