Skip to content

Instantly share code, notes, and snippets.

View pablocattaneo's full-sized avatar

Pablo Cattaneo pablocattaneo

View GitHub Profile
@pablocattaneo
pablocattaneo / fix-admin.localhost.mysql
Created October 3, 2015 04:02
Fix admin access Magento local host. Correr el script en la base de datos de Magento. http://www.iugo.com.uy/blog/magento-no-puedo-entrar-al-admin-solucionado/
UPDATE core_config_data SET value="http://127.0.0.1/mitienda" WHERE path IN ('web/unsecure/base_url','web/secure/base_url') ;
@pablocattaneo
pablocattaneo / new_gist_file_0
Created October 6, 2015 20:04
Seleccionar por color en Photoshop
http://photo.stackexchange.com/questions/15495/how-do-i-select-all-pixels-that-match-an-exact-color-value-in-adobe-photoshop
You can use the Magic Wand Tool with the following setting:
Tolerance: 0
Anti-alias: unchecked
Contiguous: unchecked
Sample All Layers: *checked or unchecked* (See below)
The Magic Wand Tool also uses the "Sample Size" settings from the Eye Dropper tool, so you will have to switch to that tool and make sure it is set to "Point Sample" before using the Magic Wand Tool. Otherwise you could end up selecting more colors than you intended.
@pablocattaneo
pablocattaneo / new_gist_file.mysql
Created October 9, 2015 00:03
Conocer el tamaño de la base de datos Mysqlo.
SELECT table_schema "Data Base Name",
sum( data_length + index_length ) / 1024 / 1024 "Data Base Size in MB",
sum( data_free )/ 1024 / 1024 "Free Space in MB"
FROM information_schema.TABLES
GROUP BY table_schema ;
@pablocattaneo
pablocattaneo / htaccess
Last active September 16, 2017 00:12
Enable the Apache mod_rewrite module. Enable the ReWriteEngine in the mod_rewrite module.
Options +FollowSymLinks
RewriteEngine on
@pablocattaneo
pablocattaneo / htaccess
Created October 9, 2015 04:21
Redirect all the site via redirect 301 ([R=301,L])
# Always use https for secure connections
# Replace 'www.example.com' with your domain name
# (as it appears on your SSL certificate)
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://www.example.com/$1 [R=301,L]
@pablocattaneo
pablocattaneo / custom Form
Last active September 16, 2017 00:11
Custom Formularios, checkbox, radiobuttons: http://screwdefaultbuttons.com/
http://screwdefaultbuttons.com/
.clearfix:before,
.clearfix:after{
content: " ";
display:table;
}
.clearfix:after{
clear:both;
}
@pablocattaneo
pablocattaneo / ie-hack.styl
Created November 11, 2015 13:33
Css Hack for Internet Explorer
@media screen and (min-width unquote('0\0'))
/* Tus estilos CSS para IE9, IE10, IE11 */
.form-signin img.v-icon
height 281px
@pablocattaneo
pablocattaneo / loop.js
Created November 12, 2015 02:24
Loop Jquery. Toma cada elemento y los trabaja como individuales.
$(".cvElementTitle").each(function(){
$(this).click(function() {
$(this).next('.cvElementContent').slideToggle( "slow" );
});
});
@pablocattaneo
pablocattaneo / toggle.css
Created November 14, 2015 18:21
Toggle slider
.cvElement.open i.fa-arrow-circle-right,
.cvElement i.fa-arrow-circle-down{
display: none;
}
.cvElement.open .fa-arrow-circle-down,
.fa-arrow-circle-right{
display: inline-block;
}