Skip to content

Instantly share code, notes, and snippets.

View frankdarnese's full-sized avatar

Frank D frankdarnese

  • Surrey, England
View GitHub Profile
@frankdarnese
frankdarnese / WP_Query.php
Created March 14, 2019 16:39 — forked from Dimasmagadan/WP_Query.php
#WordPress query with args
<?php
/**
* WordPress Query Comprehensive Reference
* Compiled by luetkemj - luetkemj.com
*
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters
* Source: https://core.trac.wordpress.org/browser/tags/3.9/src/wp-includes/query.php
*/
$args = array(
//////Author Parameters - Show posts associated with certain author.
GREG HOWE (FEAT. RICHIE KOTZEN) - SHADY LANE
HIDEAWAY – JACOB COLLIER
Jump Around by House of Pain(Lyrics)

Who's Lovin You - Jackson 5 (SIMILAR TO MEZZACAPO CLEMENTE singing ETTA JAMES)

Andy Timmons - There Are No Words
tracy chapman - give me one reason
Tracy Chapman - Fast car

Wordpress cache clean

pagespeed_admin/cache#purge_cache

Wordpress Enqueues

Enqueue a Js file template

EXPORT WORDPRESS DABATABE

SSH INTO SERVER
$ ssh www-data@{IP ADDRESS HERE}
- Are you sure you want to continue connecting (yes/no)? yes 
[email protected]'s password:

CD INTO WEBSITE REPO

GitHub Pull Request Template

| | | |
|---|---|---|
| **5s** | **6** | **7 Plus** |
| Image here | Image here | Image here |

Reset yarn and cache React Native

YARN CACHE CLEAN
yarn cache clean
rm -rf node_modules && yarn
# To list the installed packages
```TXT
apm list --installed --bare > ~/Desktop/package-list.txt
```
# To install from that file
```TXT
apm install --packages-file ~/Desktop/package-list.txt
# SSH Keys Generation
### Checking for existing SSH keys first
```TXT
ls -al ~/.ssh
```
### Generating a new SSH key

START A PHP SERVER

Using the WP_CLI
wp server --host=0.0.0.0 --docroot=../../../
Using built in php server
php -S localhost:8888

security.ubuntu.com timeout on apt-get update

Issue

When running the apt-get update command, the process 'hangs' when checking security.ubuntu.com endpoints. This is apparantely due to an issue some sites face when trying to connect over IPv6 and whilst it is assumed that this will be fixed at some point in the future (sooner rather than later judging by the transition to IPv6 by most), the fix below resolves this issue, allowing the update process to complete successfully.

Fix