Jquery Autocomplete issue

Jquery Autocomplete issue

i wrote a jquery code, which is autocompleting an input field. it getting results from a php file with json format.

here is the code:
  1. <script>
  2.     $(function() {
  3.         function log( message ) {
  4.             $( "<div/>" ).text( message ).prependTo( "#log" );
  5.             $( "#log" ).attr( "scrollTop", 0 );
  6.         }
  7.         $( "#aramakutusu" ).autocomplete({
  8.             source: "search.php",
  9.             minLength: 2,
  10.             select: function( event, ui ) {}
  11.         });
  12.     });
  13.     </script>

this code works correctly. after, these codes (attached to post) including the page and stop working.


i didnt write the second code, i didnt figure out what is doing? how can i solve this problem?

note: i must include the second code. so i cannot remove it.