This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>CRUD Petani Kode</title> | |
<link rel="icon" href="http://www.petanikode.com/favicon.ico" /> | |
</head> | |
<body> | |
<?php | |
// --- koneksi ke database |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module['exports'] = function petaniBot(hook) { | |
var request = require('request'); | |
request.post('https://api.telegram.org/bot' + hook.env.token_petani_bot + '/sendMessage') | |
.form({ | |
'chat_id': hook.params.message.chat.id, | |
'text': 'Anda mengirim: ' + hook.params.message.text | |
}); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module['exports'] = function iyanChanBot(hook) { | |
var request = require('request'); | |
var simiUrl = 'http://sandbox.api.simsimi.com/request.p?key=API_KEY_SIMSIMI&lc=id&ft=1.0&text='+hook.params.message.text; | |
request(simiUrl, function (error, response, body) { | |
if (!error && response.statusCode == 200) { | |
var data = JSON.parse(body); | |
request.post('https://api.telegram.org/bot' + hook.env.iyan_chan_bot + '/sendMessage') | |
.form({ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var x = 0; | |
var y = 0; | |
setInterval(function(){ | |
x -= 80 | |
if( x == -320){ | |
x = 0; | |
y -= 80; | |
} else { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>CSS Sprite</title> | |
<link rel="stylesheet" href="style.css" /> | |
</head> | |
<body> | |
<div class="sticker" id="stiker"></div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php defined('BASEPATH') OR exit('No direct script access allowed'); | |
/** | |
* CodeIgniter DomPDF Library | |
* | |
* Generate PDF's from HTML in CodeIgniter | |
* | |
* @packge CodeIgniter | |
* @subpackage Libraries | |
* @category Libraries |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.petanikode.cobagooglemaps; | |
import android.os.AsyncTask; | |
import android.support.v4.app.FragmentActivity; | |
import android.os.Bundle; | |
import android.util.Log; | |
import android.widget.Toast; | |
import com.google.android.gms.maps.CameraUpdateFactory; | |
import com.google.android.gms.maps.GoogleMap; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#AND | |
<b:if cond='data:blog.pageType == "index"'> | |
<b:if cond='data:blog.searchQuery'> | |
<!--search_page AND index_page--> | |
</b:if> | |
</b:if> | |
#OR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Helpher untuk mencetak tanggal dalam format bahasa indonesia | |
* | |
* @package CodeIgniter | |
* @category Helpers | |
* @author Ardianta Pargo (ardianta_pargo@yhaoo.co.id) | |
* @link https://gist.github.com/ardianta/ba0934a0ee88315359d30095c7e442de | |
* @version 1.0 | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- phpMyAdmin SQL Dump | |
-- version 4.5.4.1deb2ubuntu2 | |
-- http://www.phpmyadmin.net | |
-- | |
-- Host: localhost | |
-- Generation Time: Nov 26, 2016 at 10:39 PM | |
-- Server version: 5.7.16-0ubuntu0.16.04.1 | |
-- PHP Version: 7.0.8-0ubuntu0.16.04.3 | |
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; |