从XML链接PDF文档

时间:2016-06-03 17:15:32

标签: html css

我遇到过现有的XML文档,其中包含各种电子组件以及它们的一些属性。我试图链接PDF文档,以便在打开此文件时,用户可以单击链接并导航到该PDF文件,而无需在文件管理器中搜索它。任何见解都会有所帮助。

<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/css" href="sub.css" ?>
<row>
        <title>Miniature Circuit Breaker S201-C2</title>
        <standard>ABB</standard>
        <make>ABB Control</make>
        <item_code>VAL0185012</item_code>
        <vendor_code>2CDS 251 001 R0024</vendor_code>
        <language>EN</language>
        <url>http://www.abb.com</url>
        <linked_file url="EL38/WDS03765.pdf"/>
</row>

我目前正在使用CSS来设置文档样式:

row {
    display: block;
    border: 1px solid black;
}

title, standard, make, item_code, vendor_code, language, url {
    display: block;
}

title:before {
    content: "Title: ";
    color: green;
    font-weight: bold;
}
standard:before {
    content: "Standard: ";
    color: green;
    font-weight: bold;
}
make:before {
    content: "Make: ";
    color: green;
    font-weight: bold;
}
item_code:before {
    content: "Item Code: ";
    color: green;
    font-weight: bold;
}
vendor_code:before {
    content: "Vendor Code: ";
    color: green;
    font-weight: bold;
}
language:before {
    content: "Language: ";
    color: green;
    font-weight: bold;
}
url:before {
    content: "URL: ";
    color: green;
    font-weight: bold;
}

0 个答案:

没有答案