-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocChk.php
More file actions
42 lines (39 loc) · 1002 Bytes
/
docChk.php
File metadata and controls
42 lines (39 loc) · 1002 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
function chkDoc($filename,$confname){
include 'func.php';
//include 'ParaStyle.php';
$dcontent = getContent('word/document.xml', $filename);
$ns = getNS($dcontent);
var_dump($ns);
$dxml = new DOMDocument();
$dxml->loadXML($dcontent);
$ele = $dxml->firstChild->firstChild->firstChild;
//echo $ele->localName,"\n";
while($ele){
//echo $ele->nodeValue,"\n";
/*
$nd = new DOMDocument();
$nd->formatOutput = TRUE;
$nd ->loadXML("<root></root>");
$node = $nd->importNode($ele,TRUE);
$nd->firstChild->appendChild($node);
$sx = simplexml_import_dom($nd->saveXML());
var_dump($sx);
//echo $nd->saveXML(),"\n";
//echo $sx;
*/
include_once 'ParaStyle.php';
$p = new ParaStyle($ele,$filename);
echo"狗日的..\n";
$ele = $ele->nextSibling;
}
}
function getStyle($filename){
include_once 'func.php';
$scontent = getContent('word/styles.xml', $filename);
$ns = getNS($scontent);
$sxml = new DOMDocument();
$sxml->loadXML($scontent);
$deStyle = null;
}
?>