Skip to content

Instantly share code, notes, and snippets.


Josh Pollock Shelob9

Block or report user

Report or block Shelob9

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View 0.MD

Using WordPress Featured Images In Gatsby

GraphQL Queries For WordPress Posts With Featured Image

query PostsWithFeaturedImage {
  allWordpressPost {
    nodes {
Shelob9 /
Last active Oct 14, 2019
Set up Windows 10 for web development

Git Bash And Git

Go Here Click download. Install git bash.

git config --global ""
git config --global "Josh Pollock"
View Editor.js
export const Editor = ({attributes}) => {
const {something} = attributes;
const [data,setData]= useState({});
useEffect( () => {
fetch( `${something}`)
.then(r => r.json())
.then(r => setData(r);
}, [something, setData]);
return (
<div />
View admin-ajax.php
add_action('wp_ajax_get_option', function () {
if (empty($_GET['_my_nonce']) || wp_verify_nonce($_GET['_my_nonce'],
'my-nonce-action') || !current_user_can('something')) {
View V.txt
Verifying my Blockstack ID is secured with the address 1C4r2UeoMVxUCoCaeFqdzAFzXmGuuWsYn5
View block.json
"name": "namespace/name",
"title": "Block Name",
"category": "common",
"icon": "star",
"description": "Shows warning, error or success notices ...",
"keywords": [
View add-on.php
* Plugin Name: Test Add-on
add_action('wp_enqueue_scripts', function () {
esc_url_raw(plugins_url('test-add-on.js', __FILE__)),
View redirect-processor.php
* On form submit, do a redirect to a diffrent site, then complete submission
add_action('caldera_forms_submit_process_start', function (
) {
//If we have a already done redirect, do nothing
View block-submission-based-on-field.js
jQuery(document).ready(function($) {
//variable to prevent blocking all
var blockedOnce = false;
$(document).on("cf.ajax.request", function(e, obj) {
//only block submission once
if (!blockedOnce) {
//Make sure window.cf2 is set properly
if (!window.cf2) {
window.cf2 = {};
You can’t perform that action at this time.