Skip to content

txinparta/wordpresspj

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WordPress clean instalation through Composer

Plugins and themes are located outside the wp folder, so we can manage them separately: on one hand themes and plugins and on the other wordpress itself.

Structure

  • public/

    • wp-content/     - It contains plugins and themes
    • wp/       - Our subdirectory install location for WordPress
    • .htaccess     - If necessary
    • index.php
    • wp-config.php
  • vendor/

  • .gitignore

  • composer.json

  • composer.lock

  • local-config.php

  • .gitignore

Starting our project

  1. Create a folder: mkdir my_folder
    * Be sure you have Composer installed. If you don't have it globaly installed, you can donwload the composer.phar localy (curl -sS https://getcomposer.org/installer | php)
  1. Create folder my_folder/public/
  1. Create composer.json. Copy the file uploaded in txinparta/wordpresspj
  1. Create .gitignore
  1. Install WordPress: run composer install (or php composer.phar install)
  1. Copy and move
	cp -R public/wp/{wp-content,index.php,wp-config-sample.php} public/
	mv public/wp-config-sample.php public/wp-config.php
  1. Modify public/index.php:
	require( dirname( __FILE__ ) . '/wp-blog-header.php' );
	Replace by:
	require( dirname( __FILE__ ) . '/wp/wp-blog-header.php' );
  1. Configure local-config.php.
    Fill out database data connection and keys (https://api.wordpress.org/secret-key/1.1/salt/).
  1. Configure public/wp-config.php.
    In the same way as it is in this repository.

About

WordPress installation through Composer

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages