写真 アプリ開発 時々旅行 そしてテニス

wp-members ログインフォーム変更

wp-members の フォームが、左側に寄ってしまい、修正できなかったので対応してみました。

最初は、CSSのみで対応できるかと思ったのですが、最終的に CSS だけでは難しいようでした。


add_filter( 'wpmem_sidebar_form', 'my_sidebar_form_filter' ); 
function my_login_form_filter( $form, $action )
$form = str_replace( 'ユーザー名','会員登録
', $form );
$form = str_replace( 'パスワード','パスワード
', $form );
$form = str_replace( ' ログイン情報を保存  ',' ログイン情報を保存  ', $form );
$form = str_replace( '','', $form );
$form = str_replace( '新規ユーザー登録', '会員登録', $form );
return $form;

その上で、css の属性を触っています。

	text-align: center;

#wpmem_login input{
	margin:10px 0 10px 0;

Gemini PDA

3月に indiagogo に出資した、 Gemini PDA やっと出荷されたようですが、香港→シンガポール→深圳→成田と向かっているようです。

えらい遠回り(笑) なんでも、リチウムイオン系の電池は、香港から日本に向かえないようで、こうなるみたいです。



OS-X yosemite phpmyadmin を動作させる(php/mysql連動)

os-x で phpmyadmin を動作

mysql / php は入っているものとします。


apache 確認(yosemite はapache 初期導入済み)


$ httpd -v

Server version: Apache/2.4.28 (Unix)

Server built:   Oct 29 2017 19:23:15


apache 起動

sudo /usr/sbin/apachectl start


php.ini 設置

sudo cp -p /etc/php.ini.default /etc/php.ini

apache/php 連動

$ sudo vi /etc/apache2/httpd.conf
#LoadModule php5_module libexec/apache2/
LoadModule php5_module libexec/apache2/


$ sudo /usr/sbin/apachectl restart




ここ からダウンロード(ブラウザでダウンロード)



自分の環境では自動的に unzip されるが、必要なら、upzip

$ sudo cp -rf phpMyAdmin-4.7.9-all-languages /Library/WebServer/Documents/phpMyAdmin


$ cd /Library/WebServer/Documents/phpMyAdmin/
$ sudo mv
$ sudo vi
$cfg['Servers'][$i]['host'] = ‘localhost’;
$cfg['Servers'][$i]['host'] = ’′;

Larval 5.5 をOS-X にインストール

OS-X ELCAPTION に laravel をインストールしました。その忘備録

PHP が 5.5 なので、PHP を7に上げる。


brew がないのでインストール

OS-X ELCAPTION(10.11) には /usr/local/bin がないので作成
$ sudo mkdir /usr/local/bin
path を通す。
$ vim ~/.bash_profile
export PATH=/usr/local:$PATH


$ ruby -e “$(curl -fsSL”

path を通す。
$ source ~/.bash_profile


home-brew のlink が、PHPに届いていないようなので、それを設定します。

core を確認
$ brew -vHomebrew 1.5.9Homebrew/homebrew-core (git revision b1ce; last commit 2018-03-09)
php -vPHP 5.5.38 (cli) (built: Oct 29 2017 20:49:07) Copyright (c) 1997-2015 The PHP GroupZend Engine v2.5.0, Copyright (c) 1998-2015 Zend Technologies
$ brew taphomebrew/core
core とPHP をhomebrewに通す
$ brew tap homebrew/core
$ brew tap homebrew/php
$ brew search php7
brew search php7==> Searching local taps...homebrew/php/php70                         homebrew/php/php70-uv                      homebrew/php/php71-timecophomebrew/php/php70-amqp                    homebrew/php/php70-v8js                    homebrew/php/php71-


$ brew install homebrew/php/php70
path を通す
$ vi .bash_profile 
export PATH="$(brew --prefix homebrew/php/php70)/bin:$PATH"
$ source .bash_profile
$ php -v
PHP 7.0.27 (cli) (built: Jan  5 2018 12:23:32) ( NTS )Copyright (c) 1997-2017 The PHP GroupZend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies



$ brew info mysql
mysql: stable 5.7.21 (bottled), devel 8.0.4-rcOpen source relational database management system with:  mariadb (because mysql, mariadb, and percona install the same binaries.)  mariadb-connector-c (because both install plugins)  mysql-cluster (because mysql, mariadb, and percona install the same binaries.)  mysql-connector-c (because both install MySQL client libraries)  percona-server (because mysql, mariadb, and percona install the same binaries.)Not installedFrom:> DependenciesBuild: cmake ✘Required: openssl ✔==> RequirementsRequired: macOS >= 10.7 ✔==> Options--with-debug Build with debug support--with-embedded Build the embedded server--with-local-infile Build with local infile loading support--with-memcached Build with InnoDB Memcached plugin--with-test Build with unit tests--devel Install development version 8.0.4-rc==> CaveatsWe've installed your MySQL database without a root password. To secure it run:    mysql_secure_installation
MySQL is configured to only allow connections from localhost by default
To connect run:    mysql -uroot
To have launchd start mysql now and restart at login:  brew services start mysqlOr, if you don't want/need a background service you can just run:  mysql.server start


$ brew install mysql
mysql.server startStarting MySQL. SUCCESS!


Securing the MySQL server deployment.
Connecting to MySQL using a blank password.
VALIDATE PASSWORD PLUGIN can be used to test passwordsand improve security. It checks the strength of passwordand allows the users to set only those passwords which aresecure enough. Would you like to setup VALIDATE PASSWORD plugin?
Press y|Y for Yes, any other key for No: Please set the password for root here.
New password:
Re-enter new password: By default, a MySQL installation has an anonymous user,allowing anyone to log into MySQL without having to havea user account created for them. This is intended only fortesting, and to make the installation go a bit smoother.You should remove them before moving into a productionenvironment.
Remove anonymous users? (Press y|Y for Yes, any other key for No) : ySuccess.

Normally, root should only be allowed to connect from'localhost'. This ensures that someone cannot guess atthe root password from the network.
Disallow root login remotely? (Press y|Y for Yes, any other key for No) :
... skipping.By default, MySQL comes with a database named 'test' thatanyone can access. This is also intended only for testing,and should be removed before moving into a productionenvironment.

Remove test database and access to it? (Press y|Y for Yes, any other key for No) :
... skipping.Reloading the privilege tables will ensure that all changesmade so far will take effect immediately.
Reload privilege tables now? (Press y|Y for Yes, any other key for No) :
... skipping.All done!


$ mysql -uroot -p
grant all privileges on *.* to xxxxx@localhost identified by 'xxxxxxx';


$composer global require "laravel/installer=~1.1"


composer create-project laravel/laravel test --prefer-dist
cd testsudo chmod -R 777 storage


php artisan serve