This file contains hidden or 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
<script src="jquery.js"></script> | |
<script src="jquery.validate.js"></script> | |
<script src="jquery-ui.min.js"></script> | |
<link href="jquery-ui.css" rel="stylesheet"> | |
<!-- ////////////// --> | |
$('#select select').selectmenu( | |
{ | |
appendTo: "#select", | |
change: function( event, ui ) { |
This file contains hidden or 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
//http://xdsoft.net/jqplugins/datetimepicker/ | |
initDateTimePicker({mask:true, minuteRange:5,el:$('.date_hour_picker')}); | |
initDateTimePicker({mask:true, timepicker:false, format:'d/m/Y', el:$('.datepicker')}); | |
function initDateTimePicker(__arg__) | |
{ | |
$.datetimepicker.setLocale('pt-BR'); | |
var defaults = |
This file contains hidden or 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 | |
//https://davidwalsh.name/php-force-download | |
// grab the requested file's name | |
$file_name = 'pasta/file.pdf'; | |
// make sure it's a file before doing anything! | |
if(is_file($file_name)) { | |
/* | |
Do any processing you'd like here: |
This file contains hidden or 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
$.ajax({ | |
type:"POST", | |
beforeSend: function (request) | |
{ | |
request.setRequestHeader(API_NAME,X_API_KEY); | |
}, | |
url:URL, | |
processData: false, | |
dataType : "json", | |
data: "key=value&key=value", |
This file contains hidden or 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 | |
if(is_file($_GET['src'])) { | |
$file_name = $_GET['src']; | |
// required for IE | |
if(ini_get('zlib.output_compression')) { ini_set('zlib.output_compression', 'Off'); } | |
// get the file mime type using the file extension | |
switch(strtolower(substr(strrchr($file_name, '.'), 1))) { | |
case 'pdf': $mime = 'application/pdf'; break; | |
case 'zip': $mime = 'application/zip'; break; |
This file contains hidden or 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 | |
//namespace utils; | |
class Hash { | |
//------------------------------------------------------------------------// | |
var $key = "e7NjchMCEGgTpsx3mKXbVPiAqn8DLzWo_6.tvwJQ-R0OUrSak954fd2FYyuH~1lIBZ"; | |
public function __construct(/* ... */) { |
This file contains hidden or 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
$( _form ).serialize()+'&'+$.param({new:"some value"}); |
This file contains hidden or 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
$('.custom-select button').unbind('click').click(function(){ | |
$(this).closest('.custom-select').find('select').openSelect(); | |
return false; | |
}); | |
(function($) { | |
"use strict"; | |
$.fn.openSelect = function() | |
{ | |
return this.each(function(idx,domEl) { |