Skip to content

Instantly share code, notes, and snippets.

View ardianta's full-sized avatar
👋
hi!

Ahmad Muhardian ardianta

👋
hi!
View GitHub Profile
@derekdreery
derekdreery / ActiveRecord Tutorial.md
Last active August 29, 2015 13:56
ActiveRecord Tutorial

Groupoffice ActiveRecord Tutorial

License

This document has no copyright protection whatsoever and you are free to do as you please with it. I don't take any responsibility for anything you do with this information though.

Introduction

The groupoffice ActiveRecord.php is a custom implementation of the [active record pattern][1] commonly used for database access from web applications. The system can seem complex and daunting at first, but as you get to know it you will find the time-saving features very helpful.

I may extend this to be a tutorial of the whole of groupoffice eventually.

This tutorial assumes you have a basic understanding of the groupoffice class autoloader and router. I give a quick recap below:

@eliangcs
eliangcs / http-prompt-story.md
Last active June 3, 2020 06:49
How I created HTTP Prompt and got 5000+ stars on GitHub

How I Created HTTP Prompt and Got 5000+ Stars on GitHub

Two months ago, I published an open source project, which went viral by gaining 1200+ stars in the first 24 hours. As of this writing, it has attracted 5000+ stars. The project is called HTTP Prompt:

https://github.com/eliangcs/http-prompt

Here I want to share its development story.

It all began with Vertica. Not long ago, I used Vertica every day for my work. Vertica is a powerful database, but the official client (vsql) is not powerful at all. The GUI alternative, DbVisualizer, is bad as well.

@DaveHudson
DaveHudson / apple-touch-startup-image.html
Last active January 19, 2021 08:50
PWA apple-touch-startup-image iOS
<link rel="apple-touch-startup-image" href="images/splash/launch-640x1136.png" media="(device-width: 320px) and (device-height: 568px) and (-webkit-device-pixel-ratio: 2) and (orientation: portrait)">
<link rel="apple-touch-startup-image" href="images/splash/launch-750x1294.png" media="(device-width: 375px) and (device-height: 667px) and (-webkit-device-pixel-ratio: 2) and (orientation: portrait)">
<link rel="apple-touch-startup-image" href="images/splash/launch-1242x2148.png" media="(device-width: 414px) and (device-height: 736px) and (-webkit-device-pixel-ratio: 3) and (orientation: portrait)">
<link rel="apple-touch-startup-image" href="images/splash/launch-1125x2436.png" media="(device-width: 375px) and (device-height: 812px) and (-webkit-device-pixel-ratio: 3) and (orientation: portrait)">
<link rel="apple-touch-startup-image" href="images/splash/launch-1536x2048.png" media="(min-device-width: 768px) and (max-device-width: 1024px) and (-webkit-min-device-pixel-ratio: 2) and (orientation: portrait)">
<lin
@banghasan
banghasan / PertamaBot.php
Last active December 23, 2022 14:52
Sample Bot Telegram - PHP
<?php
/*
BOT PENGANTAR
Materi EBOOK: Membuat Sendiri Bot Telegram dengan PHP
Ebook live http://telegram.banghasan.com/
oleh: bang Hasan HS
@oliverdoetsch
oliverdoetsch / AND_OR_NOT
Last active January 22, 2023 17:03
Blogger: Globally conditional data tags for all page types
#AND
<b:if cond='data:blog.pageType == "index"'>
<b:if cond='data:blog.searchQuery'>
<!--search_page AND index_page-->
</b:if>
</b:if>
#OR
@jnrbsn
jnrbsn / better-gist-styles.css
Created September 14, 2010 01:24
Better styles for embedding GitHub Gists
/* Better styles for embedding GitHub Gists */
.gist{font-size:13px;line-height:18px;margin-bottom:20px;width:100%}
.gist pre{font-family:Menlo,Monaco,'Bitstream Vera Sans Mono','Courier New',monospace !important}
.gist-meta{font-family:Helvetica,Arial,sans-serif;font-size:13px !important}
.gist-meta a{color:#26a !important;text-decoration:none}
.gist-meta a:hover{color:#0e4071 !important}
@gasman
gasman / encode.py
Created October 25, 2020 12:23
Encoding a file as a Youtube video - https://www.youtube.com/watch?v=hyqLv2_zBdA
# Encode inputfile.tar.gz as a series of video frames
# Frames are written to frames/frameNNNN.png
from PIL import Image
with open('inputfile.tar.gz', 'rb') as f:
data = f.read()
WIDTH = 120
HEIGHT = 90
CHUNK_SIZE = int((WIDTH * HEIGHT) / 8)
@callumacrae
callumacrae / build-tools.md
Last active October 25, 2023 15:14
Build tools written in JavaScript
@kra3
kra3 / eq.preset
Created March 26, 2014 12:11
Audacious presets: ~/.config/audacious/eq.preset
[Presets]
Preset0=Classical
Preset1=Club
Preset2=Dance
Preset3=Flat
Preset4=Live
Preset5=Laptop Speakers/Headphone
Preset6=Rock
Preset7=Pop
@ardianta
ardianta / json-ld-blogger.xml
Last active April 4, 2024 14:09
Valid JSON-LD for Blogger
<script type="application/ld+json">
{ "@context": "http://schema.org",
"@type": "BlogPosting",
"headline": "<data:post.title/>",
"alternativeHeadline": "<data:post.title/>",
"mainEntityOfPage" : "<data:blog.homepageUrl/>",
"image": {
"@type" : "imageObject",
"url" : "<data:post.firstImageUrl/>",
"height": "480",