XML ve HTML = HTML kodu kullanarak yardıma ihtiyacım var

1 Cevap php

I'm converting my static HTML site to a dynamic PHP/XML-driven one. This is my current code:

  <div class="divider"></div>
  <div class="main" style="width: 552px;">
   <div class="time">00:00</div>
   <div class="show"><h3><b>Radio Show</b></h3>
    <p>Description</p></div>
   <div class="footer"></div>
  </div>

ve benim XML dosyası:

<?xml version="1.0"?>
<show>
 <showdesc>
 <divider1></divider1>
 <divmain></divmain>
 <airtime></airtime>
 <presenter></presenter>
    <showinfo></showinfo>
    <divfooter></divfooter>
    </showdesc>

which is the above HTML, that I'm trying to get into the XML file. I don't know how to get it to get the info in, I can display a simple XML page, as suggested here: http://www.kirupa.com/web/xml_php_parse_intermediate.htm but I am trying to in PHP get this to display what's in the XML pages or display this output: "Sorry. No schedule page is available" if the XML is blank, as above.

Bana yardım edebilir herkes bu düzeltmek? Ben denedim ve denedim ama bana manidar dimi ...

1 Cevap

Sen xml belgedeki tüm biçimlendirme şeyler gerekmez. Eğer olarak biçimlendirmek olabilir title, time ve description ki: html "gerçek" bilgi sadece üç adet gönderdiniz pasajı vardır

<show>
  <title>Radio Show</title>
  <time>00:00:00</time>
  <description>...</description>
</show>

Örnek xml bir unsur da var pasajı presenter. Nerede bu bilgileri (varolan) html veri olurdu?