Skip to content

Instantly share code, notes, and snippets.

@arodu
arodu / country_select.html
Last active May 24, 2024 22:09
Select HTML de paises
<select name="country" class="form-control">
<option value="">Country</option>
<option value="AF">Afghanistan</option>
<option value="AL">Albania</option>
<option value="DZ">Algeria</option>
<option value="AS">American Samoa</option>
<option value="AD">Andorra</option>
<option value="AO">Angola</option>
<option value="AI">Anguilla</option>
<option value="AR">Argentina</option>
@arodu
arodu / countries_array.php
Last active September 24, 2015 17:23
countries list php array
<?php
$countries = array(
'AF'=>'Afghanistan',
'AL'=>'Albania',
'DZ'=>'Algeria',
'AS'=>'American Samoa',
'AD'=>'Andorra',
'AO'=>'Angola',
'AI'=>'Anguilla',
'AR'=>'Argentina',
@arodu
arodu / .bashrc
Last active August 21, 2016 16:56
Consola bash con soporte para git, en colores y en blanco, agregar este codigo al final del archivo ~/.bashrc
[ -r /usr/share/bash-completion/bash_completion ] && . /usr/share/bash-completion/bash_completion
. /usr/share/git/completion/git-completion.bash
. /usr/share/git/completion/git-prompt.sh
export GIT_PS1_SHOWDIRTYSTATE=1
PS1='\[\033[01;32m\][\u@\h\[\033[01;37m\] \W\[\033[01;32m\]]\[\033[01;37m\]$(__git_ps1 "(%s)")\[\033[01;32m\]\$\[\033[00m\] '
#PS1='\u@\h \W $(__git_ps1 " (%s)")\$ '
@arodu
arodu / ImgMinComponent.php
Last active September 24, 2015 17:22
Componente para crear thumbnails en cakephp 2.x
<?php
App::uses('Component', 'Controller');
class ImgMinComponent extends Component {
public $settings = array(
'min_ancho_max' => 198,
'min_alto_max' => 100,
'min_nombre' => 'min',
'tipo_nombre'=>'back', // front, back
'tipo'=>'proporcion', // proporcion,estrechar,corte
@arodu
arodu / codes_select.html
Created September 24, 2015 17:22
Select html de lenguajes de Programacion
<select name="codes">
<option value="as">ActionScript</option>
<option value="ada">Ada</option>
<option value="apacheconf">Apache config</option>
<option value="apl">APL</option>
<option value="applescript">AppleScript</option>
<option value="awk">Awk</option>
<option value="bash">Bash</option>
<option value="console">Bash session</option>
<option value="bat">Batchfile</option>
@arodu
arodu / Operaciones-Git
Created October 16, 2015 19:48 — forked from jelcaf/Operaciones-Git
Git Tips - Mini-trucos de Git para facilitarme la tarea
#############################################
# Push de la rama actual
git push origin $rama_actual
#############################################
# Volver a un commit anterior, descartando los cambios
git reset --HARD $SHA1
#############################################
# Ver y descargar Ramas remotas
@arodu
arodu / timezone_select.html
Last active October 17, 2015 13:08
TimeZone list select html
<select name="timezone">
<option value="Pacific/Midway">(UTC-11:00) Midway Island, American Samoa</option>
<option value="Pacific/Honolulu">(UTC-10:00) Hawaii</option>
<option value="America/Anchorage">(UTC-08:00) Alaska</option>
<option value="America/Tijuana">(UTC-07:00) Baja California</option>
<option value="America/Los_Angeles">(UTC-07:00) Pacific Time (US and Canada)</option>
<option value="America/Phoenix">(UTC-07:00) Arizona</option>
<option value="America/Chihuahua">(UTC-06:00) Chihuahua, La Paz, Mazatlan</option>
<option value="America/Denver">(UTC-06:00) Mountain Time (US and Canada)</option>
<option value="America/Belize">(UTC-06:00) Central America</option>
@arodu
arodu / timezone_list.csv
Last active October 3, 2024 02:28
timezone_list.csv
TimeZone UTC offset name
Pacific/Midway UTC-11:00 Midway Island, American Samoa
Pacific/Honolulu UTC-10:00 Hawaii
America/Anchorage UTC-08:00 Alaska
America/Tijuana UTC-07:00 Baja California
America/Los_Angeles UTC-07:00 Pacific Time US and Canada)
America/Phoenix UTC-07:00 Arizona
America/Chihuahua UTC-06:00 Chihuahua, La Paz, Mazatlan
America/Denver UTC-06:00 Mountain Time US and Canada)
America/Belize UTC-06:00 Central America
@arodu
arodu / cakephp_pagination_bootstrap.php
Created May 30, 2016 18:42
cakephp_pagination_bootstrap.php
<div class="pagination pagination-large">
<ul class="pagination">
<?php
echo $this->Paginator->prev(__('prev'), array('tag' => 'li'), null, array('tag' => 'li','class' => 'disabled','disabledTag' => 'a'));
echo $this->Paginator->numbers(array('separator' => '','currentTag' => 'a', 'currentClass' => 'active','tag' => 'li','first' => 1));
echo $this->Paginator->next(__('next'), array('tag' => 'li','currentClass' => 'disabled'), null, array('tag' => 'li','class' => 'disabled','disabledTag' => 'a'));
?>
</ul>
</div>
@arodu
arodu / app.css
Created May 30, 2016 19:04
Add directional to cakephp paginator sort
th a.asc:after {
content: ' ⇣';
}
th a.desc:after {
content: ' ⇡';
}