Skip to content

Instantly share code, notes, and snippets.

View jrvaja's full-sized avatar

Jaimin Vaja jrvaja

  • Adjust GmbH
  • Berlin, Germany
View GitHub Profile
<script type="text/javascript" src="/js/jquery.complexify.js"></script>
<script type="text/javascript">
$("#password").complexify(options, callback(valid, complexity){
alert("Password complexity: " + complexity);
});
</script>
@jrvaja
jrvaja / php_temp.php
Created June 19, 2012 03:44
jrphpSnippet
<!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>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>
<body>
</body>
</html>
@jrvaja
jrvaja / css_temp.css
Created June 21, 2012 03:06
CSS : Reset
@charset "utf-8";
/* CSS Document */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, font, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
@jrvaja
jrvaja / Fileupload
Created June 21, 2012 05:04
Snippet: FileUpload
/********************************
HTML
*********************************/
<div class="upldFile">
<p class="set16p">Upload a new photo</p>
<input type="text" name="broFile" class="text-input button" value="" style="display: inline; width: 300px;">
<div class="inputType-file">
<input class="file_1" type="file" size="1"/>
</div>
<p class="set16p sand">Acceptable image formats: jpg, png, and gif • Image size must be less than 200KB. </p>
@jrvaja
jrvaja / MultipleChoiseStyle
Created June 21, 2012 05:10
Snippet:MultipleChoiseStyle
/********************************************
Select Multiple Style-HTML
*******************************************/
<div class="setbgToSelector">
<select name="" id="" class="selector-que">
<option value="MultipleChoise">MultipleChoise</option>
</select>
</div>
/********************************************
Select Multiple Style-CSS
@jrvaja
jrvaja / Accordion
Created June 21, 2012 05:12
Snippet:Accordion
/*************************************************
Accordion
*************************************************/
$('dd').filter(':nth-child(n+4)').addClass('hide');
// $('dd').addClass('hide');
$('dl').on('click','dt',function(){
$(this)
.next()
.slideDown(600)
.siblings('dd')
@jrvaja
jrvaja / HeaderMenu
Created June 21, 2012 05:16
Snippet:HeaderMenu
/*************************************************
Header Menu jQuerey-Active/Hover
*************************************************/
<div class="header-l-menu">
<ul class="menu-list">
<li><a href="#" class="radius">Overview</a></li>
<li><a href="#" class="radius">Projects</a></li>
<li><a href="#" class="radius">People</a></li>
<li><a href="#" class="radius">Process</a></li>
</ul>
@jrvaja
jrvaja / configServer
Created June 25, 2012 11:01
CodeIgniter: ServerRoot
$config['server_root']=$_SERVER['DOCUMENT_ROOT'];
@jrvaja
jrvaja / mailAttachmnetsCode
Created June 25, 2012 11:48
CodeIgniter:mailAttachmnetsCode
$path=$this->config->item('server_root');
$file=$path.'/CI25_06_2012/attachments/informa.txt';
$this->email->attach($file);
@jrvaja
jrvaja / model_activeRecords1
Created June 27, 2012 07:04
CodeIgnite:model_activeRecords1
class Site_model extends CI_Model {
//Select all
function get_records(){
$query=$this->db->get('data');
return $query->result();
}
//Add Record
function add_record(){
$data=array(
'title'=>$this->input->post('title'),