| <html><!-- #BeginTemplate "/Templates/ExamplesTemplate.dwt" --> |
| <head> |
| <!-- #BeginEditable "doctitle" --> |
| <title>JSTL: Import Tags Examples</title> |
| <!-- #EndEditable --> |
| <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> |
| <link rel="stylesheet" href="../global.css" type="text/css"> |
| </head> |
| |
| <body bgcolor="#FFFFFF" text="#000000"> |
| <table width="100%" border="0" cellpadding="5"> |
| <tr> |
| <td height="0"><font color="#000099"><b>standard taglib • implementation |
| of the JSP Standard Tag Library</b></font></td> |
| </tr> |
| <tr> |
| <td bgcolor="#CCCCFF"><font size="-1">Examples <a href="../index.html">Introduction</a> |
| • <a href="../elsupport/index.html">General Purpose</a> |
| • <a href="../conditionals/index.html">Conditionals</a> |
| • <a href="../iterators/index.html">Iterators</a> • |
| <a href="index.jsp">Import</a> • <a href="../format/index.html">I18N |
| & Formatting</a> • <a href="../xml/index.html">XML</a> |
| • <a href="../sql/index.jsp">SQL</a> • <a href="../functions/index.html">Functions</a> |
| • <a href="../tlv/index.html">TLV</a> |
| </font></td> |
| </tr> |
| </table> |
| <!-- #BeginEditable "body" --> |
| <h2>Import Tags Examples</h2> |
| |
| <p>If you are using a Proxy server, you will need to set the following System |
| Properties when starting the VM:</p> |
| <pre> |
| http.proxyHost |
| http.proxyPort |
| ftp.proxyHost |
| ftp.proxyPort |
| </pre> |
| <br> |
| |
| <h3>Absolute <a href="../ShowSource.jsp?filename=/import/Absolute.jsp"><img src="../images/code.gif" |
| width="24" height="24" |
| border="0"></a> |
| <a href="Absolute.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| Using an Absolute URL to import a resource. <br> |
| |
| <h3>Relative <a href="../ShowSource.jsp?filename=/import/Relative.jsp"><img src="../images/code.gif" |
| width="24" height="24" |
| border="0"></a> |
| <a href="Relative.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| Using a Relative URL to import a resource. <br> |
| |
| <h3>Context Relative <a href="../ShowSource.jsp?filename=/import/ContextRelative.jsp"><img |
| src="../images/code.gif" width="24" height="24" border="0"></a> |
| <a href="ContextRelative.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| Importing a resource relative to a foreign context. <br> |
| |
| <h3>Absolute (FTP) <a href="../ShowSource.jsp?filename=/import/AbsoluteFtp.jsp"><img |
| src="../images/code.gif" width="24" height="24" border="0"></a> |
| <a href="AbsoluteFtp.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| Using an Absolute URL to import a resource using a different protocol other than |
| HTTP. <br> |
| |
| <h3>Encode <a href="../ShowSource.jsp?filename=/import/Encode.jsp"><img src="../images/code.gif" width="24" |
| height="24" border="0"></a> |
| <a href="Encode.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| URL encoding examples. <br> |
| |
| <h3>Encode Context Relative <a href="../ShowSource.jsp?filename=/import/EncodeContextRelative.jsp"><img |
| src="../images/code.gif" width="24" height="24" border="0"></a> |
| <a href="EncodeContextRelative.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| URL encoding examples using a relative context and nested param tags. <br> |
| |
| <h3>Encode Query String <a href="../ShowSource.jsp?filename=/import/EncodeQueryString.jsp"><img |
| src="../images/code.gif" width="24" height="24" border="0"></a> |
| <a href="EncodeQueryString.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| URL encoding examples using a relative context and query string. <br> |
| |
| <h3>String Exposure Absolute <a href="../ShowSource.jsp?filename=/import/ExposeString.jsp"><img |
| src="../images/code.gif" width="24" height="24" border="0"></a> |
| <a href="ExposeString.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| Exposing the content of the resource as a String Object. <br> |
| |
| <h3>String Exposure Relative <a href="../ShowSource.jsp?filename=/import/ExposeStringRelative.jsp"><img |
| src="../images/code.gif" width="24" height="24" border="0"></a> |
| <a href="ExposeStringRelative.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| Exposing the content of a relative URL's resource as a String Object. <br> |
| |
| <h3>Param <a href="../ShowSource.jsp?filename=/import/Param.jsp"><img src="../images/code.gif" width="24" |
| height="24" border="0"></a> |
| <a href="Param.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| Using |
| <param> |
| element to specify request parameters. Also demonstrating how request |
| parameters can be URL encoded (default). (NOTE: Returns error page by default.) |
| <br> |
| |
| <h3>Malformed URL <a href="../ShowSource.jsp?filename=/import/StartSlash.jsp"><img src="../images/code.gif" |
| width="24" height="24" |
| border="0"></a> |
| <a href="StartSlash.jsp"><img src="../images/execute.gif" width="24" height="24" border="0"></a> |
| </h3> |
| A relative URL must start with a "/" in a foreign context. (NOTE: This example |
| will result in a ServletException describing the error condition). <br> |
| <!-- #EndEditable --> |
| <hr noshade color="#000099"> |
| <table width="100%" border="0" cellpadding="5"> |
| <tr> |
| <td height="24"><font color="#000099"><b>standard taglib • implementation |
| of the JSP Standard Tag Library</b></font></td> |
| </tr> |
| </table> |
| </body> |
| <!-- #EndTemplate --></html> |