Skip to content

Instantly share code, notes, and snippets.

Avatar

Gino onigetoc

View GitHub Profile
View gist:91b95ef8158c0b88c55522f17c745bb5
{ "categories" :
[ { "name" : "Movies",
"videos" : [
{ "description" : "Big Buck Bunny tells the story of a giant rabbit with a heart bigger than himself. When one sunny day three rodents rudely harass him, something snaps... and the rabbit ain't no bunny anymore! In the typical cartoon tradition he prepares the nasty rodents a comical revenge.\n\nLicensed under the Creative Commons Attribution license\nhttp://www.bigbuckbunny.org",
"sources" : [ "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4" ],
"subtitle" : "By Blender Foundation",
"thumb" : "images/BigBuckBunny.jpg",
"title" : "Big Buck Bunny"
},
{ "description" : "The first Blender Open Movie from 2006",
@onigetoc
onigetoc / Materialize-Mobile.html
Last active Jul 14, 2022 — forked from TerrenceLP/landing-like-google.html
Materialize CSS Demo Template
View Materialize-Mobile.html
Materialize-Mobile.html
<!DOCTYPE html>
<html>
<head>
<!--Import Google Icon Font-->
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<!-- Compiled and minified CSS -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/css/materialize.min.css">
<!--Let browser know website is optimized for mobile-->
@onigetoc
onigetoc / countries.json
Created Jul 12, 2022 — forked from tiagodealmeida/countries.json
List of countries with country code, name, currency code, population, capital and continent name in JSON format
View countries.json
{
"countries": {
"country": [
{
"countryCode": "AD",
"countryName": "Andorra",
"currencyCode": "EUR",
"population": "84000",
"capital": "Andorra la Vella",
"continentName": "Europe"
View hex-to-bgr.js
'#ff2233'.substr(1).match(/.{2}/g).reverse().join('')
@onigetoc
onigetoc / wp-ajax-loadmore.md
Created Oct 5, 2020 — forked from aslamdoctor/wp-ajax-loadmore.md
Wordpress - AJAX Load More Steps
View wp-ajax-loadmore.md

Step 1. Load more button

<?php
global $wp_query; // you can remove this line if everything works for you
 
// don't display the button if there are not enough posts
if (  $wp_query->max_num_pages > 1 )
	echo '<div class="misha_loadmore">More posts</div>'; // you can use <a> as well
?>
@onigetoc
onigetoc / app-code.js
Created Sep 29, 2020 — forked from timhudson/app-code.js
Scroll start/stop events using jQuery
View app-code.js
$(function() {
$(document).on('scrollstart', function() {
console.log('scroll started')
})
$(document).on('scrollend', function() {
console.log('scroll ended')
})
@onigetoc
onigetoc / providers.json
Created Sep 28, 2020 — forked from Niklan/providers.json
Copy of https://oembed.com/providers.json which blocked in Russia. Used for mirroring.
View providers.json
[
{
"provider_name": "23HQ",
"provider_url": "http:\/\/www.23hq.com",
"endpoints": [
{
"schemes": [
"http:\/\/www.23hq.com\/*\/photo\/*"
],
"url": "http:\/\/www.23hq.com\/23\/oembed"
@onigetoc
onigetoc / es7-async-await.js
Created Feb 13, 2020 — forked from msmfsd/es7-async-await.js
Javascript fetch JSON with ES7 Async Await
View es7-async-await.js
// Async/Await requirements: Latest Chrome/FF browser or Babel: https://babeljs.io/docs/plugins/transform-async-to-generator/
// Fetch requirements: Latest Chrome/FF browser or Github fetch polyfill: https://github.com/github/fetch
// async function
async function fetchAsync () {
// await response of fetch call
let response = await fetch('https://api.github.com');
// only proceed once promise is resolved
let data = await response.json();
// only proceed once second promise is resolved
View oembed_list.json
// https://oembed.com/providers.json
[{
"provider_name": "23HQ",
"provider_url": "http:\/\/www.23hq.com",
"endpoints": [{
"schemes": [
"http:\/\/www.23hq.com\/*\/photo\/*"
],
"url": "http:\/\/www.23hq.com\/23\/oembed"
}]