Alibabacloud.com offers a wide variety of articles about past weather data by zip code, easily find your past weather data by zip code information here online.
PrefaceJust now on the internet to inquire about the national provinces and Cities database, compared to the pit is a relatively comprehensive data, a comprehensive fee, the heart is very uncomfortable.But in the end, I got it. A slightly better national provincial and municipal database, and with left, simple spell, abbreviation, pinyin, Administrative Code, ZIP
Example of zip compression for php files1. Download the zip. php tool class that I have prepared, decompress it, and put the files in the directory. I put the files in the include folder under the virtual directory.2. Add the following code to your php file:Usage:Require_once "./include/zip. php ";$
Tags: var blog city style float null creat int arcNational provinces and Cities database, and with the left, simple spell, abbreviation, pinyin, Administrative Code, postcode, city three loadline data CREATE TABLE [dbo]. [Region] ([Id] [int] NULL, [Name] [nvarchar] ( +) NULL, [ParentID] [int] NULL, [shortname] [nvarchar] ( +) NULL, [LevelType] [int] NULL, [citycode] [varchar] ( -) NULL, [ZipCode] [varchar]
1. Please download my prepared zip.php tool class, download and unzip, put the file in the corresponding directory, I was placed in the virtual directory under the Include folder.
2. Add the following code to your PHP file
Copy Code code as follows:
Require_once "./include/zip.php";
$zip = new Phpzip
1. Please download my prepared zip.php tool class, download and unzip, put the files inside the corresponding directory, I was placed in the virtual directory in the Include folder.
2. Add the following code to your PHP file
Copy CodeThe code is as follows:
Require_once "./include/zip.php";
$zip = new Phpzip ();
$zip-
This program can be quickly implemented to our files using PHP compression class compressed into our thinking zip, or rar compression package, suffix name can be customized Oh, compression algorithm is from a foreign site copy.
First instantiate and then pass the argument. Two parameters. First an array of your file addresses. The second is the absolute address of the compressed package file that you want to save.
For example:
The
Previous
Using soap to transmit data over the network results in a slow transmission speed due to a large amount of data.To solve this problem, you can zip the file before passing it.Because almost all data is transmitted in the database, the compression space is very large.Tested, it can be compressed to the original 1/15 Method 1: use Java Compres
Parsing an XML file from a zip file The general step is to extract the zip file first, and then parse the XML directly from the zip file to read the input stream from it to reduce the I/O operation. The following is an example of parsing an XML file from a ZIP file:
The
Er, I have reviewed my previous articles today. The highest attention rate is the "self-painted radiobutton". Many people have sent messages to send source code, which is also lazy, now the source code connection has been added to the end of the article, and it is also the download of csdn. I hope it will help some people. Looking at what I wrote before is quite interesting, especially the learning version
Many of my friends will use JDK's built-in zip-related APIs to compress and decompress the zip file. This function is no problem if the zip file is used in full English, but it cannot be used in Chinese, next I will introduce a program that supports Chinese Java compression and decompression zip files.
Apache ant:
Http
For work reasons, a complete zip code database is required. The data on the Internet is relatively old and there is very little data. I really hope the post office can download the zip code for free, or you can have an interface.
pathName) {ZipFile = new File (pathName);}
public void Compress (String srcpathname) { File srcdir = new file (srcpathname); if (!srcdir.exists ()) Throw The new RuntimeException (Srcpathname + "does not exist.) "); Project PRJ = new Project (); Zip zip = new zip (); Zip.setproject (PRJ); Zip.setdestfile (ZipFile); Fileset fileset = new Fileset (); Fil
2011-04-01 17:58:52| Category: Android | Report | Font size Subscription How does the unzip function of the zip file be implemented in the Android platform? Because Android has integrated the Zlib library, for the English and non-password zip file decompression is relatively simple, the following Android123 to everyone a zip
PHP + AJAX automatically completes the example: processing the zip code. After the customer enters a POSTCODE, zipcode. PHP receives it, extracts the corresponding data from the data table, and then returns it to the client in a certain format (separated by | ). After the customer enters a POSTCODE, zipcode. PHP receiv
installation, you only need to include it when using it again.
For example:
This way
In addition, in the extract part, the files are extracted in order of folders, instead of simply extracting files.
Related usage is like this
The code is as follows:
Require_once ('pclzip. lib. php ');$ Archive = new PclZip('archive.zip ');If ($ archive-> extract () = 0) {/* the decompression path is the same as the original path */Die ("Error:". $ archive-> err
Note: This code is a little bug, so you have to use it together ~~ Bug1: If duplicate files exist, a window indicating whether to overwrite the files is displayed on the server. Therefore, do not duplicate the directories when extracting files. Bug2: it is the compression time. Similarly, there should be no duplicate names. In addition, at the beginning, create a zip file, copy it, and add it to it. The ove
In the actual project code use process, found that if the Java class Library standard specified Gzipinputstream read compressed data decompression does not work stably, the reason is unknown. Instead of using Inflaterinputstream to replace Gzipinputstream stable, normal work, now the Inflaterinputstream-based Zip\gzip Decompression
accordance with the order of the folder to extract, rather than simply extract the file Eucalyptus out
Related usage like this
Copy Code code as follows:
Require_once (' pclzip.lib.php ');
$archive = new Pclzip (' Archive.zip ');
if ($archive->extract () = = 0) {/* The decompression path is the same path as the original file * *
Die ("Error:". $archive->errorinfo (true));
}
?>
extract part, the files are extracted in order of folders, instead of simply extracting files.
Related usage is like this
Copy codeThe Code is as follows: Require_once ('pclzip. lib. php ');
$ Archive = new PclZip('archive.zip ');
If ($ archive-> extract () = 0) {/* the decompression path is the same as the original path */
Die ("Error:". $ archive-> errorInfo (true ));
}
?>
You can also specify the decompression path, suchCopy codeThe
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.