Skip to content

Instantly share code, notes, and snippets.

View naufdotal's full-sized avatar

Ariq Naufal naufdotal

View GitHub Profile
<?php
$links = array (
"http://www.nyomot.info/alasan-anda-wajib-pindah-windows-10/",
"http://www.nyomot.info/gambar-keindahan-flora-dan-fauna-madagaskar/",
"http://www.nyomot.info/periklanan-di-dunia-internet-akan-dikenakan-tarif-pajak/",
"http://www.nyomot.info/rahasia-cepat-diterima-google-adsense/",
"http://www.nyomot.info/5-macam-karakter-teman-sekolah-yang-paling-dikenal/",
"http://www.nyomot.info/tips-mengawali-hari-dengan-mood-baik-2/",
"http://www.nyomot.info/semakin-mudah-belanja-di-google-dengan-munculnya-tombol-beli/",
"http://www.nyomot.info/my-talking-tom-terbaru-v2-3-1-apk/",
@naufdotal
naufdotal / compile-nginx.sh
Last active December 7, 2016 13:23 — forked from tollmanz/compile-nginx.sh
Compile nginx with modules
./configure --prefix=/etc/nginx \
--sbin-path=/usr/sbin/nginx \
--conf-path=/etc/nginx/nginx.conf \
--error-log-path=/var/log/nginx/error.log \
--http-log-path=/var/log/nginx/access.log \
--pid-path=/var/run/nginx.pid \
--lock-path=/var/run/nginx.lock \
--http-client-body-temp-path=/var/cache/nginx/client_temp \
--http-proxy-temp-path=/var/cache/nginx/proxy_temp \
--http-fastcgi-temp-path=/var/cache/nginx/fastcgi_temp \
@naufdotal
naufdotal / gist:400197ee54dbf9df079c84b6851877f7
Created August 24, 2016 06:53 — forked from evansolomon/gist:2274120
nginx WordPress multisite config
server {
listen 80 default_server;
server_name domain.com *.domain.com;
root /srv/www/domain.com/public;
access_log /srv/www/domain.com/log/access.log;
error_log /srv/www/domain.com/log/error.log;
location / {
index index.php;
@naufdotal
naufdotal / ghost-nginx.conf
Created November 29, 2016 02:47
Ghost Configuration on nginx (proxy pass)
server {
listen 443 ssl http2; ## listen for ipv4; this line is default and implied
server_name www.sysmblo.com sysmblo.com;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $http_host;
proxy_pass http://***.***.***.115:1337;
}
#rewrite sysmblo jadi https://www.
@naufdotal
naufdotal / ghost
Created November 29, 2016 03:07
/etc/init.d/ghost
#! /bin/sh
### BEGIN INIT INFO
# Provides: ghost
# Required-Start: $network $syslog
# Required-Stop: $network $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Ghost Blogging Platform
# Description: Ghost: Just a blogging platform
### END INIT INFO
@naufdotal
naufdotal / Startup Command
Last active February 13, 2018 07:49
NGINX service file - startup
update-rc.d nginx defaults for Ubuntu 14.04
systemctl enable nginx.service for Centos 7
@naufdotal
naufdotal / interfaces
Last active February 6, 2018 16:20
networking kimsufi 1 ip NAT (/etc/network/)
# network interface settings; autogenerated
# Please do NOT modify this file directly, unless you know what
# you're doing.
#
# If you want to manage part of the network configuration manually,
# please utilize the 'source' or 'source-directory' directives to do
# so.
# PVE will preserve these directives, but will NOT its network
# configuration from sourced files, so do not attempt to move any of
# the PVE managed interfaces into external files!
<html>
<p style="width: 70%;margin: auto;margin-top: 5%;font-size:larger;text-align:center">
Download a file from any URL</p>
<form method="post" style="width: 70%;margin: auto;margin-top: 10%;">
<input name="url" size="50" placeholder="Source URL" style="width: 100%;height: 10%;font-size: 1.5em;padding:10px" required>
<input name="submit" type="submit" value="Download" style="width: 30%;height: 10%;margin: 5% auto; display: block;">
<p style="width: 70%;margin: auto;margin-top: 10%;font-size:larger;text-align:center">
To <?php echo getcwd(); ?></p>
<p style="width: 70%;margin: auto;font-size: smaller;text-align: center;position: fixed;bottom: 0;background: #fff;">
Powered by: <a href="https://karthikbhat.net/portfolio" target="_blank" style="color:#f60;text-decoration:none;">Karthik</a></p>
<?php
function my_customize_rest_cors() {
remove_filter( 'rest_pre_serve_request', 'rest_send_cors_headers' );
add_filter( 'rest_pre_serve_request', function( $value ) {
header( 'Access-Control-Allow-Origin: *' );
header( 'Access-Control-Allow-Methods: GET' );
header( 'Access-Control-Allow-Credentials: true' );
header( 'Access-Control-Expose-Headers: Link', false );
@naufdotal
naufdotal / 3d-fold-out-reveal.markdown
Last active January 25, 2020 15:55
3D Fold out reveal

3D Fold out reveal

Click to reveal more info. Info folds out beneath the card, while the rest of the grid recedes.

A Pen by Andrew Canham on CodePen.

License.