I believe many people are familiar with the dream program. I am here to share with you some tips on its powerful functions.
How can we achieve data sharing between two sites when we use two sets of dream weaving programs? I have not found it on the internet for a long time. I have figured out a method and want to share it with you. The condition for implementing this method is that the database you bought supports external database calls. Otherwise, you can only find another database. The procedure is as follows:
1. First, find the database connection, find the/data/tag/SQL. inc. php file in sequence, open the file, and see the following code. Write down your database configuration, save and close it!
// Dbsql database connection Configuration
//------------------------------------------------------------------------
$ Sqltag ['dbsql'] ['dbhost'] = 'database ip ';
$ Sqltag ['dbsql'] ['dbname'] = 'database name ';
$ Sqltag ['dbsql'] ['dbuser'] = 'database username ';
$ Sqltag ['dbsql'] ['dbpwd'] = 'database password ';
$ Sqltag ['dbsql'] ['dbprefix'] = 'database table prefix; default value: dede _';
$ Sqltag ['dbsql'] ['dblanguage'] = 'encoding format, such as utf8 and gb2312 ';
2. log onto the Space Provider control panel and fill in the authorized IP address in the database, that is, the IP address of the Data website you use to call. It is generally supported. You can ask the Space Provider, for example:
3. Write the following code as needed:
{Dede: SQL = "select * from dede_archives orderby id desc limit 0, 10" appname = "dbsql "}
[Field: title/]
{/Dede: SQL}
Use the {dede: SQL} label for calling. The appname = "dbsql" here is the name in the database link configuration in step 1.
This is the data that one party calls the other. Likewise, the two sites can call each other to enrich the website. Welcome to join www.321jm.com for a reprinted Project