Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯
Focusing

Shahjahan Jewel techjewel

🎯
Focusing
View GitHub Profile
View Contract Killer 3.md

Contract Killer

The popular open-source contract for web designers and developers by Stuff & Nonsense

  • Originally published: 23/12/2008
  • Revised date: 15/12/2013
  • Original post

View gist:38ee2f0badf9d4e57978
<?php
$names = $_POST['name'];
$emails = $_POST['email'];
$user_array = array();
foreach($names as $key => $name)
{
$user_array[$key]['name'] = $name;
@techjewel
techjewel / simple_email_template.html
Created Mar 14, 2015
Very Simple email Template
View simple_email_template.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<style type="text/css">
body {
margin: 0;
mso-line-height-rule: exactly;
padding: 0;
min-width: 100%;
}
@techjewel
techjewel / tmpl.js
Last active Aug 29, 2015
Simple JS Templating
View tmpl.js
// Simple JavaScript Templating
// John Resig - http://ejohn.org/ - MIT Licensed
// source http://ejohn.org/blog/javascript-micro-templating/
(function(){
var cache = {};
this.tmpl = function tmpl(str, data){
// Figure out if we're getting a template, or if we need to
// load the template - and be sure to cache the result.
var fn = !/\W/.test(str) ?
@techjewel
techjewel / custom_posts.php
Created Nov 4, 2015
Creating Custom Post Type with Custom Taxanomy
View custom_posts.php
<?php
// Register Custom Post Type named FAQ
function wagon_faqs_post_type() {
$labels = array(
'name' => _x( 'CPAP FAQs', 'Post Type General Name', 'cpap' ),
'singular_name' => _x( 'CPAP FAQ', 'Post Type Singular Name', 'cpap' ),
'menu_name' => __( 'CPAP FAQs', 'cpap' ),
@techjewel
techjewel / ionicons_php_array.php
Last active Nov 20, 2015
PHP Array of ionicons icon pack
View ionicons_php_array.php
<?php
$ionicons_icons = array(
'ion-alert',
'ion-alert-circled',
'ion-android-add',
'ion-android-add-circle',
'ion-android-alarm-clock',
'ion-android-alert',
'ion-android-apps',
@techjewel
techjewel / wp-login-logo-change
Created Apr 20, 2013
wordpress custom login logo change function
View wp-login-logo-change
<?php
/* ------------------------------------------------
Custom login image logo
------------------------------------------------ */
function my_custom_login_logo() {
echo '<style type="text/css">
h1 a { background-image:url('.get_bloginfo('template_url').'/images/loginlogo.png) !important; }
</style>';
}
add_action('login_head', 'my_custom_login_logo');
@techjewel
techjewel / Get Featured image
Created Sep 8, 2013
WordPress Featured image
View Get Featured image
@techjewel
techjewel / Wordpress Sortcode use in PHP template
Created Sep 9, 2013
Use sortcode in wordpress template file
View Wordpress Sortcode use in PHP template
<?php echo do_shortcode("[shortcode]"); ?>
@techjewel
techjewel / g-chart-vertical-text.js
Created Oct 3, 2013
Google chart api for show lebel in vertical axix
View g-chart-vertical-text.js
var options = {
title: "Test",
hAxis: {
direction:-1,
slantedText:true,
slantedTextAngle:90 // here you can even use 180
}
};