Recent Notes

Displaying keyword search results 1 - 5
Created by woolf on December 29, 2011 11:18:11    Last update: December 29, 2011 11:18:11
Use the expand command to extract files from a .cab file: expand [-r] source [destination] [-d source.cab ... Option Description [-r] Renames expanded files. [destination] Specifies where files are to be expanded. If source is multiple files and -r is not specified, destination must be a directory. destination can consist of a drive letter and colon, a directory name, a file name, or a combination of any of these. [-d source.cab] Displays a list of files in the source location. Does not expand or extract the files. [-f:files] Specifies the files in a cabinet (.cab) file that you intend to expand. You can use wildcards (* and ?). source.cab Specifies the files to expand. source can consist of a drive letter and colon, a directory...
Created by Dr. Xi on June 16, 2011 13:51:53    Last update: June 16, 2011 14:02:10
With an absolute path to a file, this is the way to construct a URL : URL url = new URL("file:///absolute/path/to/file.e... What if I want a URL for a file relative to the current working directory? URL url = new URL("file:///./file.ext"); // this ... Or, you can use the File class to help you out: URL url = new URL(String.format("file:///%s/file.e...
Created by voodoo on July 11, 2009 15:14:55    Last update: July 29, 2010 22:45:48
cURL is a command line tool for transferring files with URL syntax. The main purpose and use for cURL is to automate unattended file transfers or sequences of operations. It's really easy to see HTTP headers with curl: C:\>curl --head http://www.google.com HTTP/1.0 ... or, headers and page together (dump headers to stdout): $ curl --dump-header - http://www.google.com HTTP/... Download openssl from openssl.org: curl http://www.openssl.org/source/openssl-0.9.6m.... C:\>curl --help Usage: curl [options...] <url> ...
Created by Fang on April 01, 2010 22:24:58    Last update: April 02, 2010 02:49:38
In this note I'll show you how to create and package a JSP custom tag. The purpose of this tag is to display a random splash image for a home page, among a set of images. We should be able to add or delete candidate splash images from the WAR archive without the need to change the JSP. This is the intended use of the tag: <%@ taglib uri="http://custom.tag.com/demo" prefix... In the above example you provide a set of images named splash*.png (e.g., splash1.png, spalsh2.png, ...), and the tag will pick a random one to display when the JSP is rendered. Let's get started. I'll use Maven for this purpose. Create the standard Maven directory structure ./pom.xml ./src ./src/main ./src/main/jav... pom.xml <project xmlns="http://maven.apache.org/POM/4.0.0"... SplashTag.java package tagdemo; import java.util.ArrayList......
Created by Dr. Xi on October 06, 2008 18:39:53    Last update: October 06, 2008 18:39:53
Python modules are searched in the list of directories given by the variable sys.path which is initialized from: the directory containing the input script (or the current directory) the list of directories specified by the environment variable PYTHONPATH the installation-dependent default. peaches@bashful:~/tmp$ export PYTHONPATH=`pwd` ...