REMOTE SQL using php4 and VB6 Created by Pablo Gazmuri [email@example.com] in September 2002 Very special thanks to: Mukul Sabharwal [firstname.lastname@example.org] for a PHP implementation of RC4 David Midkiff (email@example.com) for a VB implementation of RC4 Klemens Schmid - http://www.schmidks.de/ for the XMLHTTP30 usage code This Visual Basic and PHP combination allows you to remotely execute and retreive SQL queries to and from your online databases. The VB code makes http requests to an online script (written in PHP) which executes your query and returns the result. The queries and results are encrypted using rc4 encryption, which is now free for use (no patent fees apply), and the PHP script can be configured to only accept queries from a specific IP address. This code provides the basis for building back-end client-side components (in VB of course). The idea is that a VB application is much more responsive than web-based administration tools, and things like category or menu manipulation (via the VB tree view control) are much more user-friendly in a client-side app than in their cumbersome web-based counterparts. The code could be extended to allow for binary data uploads as well, although a good VB FTP class could accomplish the same thing. For those of you who abhor Microsoft, I apologize and invite you to create a Java client (I initially developed this for a larger VB App) To use the VB portion of this project, you must add a reference to Microsoft XML version 3.0 (msxml3.dll) to the project file Although the project references msxml3.dll, you will also need msxml3a.dll and msxml3r.dll installed to run this code. You can download these .dll's from microsoft if they are not already on your system. The PHP code is designed for use with a MySQL database, but could easily be modified for use with other databases. NB - You need to set the encryption keys in both the VB source (Query.bas) and your PHP file (sql-link.php). They must be the same string, and should not be words found in the dictionary. The longer the string, the better the encryption.