Combining autocomplete with suggestionlist and clone
Hello,
I'm having an issue combining two differnt plugins..
- <script type="text/javascript">
- function lookup(inputString) {
- if(inputString.length == 0) {
- // Hide the suggestion box.
- $('#suggestions').hide();
- } else {
- $.post("rpc.php", {queryString: ""+inputString+""}, function(data){
- if(data.length >0) {
- $('#suggestions').show();
- $('#autoSuggestionsList').html(data);
- }
- });
- }
- } // lookup
-
- function fill(thisValue) {
- $('#inputString').val(thisValue);
- setTimeout("$('#suggestions').hide();", 200);
- }
- </script>
- <script type="text/javascript">
- $(function(){
- var removeLink = ' <a class="remove" href="#" onclick="$(this).parent().slideUp(function(){ $(this).remove() }); return false">remove</a>';
- $('a.add').relCopy({ append: removeLink});
- });
- </script>
My problem is when i'm trying to add a new row the autocomplete script inserts only to the first item..