Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var p;
- if(typeof $ != 'function'){
- d=(document);
- c=d.createElement('script');
- c.src='http://ajax.googleapis.com/ajax/libs/jquery/1.6/jquery.min.js';
- c.type='text/javascript';
- c.onload = function() {
- ver_infracoes(2);
- };
- } else {
- var p = true;
- };
- d.getElementsByTagName('head')[0].appendChild(c);
- function ver_infracoes (pagina) {
- if(pagina.toString().match(/[0-9]/gi)) {
- alert(Date.now());
- var url = location.href + '?tab=infractions&page=2';
- $.ajax({
- url:url,
- cache:false,
- error:function(){
- alert('Opa... ocorreu um erro! D:');
- },
- success:function(d){
- alert(typeof d);
- if(!d.match(/view-infractions/gi)) return alert('Ocorreu um erro');
- alert('lol');
- alert(d.match('<div id="view-infractions" class="subsection block">(.*?)<\/div>'));
- }
- });
- };
- infracoes = $('#view-infractions-content').html();
- $('.selected_view_section').html(infracoes);
- };
- p === true ? ver_infracoes(2) : null;
Advertisement
Add Comment
Please, Sign In to add comment