Mercurial > epgrec.yaz
annotate getepg.old.php @ 109:3450df471c8c
merged with upstream
author | Yoshiki Yazawa <yaz@honeyplanet.jp> |
---|---|
date | Tue, 09 Mar 2010 05:56:04 +0900 |
parents | d9b9d1d903a1 |
children | 3bed74eca373 |
rev | line source |
---|---|
84
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
1 #!/usr/bin/php |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
2 <?php |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
3 include_once('config.php'); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
4 include_once( INSTALL_PATH . '/DBRecord.class.php' ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
5 include_once( INSTALL_PATH . '/Reservation.class.php' ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
6 include_once( INSTALL_PATH . '/Keyword.class.php' ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
7 include_once( INSTALL_PATH . '/Settings.class.php' ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
8 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
9 $settings = Settings::factory(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
10 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
11 if( file_exists( $settings->temp_data ) ) @unlink( $settings->temp_data ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
12 if( file_exists( $settings->temp_xml ) ) @unlink( $settings->temp_xml ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
13 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
14 // BS |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
15 if( $settings->bs_tuners != 0 ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
16 // 牙脂茲с |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
17 $num = DBRecord::countRecords( RESERVE_TBL, "WHERE complete = '0' AND (type = 'BS' OR type = 'CS') AND endtime > now() AND starttime < addtime( now(), '00:03:05')" ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
18 if( $num == 0 ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
19 $cmdline = "CHANNEL=211 DURATION=180 TYPE=BS TUNER=0 MODE=0 OUTPUT=".$settings->temp_data." ".DO_RECORD . " >/dev/null 2>&1"; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
20 exec( $cmdline ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
21 $cmdline = $settings->epgdump." /BS ".$settings->temp_data." ".$settings->temp_xml; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
22 exec( $cmdline ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
23 storeProgram( "BS", $settings->temp_xml ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
24 if( file_exists( $settings->temp_data ) ) @unlink( $settings->temp_data ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
25 if( file_exists( $settings->temp_xml ) ) @unlink( $settings->temp_xml ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
26 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
27 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
28 // CS |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
29 if ($settings->cs_rec_flg != 0) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
30 $num = DBRecord::countRecords( RESERVE_TBL, "WHERE complete = '0' AND (type = 'BS' OR type = 'CS') AND endtime > now() AND starttime < addtime( now(), '00:03:05')" ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
31 if( $num == 0 ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
32 $cmdline = "CHANNEL=CS8 DURATION=120 TYPE=CS TUNER=0 MODE=0 OUTPUT=".$settings->temp_data." ".DO_RECORD . " >/dev/null 2>&1"; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
33 exec( $cmdline ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
34 $cmdline = $settings->epgdump." /CS ".$settings->temp_data." ".$settings->temp_xml; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
35 exec( $cmdline ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
36 storeProgram( "CS", $settings->temp_xml ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
37 if( file_exists( $settings->temp_data ) ) @unlink( $settings->temp_data ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
38 if( file_exists( $settings->temp_xml ) ) @unlink( $settings->temp_xml ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
39 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
40 $num = DBRecord::countRecords( RESERVE_TBL, "WHERE complete = '0' AND (type = 'BS' OR type = 'CS') AND endtime > now() AND starttime < addtime( now(), '00:03:05')" ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
41 if( $num == 0 ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
42 $cmdline = "CHANNEL=CS24 DURATION=120 TYPE=CS TUNER=0 MODE=0 OUTPUT=".$settings->temp_data." ".DO_RECORD . " >/dev/null 2>&1"; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
43 exec( $cmdline ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
44 $cmdline = $settings->epgdump." /CS ".$settings->temp_data." ".$settings->temp_xml; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
45 exec( $cmdline ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
46 storeProgram( "CS", $settings->temp_xml ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
47 if( file_exists( $settings->temp_data ) ) @unlink( $settings->temp_data ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
48 if( file_exists( $settings->temp_xml ) ) @unlink( $settings->temp_xml ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
49 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
50 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
51 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
52 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
53 // 遺羈≪ |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
54 if( $settings->gr_tuners != 0 ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
55 foreach( $GR_CHANNEL_MAP as $key=>$value ){ |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
56 // 牙脂茲с |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
57 $num = DBRecord::countRecords( RESERVE_TBL, "WHERE complete = '0' AND type = 'GR' AND endtime > now() AND starttime < addtime( now(), '00:01:10')" ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
58 if( $num == 0 ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
59 $cmdline = "CHANNEL=".$value." DURATION=60 TYPE=GR TUNER=0 MODE=0 OUTPUT=".$settings->temp_data." ".DO_RECORD . " >/dev/null 2>&1"; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
60 exec( $cmdline ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
61 $cmdline = $settings->epgdump." ".$key." ".$settings->temp_data." ".$settings->temp_xml; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
62 exec( $cmdline ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
63 storeProgram( "GR", $settings->temp_xml ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
64 if( file_exists( $settings->temp_data ) ) @unlink( $settings->temp_data ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
65 if( file_exists( $settings->temp_xml ) ) @unlink( $settings->temp_xml ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
66 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
67 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
68 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
69 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
70 // 筝荀違 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
71 // 8ヤ札筝違羔 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
72 $arr = array(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
73 $arr = DBRecord::createRecords( PROGRAM_TBL, "WHERE endtime < subdate( now(), 8 )" ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
74 foreach( $arr as $val ) $val->delete(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
75 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
76 // 8ヤ札筝若帥井 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
77 $arr = array(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
78 $arr = DBRecord::createRecords( PROGRAM_TBL, "WHERE starttime > adddate( now(), 8 )" ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
79 foreach( $arr as $val ) $val->delete(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
80 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
81 // 若若牙私膣 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
82 $arr = array(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
83 $arr = Keyword::createKeywords(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
84 foreach( $arr as $val ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
85 try { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
86 $val->reservation(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
87 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
88 catch( Exception $e ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
89 // ∴ |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
90 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
91 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
92 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
93 exit(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
94 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
95 function storeProgram( $type, $xmlfile ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
96 global $BS_CHANNEL_MAP, $GR_CHANNEL_MAP, $CS_CHANNEL_MAP; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
97 // c潟<ゃ羣 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
98 $map = array(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
99 if( $type == "BS" ) $map = $BS_CHANNEL_MAP; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
100 else if( $type == "GR") $map = $GR_CHANNEL_MAP; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
101 else if( $type == "CS") $map = $CS_CHANNEL_MAP; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
102 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
103 // XML parse |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
104 $xml = @simplexml_load_file( $xmlfile ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
105 if( $xml === false ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
106 return; // XML茯水篏 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
107 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
108 // channel遵 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
109 foreach( $xml->channel as $ch ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
110 $disc = $ch['id']; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
111 try { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
112 // c潟若帥「 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
113 $num = DBRecord::countRecords( CHANNEL_TBL , "WHERE channel_disc = '" . $disc ."'" ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
114 if( $num == 0 ) { |
93
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
115 // channel disc蕋違 |
95
d9b9d1d903a1
fix: さらに修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
94
diff
changeset
|
116 if( array_key_exists( "$disc", $map ) ) { |
93
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
117 // c潟若帥域鋎 |
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
118 $rec = new DBRecord( CHANNEL_TBL ); |
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
119 $rec->type = $type; |
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
120 $rec->channel = $map["$disc"]; |
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
121 $rec->channel_disc = $disc; |
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
122 $rec->name = $ch->{'display-name'}; |
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
123 } |
84
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
124 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
125 else { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
126 // 絖翫c潟贋違 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
127 $rec = new DBRecord(CHANNEL_TBL, "channel_disc", $disc ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
128 $rec->name = $ch->{'display-name'}; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
129 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
130 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
131 catch( Exception $e ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
132 // ∴ |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
133 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
134 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
135 // channel 腟篋 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
136 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
137 // programme 緇 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
138 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
139 foreach( $xml->programme as $program ) { |
93
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
140 $channel_disc = $program['channel']; |
94
12ed8ad837fc
fix: さらに修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
93
diff
changeset
|
141 if( ! array_key_exists( "$channel_disc", $map ) ) continue; |
93
80cc05b420af
fix: $*_CHANNEL_MAPに存在しないチャンネルの番組を取得する際のエラーを修正
epgrec@park.mda.or.jp <yoneda@recorder.localnet.mda.or.jp>
parents:
84
diff
changeset
|
142 |
84
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
143 $channel = $map["$channel_disc"]; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
144 $starttime = str_replace(" +0900", '', $program['start'] ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
145 $endtime = str_replace( " +0900", '', $program['stop'] ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
146 $title = $program->title; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
147 $desc = $program->desc; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
148 $cat_ja = ""; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
149 $cat_en = ""; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
150 foreach( $program->category as $cat ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
151 if( $cat['lang'] == "ja_JP" ) $cat_ja = $cat; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
152 if( $cat['lang'] == "en" ) $cat_en = $cat; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
153 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
154 $program_disc = md5( $channel_disc . $starttime . $endtime ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
155 // printf( "%s %s %s %s %s %s %s \n", $program_disc, $channel, $starttime, $endtime, $title, $desc, $cat_ja ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
156 try { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
157 // 眼 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
158 $category_disc = md5( $cat_ja . $cat_en ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
159 $num = DBRecord::countRecords(CATEGORY_TBL, "WHERE category_disc = '".$category_disc."'" ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
160 $cat_rec = null; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
161 if( $num == 0 ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
162 // 域眼菴遵 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
163 $cat_rec = new DBRecord( CATEGORY_TBL ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
164 $cat_rec->name_jp = $cat_ja; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
165 $cat_rec->name_en = $cat_en; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
166 $cat_rec->category_disc = $category_disc; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
167 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
168 else |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
169 $cat_rec = new DBRecord(CATEGORY_TBL, "category_disc" , $category_disc ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
170 // |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
171 $channel_rec = new DBRecord(CHANNEL_TBL, "channel_disc", $channel_disc ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
172 $num = DBRecord::countRecords(PROGRAM_TBL, "WHERE program_disc = '".$program_disc."'" ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
173 if( $num == 0 ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
174 // 域腟 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
175 // 茲с 絽腟 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
176 $options = "WHERE channel_disc = '".$channel_disc."' ". |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
177 "AND starttime < '". $endtime ."' AND endtime > '".$starttime."'"; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
178 $battings = DBRecord::countRecords(PROGRAM_TBL, $options ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
179 if( $battings > 0 ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
180 // 茲榊鐚丈紊 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
181 $records = DBRecord::createRecords(PROGRAM_TBL, $options ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
182 foreach( $records as $rec ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
183 // 牙私膣腟丈紊眼cゃ |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
184 try { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
185 $reserve = new DBRecord(RESERVE_TBL, "program_id", $rec->id ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
186 if( $reserve->autorec ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
187 Reservation::cancel( $reserve->id ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
188 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
189 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
190 catch( Exception $e ) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
191 //∴ |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
192 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
193 // 腟 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
194 $rec->delete(); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
195 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
196 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
197 // // |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
198 $rec = new DBRecord( PROGRAM_TBL ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
199 $rec->channel_disc = $channel_disc; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
200 $rec->channel_id = $channel_rec->id; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
201 $rec->type = $type; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
202 $rec->channel = $channel_rec->channel; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
203 $rec->title = $title; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
204 $rec->description = $desc; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
205 $rec->category_id = $cat_rec->id; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
206 $rec->starttime = $starttime; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
207 $rec->endtime = $endtime; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
208 $rec->program_disc = $program_disc; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
209 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
210 else { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
211 // 腟絎号贋 |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
212 $rec = new DBRecord( PROGRAM_TBL, "program_disc", $program_disc ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
213 $rec->title = $title; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
214 $rec->description = $desc; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
215 $rec->category_id = $cat_rec->id; |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
216 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
217 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
218 catch(Exception $e) { |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
219 exit( $e->getMessage() ); |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
220 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
221 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
222 } |
3ec5ca5e56ca
add: EPG取得並列化版を暫定的に標準に
yoneda <yoneda@recorder.localnet.mda.or.jp>
parents:
diff
changeset
|
223 ?> |