• Jetzt anmelden. Es dauert nur 2 Minuten und ist kostenlos!

Datei wird nicht ausgegeben!

Status
Für weitere Antworten geschlossen.

Maxi Ebel

Neues Mitglied
Hallo
schaut bitte mal http://2freeride.de

HTML:
<div style="position: absolute; overflow: auto; color: rgb(0, 0, 0); left: 195px; width: 705px; top: 125px; height: 700px;">
     <div style="background-image:url(http://2freeride.2f.funpic.de/Bilder/Events01.png); position: absolute; overflow: auto; color: rgb(0, 0, 0); left: 0px; height: 350px; width: 350px; top: 10px;">
         <div style="position: absolute; overflow: no; color: rgb(0, 0, 0); height: 300px; width: 320px; top: 35px; left: 15px;">
            <FONT FACE="Arial"><FONT SIZE=2>Keine Events eingetragen!
               <?php
               $events = @implode("events.txt",file($quell));
               ?>
               <textarea rows="16" cols="35">
               <?php echo htmlspecialchars($events); ?>
               </textarea>
            </FONT></FONT>
         </div>
     </div>
     <div style="background-image:url(http://2freeride.2f.funpic.de/Bilder/News01.png); position: absolute; overflow: auto; color: rgb(0, 0, 0); left: 350px; height: 350px; width: 350px; top: 10px;">
         <div style="position: absolute; overflow: no; color: rgb(0, 0, 0); height: 125px; width: 320px; top: 35px; left: 15px;">
            <FONT FACE="Arial"><FONT SIZE=2>Keine News Vorhanden!
               <?php
               $news = @implode("news.txt",file($quell));
               ?>
               <textarea rows="6" cols="35">
               <?php echo htmlspecialchars($news); ?>
               </textarea>
            </FONT></FONT>
         </div>
         <div style="position: absolute; overflow: no; color: rgb(0, 0, 0); height: 125px; width: 320px; top: 210px; left: 15px;">
            <FONT FACE="Arial"><FONT SIZE=2>Keine News Vorhanden!<br>
               <?php
               $news = @implode("news.txt",file($quell));
               ?>
               <textarea rows="6" cols="35">
               <?php echo htmlspecialchars($news); ?>
               </textarea>
            </FONT></FONT>
         </div>
     </div>
</div>
dieße PHP ausgabe felder lesen den text nicht!
HTML:
               <?php
               $news = @implode("news.txt",file($quell));
               ?>
               <textarea rows="6" cols="35">
               <?php echo htmlspecialchars($news); ?>
               </textarea>
 
Wenn du im Manual nachschaust wirst du feststellen das der erste Parameter vom implode das trennzeichen festlegt mit dem die teile des arrays zusammengefügt werden. Ausserdem setzt du Quell nirgendwo. Das heist file kann gar nichts laden da du auch keine gültige Datei angibst.
Deine konstruktion müsste also so aussehen:
PHP:
<?php
  $news = @implode('',file('news.txt'));
?>
<textarea rows="6" cols="35">
  <?php echo htmlspecialchars($news); ?>
</textarea>

Die variante ist allerdings ziemlich umständlich. Du könntest dir eine menge mühe sparen wenn du file_get_contents sinnvoll einsetzt:
PHP:
<textarea rows="6" cols="35">
  <?php echo htmlspecialchars(file_get_contents('news.txt')); ?>
</textarea>
 
Status
Für weitere Antworten geschlossen.
Zurück
Oben