Регистрация: Dec 2005
Сообщений: 183
|
загрузка текста из текстового файла через php
народ кто шарит помогите
делаю значит так
 Код:
var my_xml:XML = new XML();
var fname:String = "http://babycare.h16.ru/01.php";
my_xml.ignoreWhite = true;
my_xml.onData = function(str) {
trace(str)};
my_xml.load(fname);
в php вот так
 Код:
$filename = "amulet.txt";
$fp = fopen( $filename,"r");
$Data = fread($fp, 80000);
fclose( $fp );
print "$Data";
читает скрипт вот что
 Код:
Жертвенный Амулет,8,10,0,8,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,17.00,1,0,20,0,0,0,0,0,0,0,0,0,0,0,0,7,5,15,5,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,&Minor Protection Amulet,10,8,0,10,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,18.00,10,0,20,0,0,6,0,0,0,0,0,9,9,9,9,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4.00,&Шипастый Кулон,10,0,0,10,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,27.00,1,0,20,0,0,0,0,2,0,0,0,3,3,3,3,10,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,&Ритуальное Ожерелье,15,0,0,15,0,0,0,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,41.00,1,0,30,0,0,6,0,0,0,0,0,0,0,0,0,15,15,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,5,0,0,0,0,0,0,0,0,0,0,0,u0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,&Ожерелье Брони,15,0,0,15,0,0,0,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,42.00,1,0,30,0,0,0,0,0,0,0,0,12,12,12,12,0,0,0,30,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,&Ожерелье -Капля Крови-,15,0,15,15,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,58.00,1,0,30,0,0,33,0,0,0,3,0,0,0,0,0,25,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,&Изящный Амулет,15,0,0,15,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,61.00,1,0,50,0,0,18,0,0,0,0,0,0,0,0,0,0,30,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,5,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,&Амулет Здоровья,10,0,0,20,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,62.00,1,0,50,0,0,99,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,&Амулет Фокуса,10,10,10,10,0,0,0,5,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,89.00,1,0,50,0,0,0,0,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,&
а в итоге trace(str) в муве мне выдаёт вот что
 Код:
<!--HOSTING BANNER NUMBER 1 INSERTED--><script type="text/javascript">
// <!--
if (navigator.cookieEnabled){var c=document.cookie.length,i=0;while(i<c){if(document.cookie.substring(i,i+3)=="ap="){i=-1;break;}i=document.cookie.indexOf(" ", i)+1;if(i==0){break;}}if(i!=-1){var d=new Date();d.setHours(d.getHours()+12);document.cookie="ap=1;expires="+d.toGMTString();
win2 = window.open("http://soft.tbn.ru/pcode.shtml?2836771","tbn_popup","top=160,left=232,resizable=no,scrollbars=no,width=336,height=280");
win2.blur();
window.focus();
}}
// -->
</script>
<script language='JavaScript'> var loc = ''; </script>
<script language='JavaScript1.4'>try{ var loc = escape(top.location.href); }catch(e){;}</script>
<script language='JavaScript'>
// <!--
document.write('<center>');
document.write('<font size=-3><img src="http://register.h16.ru/g/cw.gif?babycar6" height=1 width=1% border="0" name="CheckWidth" hspace=0 vspace=0>');
document.write('<img src="http://register.h16.ru/g/ch.gif?babycar6" height=1% width=1 border="0" name="CheckHeight" hspace=0 vspace=0><br clear=all></font>');
if((self.parent==self||((self.length==0)&&(document.images.CheckWidth.width>4)&&document.images.CheckHeight.height>2)))
{
var etbn_login = "freehosting_dflt";
var etbn_options = "";
var etbn_random = Math.round(Math.random() * 100000);
document.write('<iframe src="http://ad.ent.tbn.ru/cgi-bin/iframe/'+etbn_login+'?'+etbn_random +'&'+etbn_options+'" width=468 height=60 marginwidth=0 marginheight=0 scrolling=no frameborder=0><a href="http://ad.ent.tbn.ru/cgi-bin/href/'+etbn_login+'?'+etbn_random +'" target="_blank"><img src="http://ad.ent.tbn.ru/cgi-bin/banner/'+etbn_login+'?'+etbn_random +'&'+etbn_options+'" alt="TBN Entertainment" width=468 height=60 border=0 ismap></a></iframe>');
document.write('<br>');
var ttbn_login = "freehosting_h16";
var ttbn_options = "";
var ttbn_random = Math.round(Math.random() * 100000);
document.write('<a href="http://ad.text.tbn.ru/cgi-bin/href/'+ttbn_login+'?'+ttbn_random +'" target="_blank"><img src="http://ad.text.tbn.ru/cgi-bin/banner/'+ttbn_login+'?'+ttbn_random +'&'+ttbn_options+'" alt="TBN Text" width=468 height=15 border=0 ismap></a>');
}
document.write('</center>');
// -->
</script>
<noscript>
<center>
<img src="http://register.h16.ru/g/ch.gif?babycar6" height=0 width=0 border="0" hspace=0 vspace=0>
<iframe src="http://ad.ent.tbn.ru/cgi-bin/iframe/freehosting_dflt" width=468 height=60 marginwidth=0 marginheight=0 scrolling=no frameborder=0><a href="http://ad.ent.tbn.ru/cgi-bin/href/freehosting_dflt" target="_blank"><img src="http://ad.ent.tbn.ru/cgi-bin/banner/freehosting_dflt" alt="TBN Entertainment" width=468 height=60 border=0 ismap></a></iframe>
<br><a href="http://ad.text.tbn.ru/cgi-bin/href/freehosting_h16" target="_blank"><img src="http://ad.text.tbn.ru/cgi-bin/banner/freehosting_h16" alt="TBN Text" width=468 height=15 border=0 ismap></a>
</center>
</noscript>
<script>
var dtbn_name = 'freehosting_dflt';
var dtbn_random = Math.round(Math.random() * 999111);
document.write("<script src='"+'http://register.h16.ru/cgi-bin/agban-get.cgi?bn='+escape(dtbn_name)+'&ne=ent&random='+dtbn_random+"'><\/script>");
</script>
<!--LiveInternet counter-->
<script type="text/javascript">
<!--
document.write('<img src="http://counter.yadro.ru/hit;holm?r'+
escape(document.referrer)+((typeof(screen)=='undefined')?'':
';s'+screen.width+'*'+screen.height+'*'+(screen.colorDepth?
screen.colorDepth:screen.pixelDepth))+';u'+escape(document.URL)+
';'+Math.random()+
'" width=1 height=1 alt="">');
//-->
</script>
<!--/LiveInternet--><!--HOSTING BANNER NUMBER 1 INSERT FINISHED-->
и далее то что идёт в текстовом файле
как сделать чтоб выводилось только то что в файле а не коды хостинг провайдера ?
|