Windows+xampp+yii+sqlserver Configuration Tutorial

Source: Internet
Author: User
Tags dsn mssql sqlite yii

First download XAMPP website address: https://www.apachefriends.org/zh_cn/index.html
650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5ab86b10655 C803c24111d0dcab8964204ac7efc07639103fe77bd8628997ca67414d853d512741e72&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle;line-height : 1.5;width:716px;height:431px; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

This is the other version of XAMPP that is primarily for PHP version https://www.apachefriends.org/download.html

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5ada2be07ab Afe088be31aaaaf545eaf8689747917b9989feceb9fcd73c0d904e4c14ab1b88cb19236&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5a93c26d9d0 E7fc687e2cbe4432df95c55eb6724480f74a9a3e9d3a32174784bed331e6e65f12b42cd&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5acb5072f09 925e574d2e6879dede2cb11e3412048563a4f0b4c17e0050e244778efd8a32d17b0c79e&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

Always next, the middle has access prompt always point allow to know the end of installation

Run

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5ac219d93e2 3115b83a63d858fa5e3db0ee15f2cb9b5d565563f6115d0892f7d4f89e3f1f0d4f7da70&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5aae5b8d2a8 67a2c6b609eaadbc6498c32dd21f9678cf19ed1ee590515aed2b780509584cad0e022f5&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

By the time you're done, you need to put botappserver, our code, in the root directory C:\xampp\htdocs

It's basically done more than half.

Remember to run the CMD CD to C:\xampp\htdocs\botappServer

Then run Init

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5ae017045f2 40d8fbec15ce2f0c6b0e7f94b98b965c8c11a31e2c77a279e12ef1149cd78475bd469f8&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5af4ed2c7df 0b2a11b8d10459eea38cae8dbb2b0a30932f6c771a8a2a6b659152f489788895299506f&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

Open file C:\xampp\php\php.ini here to add C:\xampp\php\ext support for SQL Server dynamic library files Xampp Actually, it's a really big place.

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5aeda90efb2 722f361fa3016afda53574150a8781e7bc0fa22618c5d9af761febcf21d488adf6b057e&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle;width:761px ; height:440px; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

Extension=php_sqlsrv_56_ts.dll
Extension=php_pdo_sqlsrv_56_ts.dll

Here is to set up our service interface for direct access to the address such as http://localhost will jump directly to the server interface does not need to be like Http://localhost/botappserver/api/web

Open Directory C:\xampp\apache\conf find httpd.conf open Edit

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5ac2d357e6e B89f3173636e2a4d5c341fbcc80b52047d721c163a33052c921d185c6d746d333e05dfb&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle;width:761px ; height:440px; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5adf5b14d04 Aa56cd827c5fedeeb6a97691967106b1703f5254625f0db4b2fb3aecfa31e3c59d59dff&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle;width:761px ; height:525px; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

Edit C:/xampp/htdocs/botappserver/api/web

<directory " c:/xampp/htdocs/botappserver/api/web" > Zhuyi </Directory> middle to add

# Turn on mod_rewrite support for beautifying URL features (pretty URL option)
Rewriteengine on
# If the requested file or directory is real, direct access to the
Rewritecond%{request_filename}!-f
Rewritecond%{request_filename}!-d
# If the request is not a real file or directory, distribute the request to index.php
Rewriterule. index.php

# ... Other Settings ...

Set up here to complete restart service start

Locate the Botappserver directory under Botappserver\common\config main-local.php

Open it

650) this.width=650; "Src=" https://set1.mail.qq.com/cgi-bin/viewfile?f= 71bd4ac129c94b1fbced14094faec37e932d33b78077cdf9ca86893782ce0c1a0f17b8bd20b0647a8fbbd89696b66aafed959fcefe038b5ae71165584 B6535eea2a195db69939454ae38865f4d49fec1afc54d7a863a136e89bad294e9fcbc2d&mailid=zl4121-5hyde4mkh_ 6xtfifjxrqb66&sid=xt9yslpysmmxemqz&net=1402177802 "style=" border:none;vertical-align:middle;width:761px ; height:387px; "alt=" VIEWFILE?F=71BD4AC129C94B1FBCED14094FAEC "/>

Note the unnecessary, this is a way to connect a variety of databases for reference

return [ // ... ' components '= [// ... ' DB '= [' class '=' Yii\db\connection ', ' DSN '=' Mysql:host=localhost;dbname=mydatabase ', //MySQL, MariaDB //' DSN ' = ' sqlite:/path/to/database/file ',//SQLite //' DSN ' = ' pgsql:host=localhost;port=5432;dbname=mydatabase ',//PostgreSQL //' DSN ' = ' cubrid:dbname=demodb;host=localhost;port=33000',//Cubrid //' DSN ' = ' sqlsrv:server=localhost;database=mydatabase ',//MS SQL Server, sqlsrv driver //' DSN ' = ' dblib:host=localhost;dbname=mydatabase ',//MS SQL Server, dblib driver //' DSN ' = ' mssql:host=localhost;dbname=mydatabase ',//MS SQL Server, MSSQL driver //' DSN ' = ' oci:dbname=//localhost:1521/mydatabase ',//Oracle ' username '=' Root ', //Database user name ' Password '="', //Database Password ' CharSet '=' UTF8 ', ], ], // ... ];


This article from "Hennychen" blog, reproduced please contact the author!

Windows+xampp+yii+sqlserver Configuration Tutorial

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.