Advertisement
yanirx

quick add csgolounge

May 29th, 2015
389
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var mynote = "hi guys"; // edit as you wish
  2.  
  3. $('#itemfilter').val('case key');
  4.  
  5. function filterResults(search,page) {
  6.     $("#itemlist").html('<img src="http://csgolounge.com/img/load.gif" id="loading" style="margin: 0.75em 2%">');
  7.     $.ajax({
  8.         url: 'ajax/tradeCsRightTmp.php',
  9.         type: 'POST',
  10.         data: $(".srch").serialize()+"&search="+search+"&page="+page,
  11.         success: function(data) {
  12.             $("#itemlist").html(data);
  13.             setTimeout(function() {
  14.                 $( "#itemlist .item" ).each(function( index ) {
  15.                 console.log($(this).children()[0].alt);
  16.                   if( $(this).children()[0].alt.indexOf('Prototype') == -1 && $('.right').children().size() < 8)
  17.                   $(this).click()
  18.                 }); }, 100);
  19.             $('#notes').val(mynote);
  20.     }
  21.     });
  22. }
  23. filterResults();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement