ibm-information-center/dist/eclipse/plugins/i5OS.ic.clfinder_5.4.0.1/table/results.jsp

177 lines
5.9 KiB
Plaintext

<%@ page language="java" contentType="text/html; charset=utf-8" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta name="Copyright" content="Copyright (c) 2006 by IBM Corporation" />
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<title>CL command finder</title>
<link rel="stylesheet" type="text/css" href="finder.css" />
<link rel="stylesheet" type="text/css" href="ic.css" />
<script language="javascript" type="text/javascript">
//START NON-TRANSLATABLE
function openFinder() {
window.location = "/help/topic/clfinder/finder.htm";
}
//END NON-TRANSLATABLE
</script>
</head>
<body>
<h2>CL command finder</h2>
<script language="javascript" type="text/javascript">
var alert_string = "Enter a value in the search field.";
//START NON-TRANSLATABLE
//alert(window.location);
function openLink(url)
{
var url_low = url.toLowerCase();
var topic_string = "/help/topic/cl/";
if (url_low.indexOf("http://") == 0 ||
url_low.indexOf("https://") == 0 ||
url_low.indexOf("file://") == 0 ||
url_low.indexOf("ftp://") == 0 )
{
window.open(url, 'pdf_window');
}
else if ( url_low.lastIndexOf('.pdf') == url.length-4)
{
window.open(topic_string+url, 'pdf_window');
}
else
{
location = topic_string+url;
}
}
<%
String temp_string = (String)request.getParameter("sort_type");
if (temp_string != null)
out.println("var original_sort_type = \""+temp_string+"\";");
else
out.println("var original_sort_type = \"ascending\";");
temp_string = (String)request.getParameter("sort_column");
if (temp_string != null)
out.println("var original_sort_column = \""+temp_string+"\";");
else
out.println("var original_sort_column = \"apidescriptivename\";");
temp_string = (String)request.getAttribute("query");
if (temp_string != null)
out.println("var original_query = \""+temp_string+"\";");
else
out.println("var original_query = \"\";");
temp_string = (String)request.getParameter("field");
if (temp_string != null)
out.println("var original_field = \""+temp_string+"\";");
else
out.println("var original_field = \"_all\";");
%>
function submitSort(sort_column) {
if (sort_column == original_sort_column)
{
if (original_sort_type == "ascending")
document.form_1.sort_type.value = "descending";
else
document.form_1.sort_type.value = "ascending";
}
else
document.form_1.sort_type.value = "ascending";
document.form_1.sort_column.value = sort_column;
document.form_1.query.value = original_query;
document.form_1.field.value = original_field;
document.form_1.submit();
}
//END NON-TRANSLATABLE
////////// -->
</script>
<form name="form_1" method="GET" action="InteractiveTableManager">
<%
//START NON-TRANSLATABLE
temp_string = (String)request.getParameter("query");
String outString = "";
if (temp_string != null) {
outString = "<input type=hidden name=\"query\" value=\""+temp_string+"\">";
} else {
outString = "<input type=hidden name=\"query\">";
}
out.print(outString);
String lang = (String)request.getParameter("lang");
outString = "<input type=hidden name=\"lang\" value=\""+lang+"\">";
out.print(outString);
temp_string = (String)request.getParameter("query_filter");
if (temp_string != null) {
outString = "<input type=hidden name=\"query_filter\" value=\""+temp_string+"\">";
} else {
outString = "<input type=hidden name=\"query_filter\" value=\"\">";
}
out.print(outString);
//END NON-TRANSLATABLE
%>
<input type=hidden name="table_name" value="table" />
<input type=hidden name="function" value="search" />
<!-- <input type=hidden name="query_filter" value="" /> -->
<input type=hidden name="sort_type" value="ascending" />
<input type=hidden name="sort_column" value="description" />
<input type=hidden name="field" value="_all" />
<%
//START NON-TRANSLATABLE
temp_string = (String)request.getParameter("search_type");
if (temp_string != null && temp_string.equals("or")) {
outString = "<input type=hidden name=\"search_type\" value=\"or\">";
} else {
outString = "<input type=hidden name=\"search_type\" value=\"and\">";
} out.print(outString);
//END NON-TRANSLATABLE
%>
</form>
<%
//START NON-TRANSLATABLE
String temp_string2 = (String)request.getParameter("query");
//END NON-TRANSLATABLE
String output1 = "<table border='0' width='95%'><tr><td><strong>Results for '"+temp_string2+"'</strong></td><td align='right'><a href=\"javascript:openFinder()\">Back to CL command finder</a></td></tr></table>";
String output2 = "<table border='0' width='95%'><tr><td><strong>Results</strong></td><td align='right'><a href=\"javascript:openFinder()\">Back to CL command finder</a></td></tr></table>";
//START NON-TRANSLATABLE
if (temp_string2 != null)
out.print(output1);
else
out.print(output2);
//END NON-TRANSLATABLE
%>
<form name="form_2">
<table width="95%" cellpadding="0" cellspacing="5" class="output">
<!-- table definition file must match your results.jsp as far as number and order of columns -->
<tr>
<th align="left" valign="bottom">Descriptive Name<br /><input type="button" value="Sort" onClick="submitSort('description');" /></th>
<th align="left" valign="bottom">CL Name<br /><input type="button" value="Sort" onClick="submitSort('clname');" /></th>
<th align="left" valign="bottom">Product Name<br /><input type="button" value="Sort" onClick="submitSort('productname');" /></th>
<th align="left" valign="bottom">Change Status<br /><input type="button" value="Sort" onClick="submitSort('changestatus');" /></th>
</tr>
<% out.print((String)request.getAttribute("table_data"));%>
</table>
</form>
</body>
</html>