From c004bbdf4f0e824e5ccbaef8f98ca4a3d44d3b49 Mon Sep 17 00:00:00 2001 From: wei <> Date: Fri, 14 Jul 2006 06:46:31 +0000 Subject: Changed SQLMap manual into a prado app. --- .../protected/pages/Manual/Configuring.page | 47 ++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 demos/sqlmap-docs/protected/pages/Manual/Configuring.page (limited to 'demos/sqlmap-docs/protected/pages/Manual/Configuring.page') diff --git a/demos/sqlmap-docs/protected/pages/Manual/Configuring.page b/demos/sqlmap-docs/protected/pages/Manual/Configuring.page new file mode 100644 index 00000000..75dade31 --- /dev/null +++ b/demos/sqlmap-docs/protected/pages/Manual/Configuring.page @@ -0,0 +1,47 @@ + + +

Configuring the DataMapper for PHP

+

The SQLMap PHP DataMapper is configured using a central XML descriptor file, +usually named SqlMap.config, which provides the details for your data +source, data maps, and other features like caching, and transactions. At +runtime, your application code will call a class method provided by the SQLMap +library to read and parse your SqlMap.config file. After parsing the +configuration file, a DataMapper client will be returned by SQLMap for your +application to use.

+ +

DataMapper clients

+

Currently, the SQLMap PHP DataMapper framework revolves around the +TSqlMapper class, which acts as a facade to the DataMapper framework API. +You can create a DataMapper client by instantiating an object of the +TSqlMapper class. An instance of the TSqlMapper class (your +DataMapper client) is created by reading a single configuration file. Each +configuration file can specify one database or data source. You can of couse +use multiple DataMapper clients in your application. Just create another +configuration file and pass the name of that file when the DataMapper client +is created. The configuration files might use a different account with the +same database, or reference different databases on different servers. You can +read from one client and write to another, if that's what you need to do. +First, let's take a look at the DataMapper configuration file. + +

DataMapper Configuration File (SqlMap.config)

+

A sample configuration file for a PHP web application is shown below. +Not all configuration elements are required. See +DataMapper Configuration Elements +for details of each configuration elements in a SqlMap.config file. + + +<?xml version="1.0" encoding="utf-8"?> + + + + + + + + + + + + + + \ No newline at end of file -- cgit v1.2.3