Rajasekar S

Rajasekar S

  • NA
  • 95
  • 6.3k

Reading Text file using JQuery

Apr 1 2016 6:59 AM
I am using jquery for reading content from text file using AJAX. I tried it with sample application, it is working fine. But when i used in project,  it is not showing  the text. It scrolls entire page while loading.
 
 Below is the code which i have used.
 
<script type="text/javascript">
$(window).load(function () {
jQuery.get('TextFile1.txt', function (data) {
//process text file line by line
$('#marDemo').html(data);
});
});
 
</script>
 
 
<div id="marqDiv">
<marquee id="marDemo" runat="server" style="font-size: 25px; font-style: italic;
font-weight: 100px; color: Red" onmouseover="this.stop();" onmouseout="this.start();">
</marquee>
</div>
 
Could you please help me for the above issue. 
 

Answers (4)