Need to extract info from the source of HTML and put it in an mySQL update string

خرید بک لینک

I need to get callsign, channel number and xmltvid from this HTML source. Here's a link to a larger sample of the file: http://pastebin.com/VuzBRhq6

In this case each TD of the table contains a span with the callsign($sign) <span class="callsign">KETSDT</span> in this case "KETSDT".

It has a span with <span class="chan">2-1</span> where 2-1 is the channel($chan)

The TD also has a title element that looks like this title="KETSDT (KETS-DT) (id: 44002)", where the number after "id:" is the xmltvid($id).

It should output the full update query:

UPDATE channel SET xmltvid="$id" WHERE callsign="$sign" AND channum="$chan";

example:

UPDATE channel SET xmltvid="44002" WHERE callsign="KETSDT" AND channum="2-1";

Recent Questions...

ما را در سایت Recent Questions دنبال می‌کنید

برچسب: نویسنده: استخدام کار بازدید: 193 تاريخ: جمعه 27 فروردين 1395 ساعت: 11:12

صفحه بندی