<script> $('.button').live('click', function(){ $.ajax({ url: 'test.php', success: function(data) { $('#outFileText').html(data); //alert('Load was performed.'); } }); }); </script> <div class="button" id="test"></div> <div id="outFileText"></div>