10 |
$xmlcp_tagcbfunctions = array(); |
$xmlcp_tagcbfunctions = array(); |
11 |
$xmlcp_cdata = ''; |
$xmlcp_cdata = ''; |
12 |
|
|
13 |
function xmlcp_registertagcallbacks($tagname, $fn_startelement, $fn_endelement) { |
function xmlcp_registertagcallbacks($tagname, $fn_startelement, $fn_endelement = '') { |
14 |
|
|
15 |
global $xmlcp_tagcbfunctions; |
global $xmlcp_tagcbfunctions; |
16 |
|
|
17 |
if($tagname && $fn_startelement && $fn_endelement) { |
if($tagname && $fn_startelement) { |
18 |
|
|
19 |
$xmlcp_tagcbfunctions[$tagname] = array($fn_startelement, $fn_endelement); |
$xmlcp_tagcbfunctions[$tagname] = array($fn_startelement, $fn_endelement); |
20 |
|
|
55 |
|
|
56 |
global $xmlcp_tagcbfunctions; |
global $xmlcp_tagcbfunctions; |
57 |
|
|
58 |
if(isset($xmlcp_tagcbfunctions[$tagname])) echo $xmlcp_tagcbfunctions[$tagname][1]($h_parser, $tagname); |
if(isset($xmlcp_tagcbfunctions[$tagname]) && $xmlcp_tagcbfunctions[$tagname][1]) echo $xmlcp_tagcbfunctions[$tagname][1]($h_parser, $tagname); |
59 |
|
|
60 |
} |
} |
61 |
|
|