XAMPP assembly and deployment of thinkphp

Source: Internet
Author: User
Tags download redis zts install redis
Installation of XAMPP and deployment of thinkphp

First, the installation of XAMPP

1, Xampp's download:

Https://www.apachefriends.org/zh_cn/index.html

XAMPP for Linux v5.6.12

The downloaded file is: Xampp-linux-x64-5.6.12-0-installer.run

2. Installation

? Other permissions cannot be installed. Switch to Linux under root authority and execute./xampp-linux-x64-5.6.12-0-installer.run

3. Start XAMPP

? ?? [[email protected] lampp]#/opt/lampp/lampp start

Starting XAMPP for Linux 5.6.12-0 ...

Xampp:starting Apache...ok.

Xampp:starting Mysql...ok.

Xampp:starting Proftpd...ok.

? ?

4. Visit xampp

? ? http://localhost/

?

? ? External access also shuts down Firewall service iptables stop

? ? http://192.168.0.106/

? ? Phpinfo:? http://192.168.0.106/dashboard/phpinfo.php

?

Ii. Deployment of thinkphp

? ? 1. Download thinkphp liunux installation file

???? http://www.thinkphp.cn/? Download Thinkphp_3.2.3_full.zip

? ? 2. Deploy to XAMPP

? ? Unzip to/opt/lampp/htdocs/thinkphp

? ? 3. Add permissions to application under thinkphp directory

? ? If you do not add access to the thinkphp, the following prompt appears: the application directory [./application/] is not writable and the directory cannot be generated automatically!

? ?? [Email protected] lampp]# chmod a+w application/

? ? 4, visit thinkphp?

? ? ? http://192.168.0.106/thinkphp

? ?

? third, PHP installation Redis plugin

? ? 1. Download Redis Plugin

???? http://www.redis.io/clients

??? Download the PHP language plugin phpredis:phpredis-develop.zip

Extract to cd/home/hadoop/temp/ Phpredis-develop

???? 2, build the installation file and install

??? 2.1 Build Configure file:/opt/lampp/bin/phpize

? ? M4 and autoconf files may need to be installed, see http://blog.csdn.net/21aspnet/article/details/7471574

??? 2.2 Make

??? 2.3 Make Install

? ? ? [[email protected] phpredis-develop]# make install

? ? ? Installing shared extensions:?? /opt/lampp/lib/php/extensions/no-debug-non-zts-20131226/

? ? ? 2.4 View the generated Redis plug-in

? ? ??

[Email protected] phpredis-develop]# Cd/opt/lampp/lib/php/extensions/no-debug-non-zts-20131226/[[email protected] no-debug-non-zts-20131226]# lltotal 2148-rwxr-xr-x. 1 root root   49312 08:52 mssql.so-rwxr-xr-x. 1 root root  156856 08:52 oci8.so-rwxr-xr-x. 1 root root< c2/>143976 08:52 opcache.so-rwxr-xr-x. 1 root root   20496 08:52 pdo_dblib.so-rwxr-xr-x. 1 root root  132480 08:52 pgsql.so-rwxr-xr-x. 1 root Root   42960 08:52 radius.so-rwxr-xr-x. 1 root root 1423553 19:47 redis.so-rwxr-xr-x. 1 root root  
?? redis.so is the Redis plugin that is generated.

?

?? 3. Configuring the Redis Plugin

? ?? [Email protected] etc]# pwd

? ? /opt/lampp/etc

? ? [Email protected] etc]# VI php.ini

? ? Added: extension= "redis.so"

?? 4, restart PHP (XAMPP).

? ?

? ? 5. See if the Redis plugin is installed successfully

???? http://192.168.0.106/dashboard/phpinfo.php

??? to see a list of Redis lists

? ? 6, install Redis program, write demo test.

? ? Redis installation is not mentioned here, self-check the installation. The default port.

? ? htdocs/demo/redisdemo.php:

 
  Connect ("127.0.0.1"), $redis->set ("name", "Leh"), $data = $redis->get ("name"), Echo ($data);

? ??

? ? Test: http://192.168.0.106/demo/redisdemo.php

? ? Leh

?

? Iv. installing thrift to enable PHP to access HBase

? ? ? 1, download thrift.

? ? ? Thrift-0.9.2.tar.gz

??? 2, installation Configuration thrift

? ? ? first run the $./bootstrap.sh in the root directory to generate the Configure script ?

if the download is directly a tarball, skip this step and run the Configure script directly under the software root directory ?

? ??

./bootstrap.sh./configuremakemake Install

? ?? 3, copy thrift-0.9.2/lib/php to the corresponding PHP web directory htdocs/demo/hbasethrift

?? 4, generate PHP and HBase interface files

#/home/hadoop/software/thrift/bin/thrift--gen php/home/hadoop/temp/hbase/src/main/resources/org/apache/hadoop/ Hbase/thrift/hbase.thrift

# (according to your own directory settings)

Build catalog file:/home/hadoop/temp/gen-php/hbase

?? There are files: hbase.php,hbase_types.php

Copy hbase.php,hbase_types.php to: Web directory/opt/lamp/php/hbasethrift/libs/packages/hbase/

?

?

?

?

?

  • 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.