This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 如下, | |
| root@ubuntu:/var/www# cat .htaccess | |
| Header set X-Frame-Options SAMEORIGIN | |
| 报错。 | |
| 解决方案, | |
| root@ubuntu:/var/www# a2enmod | |
| Your choices are: actions alias asis auth_basic auth_digest authn_alias authn_anon authn_dbd authn_dbm authn_default authn_file authnz_ldap authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cern_meta cgi cgid charset_lite dav dav_fs dav_lock dbd deflate dir disk_cache dump_io env expires ext_filter file_cache filter headers ident imagemap include info ldap log_forensic mem_cache mime mime_magic negotiation php5 proxy proxy_ajp proxy_balancer proxy_connect proxy_ftp proxy_http proxy_scgi reqtimeout rewrite setenvif speling ssl status substitute suexec unique_id userdir usertrack version vhost_alias |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package.json里的dependencies,组件版本通常都有关联性。 | |
| 比如,下面这个,npm install是OK的。 | |
| "dependencies": { | |
| "native-base": "^2.0.5", | |
| "react": "^15.4.1", | |
| "react-native": "0.41.2", | |
| "react-native-banner": "^0.1.0", | |
| "react-native-easy-toast": "^1.0.5", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Use command below to get react-native version: | |
| $ react-native --version | |
| react-native-cli: 2.0.1 | |
| react-native: 0.38.1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *** macOS, install brew first. | |
| $ brew install imagemagick | |
| *** I need to convert a lot of images with different width/height to same width(150px) and height(200px), and images cannot be deformation. | |
| *** write a shell script below: | |
| #!/bin/bash | |
| for img in `ls *.jpg` | |
| do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | |
| $ brew install redis | |
| *** To have launchd start redis now and restart at login: | |
| *** brew services start redis | |
| *** Or, if you don't want/need a background service you can just run: | |
| *** redis-server /usr/local/etc/redis.conf |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # wget http://downloads3.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz | |
| # tar xvfz ioncube_loaders_lin_x86-64.tar.gz | |
| # PHP_VERSION=$(php -r "echo PHP_MAJOR_VERSION.'.'.PHP_MINOR_VERSION;") | |
| # cp "ioncube/ioncube_loader_lin_${PHP_VERSION}.so" /usr/lib/php5/20121212/ | |
| # service apache2 restart | |
| # service php5-fpm restart | |
| # vi /etc/php5/apache2/php.ini | |
| *** Find and Add: | |
| zend_extension = /usr/lib/php5/20121212/ioncube_loader_lin_5.5.so |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ sudo su | |
| # apt-get update | |
| # apt-get install mysql-server mysql-client | |
| *** New password for the MySQL “root” user:Repeat password for the MySQL “root” user: | |
| # apt-get install apache2 | |
| # apt-get install php5 libapache2-mod-php5 | |
| # apt-get install php5-mysql php5-curl php5-gd php5-intl php-pear php5-imagick php5-imap php5-mcrypt php5-memcache php5-ming php5-ps php5-pspell php5-recode php5-snmp php5-sqlite php5-tidy php5-xmlrpc php5-xsl | |
| # apt-get install phpmyadmin | |
| *** enable useful mods |