Skip to content

Instantly share code, notes, and snippets.

@phpleo
phpleo / buscar_comentarios.sql
Created July 21, 2011 14:43
TSQL Stored Proceures
SELECT 'sp_helptext ' + name
FROM sysobjects o
INNER JOIN syscomments c ON (o.id = c.id)
WHERE
TEXT LIKE '%reemplazar_el_nombre%'
@phpleo
phpleo / 1.sh
Created July 10, 2011 03:52
Configurando php en ubuntu
$ sudo gedit /etc/php5/cgi/php.ini
@phpleo
phpleo / 0_php_cli.sh
Created July 10, 2011 03:35
Instalando de php y librerias en ubuntu
# instalando php y pear para usarn en terminal
$ sudo apt-get install php5-cli php-pear
@phpleo
phpleo / ubuntu.sh
Created July 10, 2011 01:36
Editando archivos hosts
$ sudo gedit /etc/hosts
@phpleo
phpleo / cherokee-admin.sh
Created July 10, 2011 00:46
Comandos en Cherokee server
$ sudo cherokee-admin -u
@phpleo
phpleo / 1.sh
Created July 9, 2011 06:39
Instalando cherokee server en Ubuntu por terminal con la PPA
$ sudo add-apt-repository ppa:cherokee-webserver/ppa
$ sudo apt-get update && sudo apt-get install cherokee
@phpleo
phpleo / gist:1067849
Created July 6, 2011 17:42
Select en stored procedure
-- http://stackoverflow.com/questions/653714/how-to-select-into-temp-table-from-stored-procedure
declare @temp table
(
name varchar(255),
field varchar(255),
filename varchar(255),
filegroup varchar(255),
size varchar(255),
maxsize varchar(255),
growth varchar(255),
@phpleo
phpleo / gist:1053272
Created June 29, 2011 06:33
Instalar JDownloader Ubuntu 11.04
sudo add-apt-repository ppa:jd-team/jdownloader
sudo apt-get update && sudo apt-get install jdownloader
@phpleo
phpleo / gist:1010313
Created June 6, 2011 14:02
Recorer checkbox en gridview
// http://www.codeproject.com/KB/webforms/SelChkboxesDataGridView.aspx
for (int i = 0; i < GridView1.Rows.Count; i++)
{
GridViewRow row = GridView1.Rows[i];
bool isChecked = ((CheckBox) row.FindControl("chkSelect")).Checked;
if (isChecked)
{
// Column 2 is the name column
@phpleo
phpleo / 1.js
Created January 11, 2011 16:21
Para que MeioMask acepte () espacio y - sin quitarlos del campo de texto
// http://www.meiocodigo.com/projects/meiomask/
// alterando la configuracion de meio mask para
// usar () espacio y - en las cajas de texto
$.mask.options = {
attr: 'alt', // an attr to look for the mask name or the mask itself
mask: null, // the mask to be used on the input
type: 'fixed', // the mask of this mask
maxLength: -1, // the maxLength of the mask
defaultValue: '', // the default value for this input