Skip to content

Instantly share code, notes, and snippets.

@rohman
rohman / tamu_cari.php
Created April 16, 2013 10:23
Belajar TypeHead Bootstrap CI
<!DOCTYPE html>
<html lang="en">
<head>
<title>..:: Buku Tamu ::..</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Bootstrap -->
<link href="<?php echo $this->config->item('assets_url');?>css/bootstrap.css" rel="stylesheet" media="screen">
<script type="text/javascript" src="<?php echo base_url();?>js/jquery-1.8.2.js"></script>
<script type="text/javascript" src="<?php echo base_url();?>js/bootstrap.js"></script>
<script type="text/javascript">
@rohman
rohman / odbc_con.php
Created April 17, 2013 23:17
PHP ODBC Connection
<?php
$host = '127.0.0.1'; // ini merupakan hostnya
$db = 'databasenya';
$user = 'sa'; // user sql server
$pwd = 'sa'; // password sql server
//$dsn = "Driver={SQL Native Client};Server=$host;Database=$db; Uid=$user;Pwd=$pwd;";
// This is a more generic one I use with to dev with, Windows 7 and SQL Server 2008
$dsn = "Driver={SQL Server};Server=$host;Database=$db; Uid=$user;Pwd=$pwd;"; // only for dev. purposes
try{
@rohman
rohman / database.php
Created April 17, 2013 23:21
CodeIgniter ODBC Connection
<?php
$active_group = 'default';
$active_record = FALSE;
$db['default']['hostname'] = 'Driver={SQL Server};Server=127.0.0.1;Database=databasenya; Uid=sa;Pwd=sa;';
$db['default']['username'] = 'sa';
$db['default']['password'] = 'sa';
$db['default']['database'] = 'databasenya';
$db['default']['dbdriver'] = 'odbc';
$db['default']['dbprefix'] = '';
$db['default']['pconnect'] = FALSE;
<!DOCTYPE html>
<html>
<head>
<title>Angular Binding</title>
<link rel="stylesheet" href="assets/foundation/foundation.css" />
</head>
<body>
<div ng-app="">
<input type="text" ng-model="data.message" />
<h1>{{data.message + " World"}}</h1>
@rohman
rohman / angular_controllers.html
Created May 23, 2013 08:46
angular_controllers
<!DOCTYPE html>
<html>
<head>
<title>Angular Binding</title>
<link rel="stylesheet" href="assets/foundation/foundation.css" />
</head>
<body>
<div ng-app="">
<div ng-controller="FirstCtrl">
<h1>{{data.message + " World"}}</h1>
@rohman
rohman / main.js
Created May 23, 2013 08:49
angular main.js
function FirstCtrl($scope)
{
$scope.data = {message:"halow"}
}
@rohman
rohman / ng-filter.html
Created June 5, 2013 11:43
Contoh penggunaan ng-filter & ng-repeat
<!DOCTYPE html>
<html>
<head>
<title>Angular Binding</title>
<link rel="stylesheet" href="assets/foundation/foundation.css" />
</head>
<body>
<div ng-app="MyApp">
<div ng-controller="AvengerCtrl">
<input type="text" ng-model="search.$"/>
@rohman
rohman / composer
Created December 2, 2013 11:07
L4 Blog composer.json
{
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"require": {
"laravel/framework": "4.0.*",
"cartalyst/sentry": "2.0.*",
"dflydev/markdown": "v1.0.2",
"imagine/Imagine": "v0.4.1"
@rohman
rohman / CreateArticleTable.php
Last active December 30, 2015 00:09
L4 Blog Migration Create Article Table
<?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateArticlesTable extends Migration {
/**
* Run the migrations.
*
@rohman
rohman / CreatePagesTable.php
Last active December 30, 2015 00:09
L4 Blog Migration Create Pages Table
<?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreatePagesTable extends Migration {
/**
* Run the migrations.
*