class Database
{
private $host = "localhost";
private $db_name = "mydb";
private $username = "root";
private $password = "";
public $conn;
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 | |
function u($string="") { | |
return urlencode($string); | |
} | |
function raw_u($string="") { | |
return rawurlencode($string); | |
} | |
function h($string="") { |
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
// Jquery Version | |
$(function () { | |
$.getJSON('api', updateFeedback); | |
$('.feedback-form').submit(function (e) { | |
e.preventDefault(); | |
$.post('api', { | |
name: $('#feedback-form-name').val(), | |
title: $('#feedback-form-title').val(), | |
message: $('#feedback-form-message').val() |
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
# From Kal Skills Teaching procces on cloning a existing repository or want to colaborate with it | |
git clone - clone a repository | |
cd - change directory | |
ls - list directory | |
git status - mostly for verification | |
git add filename | |
git commit -m "waht ever message here" | |
git push | |
upstream |
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
-- 02 JOIN | |
-- test.db | |
-- join example tables, left and right | |
CREATE TABLE left ( id INTEGER, description TEXT ); | |
CREATE TABLE right ( id INTEGER, description TEXT ); | |
INSERT INTO left VALUES ( 1, 'left 01' ); | |
INSERT INTO left VALUES ( 2, 'left 02' ); | |
INSERT INTO left VALUES ( 3, 'left 03' ); |