Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Developing in a local environment

Developing in a local environment

This is a talk given at the Raleigh WordPress Meetup that goes over the basics of developing in a local environment geared specifically toward WordPress Developers.

55ea809c64e7bba42f566d7bdb4e106e?s=128

Allen Moore

February 18, 2014
Tweet

Transcript

  1. # Developing in a Local Environment ! Allen Moore @creativeallen

    http://www.allenmoore.me
  2. * Building with WordPress since 2005 * Web Designer at

    NC State University Department of Electrical and Computer Engineering * Continuing Education Instructor at Wake Technical Community College * 8 years of Contract and Freelance Work prior to NC State ## About me
  3. 1. What is local development? 2. Installing tools for local

    development 3. Configuration of tools 4. Installing WordPress in a local environment 5. Additional thoughts and tools ## Outline
  4. * Mac OSX * Text editor * Terminal ## Assumptions

    for your environment
  5. * Local environment = your computer * Outside of the

    production environment ### What is local development?
  6. ### Advantages of local development?

  7. * Internet connection not required ### Advantages of local development?

  8. * Internet connection not required * Network failures ### Advantages

    of local development?
  9. * Internet connection not required * Network failures * Internet

    outages ### Advantages of local development?
  10. * Internet connection not required * Network failures * Internet

    outages * Other possible headaches ### Advantages of local development?
  11. * Internet connection not required * Network failures * Internet

    outages * Other possible headaches * Develop from anywhere ### Advantages of local development?
  12. * Internet connection not required * Network failures * Internet

    outages * Other possible headaches * Develop from anywhere * Testing, testing, testing ### Advantages of local development?
  13. * Internet connection not required * Network failures * Internet

    outages * Other possible headaches * Develop from anywhere * Testing, testing, testing * Upload, test, fix, REPEAT ### Advantages of local development?
  14. * MAMP * Windows: WAMP, AMPPS, XAMPP * SQL pro

    * Windows: Heidi SQL, PHPMyAdmin #### Installing tools for local development
  15. * Mac, Apache, MySQL, PHP * http://www.mamp.info #### MAMP

  16. * http://www.sequelpro.com/ #### SQL Pro

  17. * Proper configuration of your development tools will leave you

    with less headaches ##### Configuration of tools
  18. * Change server start/stop ##### MAMP Configuration

  19. * Apache/MySQl Ports ##### MAMP Configuration

  20. * PHP Version ##### MAMP Configuration

  21. * Apache ##### MAMP Configuration

  22. * Open Terminal and enter the following command sudo pico

    /etc/apache2/httpd.conf ##### MAMP Configuration
  23. * Start MAMP ##### MAMP Configuration

  24. * MySQL Server ##### SQL Pro Configuration

  25. * Local copy of WordPress * Database ###### Installing WordPress

    in a local environment
  26. * Download WordPress * http://www.wordpress.org ###### Installing WordPress in a

    local environment
  27. * Copy contents of WordPress to your preferred directory ######

    Installing WordPress in a local environment
  28. * Create a new database in SQL Pro ###### Installing

    WordPress in a local environment
  29. * Edit wp-config-sample.php with database connection info ###### Installing WordPress

    in a local environment
  30. * Edit wp-config-sample.php with WordPress Salt Keys * https://api.wordpress.org/secret-key/1.1/salt/ ######

    Installing WordPress in a local environment
  31. * Edit wp-config-sample.php $table_prefix with unique prefix ###### Installing WordPress

    in a local environment
  32. * Save wp-config-sample.php as wp-config.php ###### Installing WordPress in a

    local environment
  33. * Navigate to your local install and complete the WordPress

    setup ###### Installing WordPress in a local environment
  34. * WordPress is installed! ###### Installing WordPress in a local

    environment
  35. * Let’s log in! ###### Installing WordPress in a local

    environment
  36. * Virtual Hosts such as: * yourdomain.dev * yourdomain.local *

    subdomain.yourdomain.dev * WordPress Multisite install * Sub-directory * Sub-domain ####### Additional thoughts and tools
  37. * Git or version control * GitHub * Bitbucket *

    Gitlab * Database Migration * WP Migrate DB (Free & Premium) * Backup Buddy (Premium) * Staging * WPStageCoach.com * WPEngine (Dev Staging Area) * Command Line Tools * WP-CLI - wp-cli.org * PHP Unit - phpunit.de ####### Additional thoughts and tools