• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[SOLVED] jquery $.get - IE7 gets wrong value

#1
[eluser]SPeed_FANat1c[/eluser]
Hi,

it is strange problem. Here is simple jquery code:

Code:
$(document).ready(function(){
        var base_url = '<? echo base_url() ?>';
        
        
        $.get(base_url+"admin_/reklama/head_ad_id/", function(h_id){
            
            $('#up_' + h_id).hide();
        })
        
        $.get(base_url+"admin_/reklama/underpart_ad_id/", function(u_id){
            
            $('#down_' + u_id).hide();
        })
        
    });

and there is the function which is called by jquery:

Code:
function head_ad_id()
    {
        $query = $this->db->select('rek_id')->where('queue',1)->get('reklama');
        $row = $query->row();
        $id = $row->rek_id;
        echo $id;
    }

How can IE get diferent id from this function? Firefox, opera, chrome gets the correct value. Sometimes IE gets correct value, sometimes not.

Edit:
After I restart IE and go to the same page, it gets correct value. So maybe it somehow remembers that value from earlier, because I do this - load the page on IE and firefox. Then I click a button in firefox so it make changes in database. Then I refresh the page in IE to see if something changed - some content I can see is changed so the whole page isn't in them memory, but that value from $.get insn't and it hides the wrong button.


Messages In This Thread
[SOLVED] jquery $.get - IE7 gets wrong value - by El Forum - 06-16-2010, 03:59 AM
[SOLVED] jquery $.get - IE7 gets wrong value - by El Forum - 06-16-2010, 07:17 AM
[SOLVED] jquery $.get - IE7 gets wrong value - by El Forum - 06-22-2010, 03:19 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.