blob: afa6244392545b32c07e8a138c4ca1de1e0a3b43 [file] [log] [blame]
<!--
! Licensed to the Apache Software Foundation (ASF) under one or more
! contributor license agreements. See the NOTICE file distributed with
! this work for additional information regarding copyright ownership.
! The ASF licenses this file to You under the Apache License, Version 2.0
! (the "License"); you may not use this file except in compliance with
! the License. You may obtain a copy of the License at
!
! http://www.apache.org/licenses/LICENSE-2.0
!
! Unless required by applicable law or agreed to in writing, software
! distributed under the License is distributed on an "AS IS" BASIS,
! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
! See the License for the specific language governing permissions and
! limitations under the License.
!-->
<html>
<head>
<title>PDFBox Examples</title>
<script language="JavaScript">
function forwardToPDF()
{
var xmlURL = "" + window.location;
if( xmlURL.lastIndexOf( "index.html" ) > 0 )
{
xmlURL = xmlURL.substring( 0, xmlURL.lastIndexOf( "index.html" ) );
}
if( xmlURL.charAt( xmlURL.length-1 ) != '/' )
{
xmlURL += "/";
}
xmlURL += "highlight.jsp";
var finalURL = window.document.highlightForm.pdfURL.value +
"#xml=" + xmlURL +
"?pdf=" + window.document.highlightForm.pdfURL.value +
"&words=" + window.document.highlightForm.highlightWords.value;
window.location = finalURL;
}
</script>
</head>
<body>
<h1>PDFBox Highlighter example</h1>
This is a simple example to show off the PDFBox highlighting capabilities. Enter a URL PDF that you would like to view and
some words that you would like to search on. <br /> <br />
See the <a href="http://partners.adobe.com/public/developer/en/pdf/HighlightFileFormat.pdf">PDF Highlighter spec</a> for more detailed information.
<form name="highlightForm" method="GET" action="">
PDF: <input name="pdfURL" type="text" size="100" value="http://www.csh.rit.edu/~ben/projects/pdfbox/userguide/bookmarks.pdf" /><br />
Highligh words:<input type="text" name="highlightWords" length="100" value="hierarchical" /><br /><br />
<input type="button" value="View PDF With Highlighting" onClick="forwardToPDF()"/>
</form>
</body>
</html>