View host_docker_ip.txt
This file contains 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
This is in `host.docker.internal` hostname and `172.17.0.1` IP for Linux in default network. |
View backup.sh
This file contains 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
#!/bin/sh | |
#set -x | |
INSTANCIA=$1 | |
TODAY=$(date -I) | |
### ------------------------------------------------------------ |
View app_gettext.sh
This file contains 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
APP_ROOT=$1 | |
if [ $# == 2 ] | |
then | |
echo "error: app path?" | |
fi |
View scripts.js
This file contains 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
(function($) { | |
jQuery.fn.html5_upload = function(options) { | |
var available_events = ['onStart', 'onStartOne', 'onProgress', 'onFinishOne', 'onFinish', 'onError']; | |
var options = jQuery.extend({ | |
onStart: function(event, total) { |
View info.md
Si has añadido una regla :before o :after y parece que no toma los estilos es porque para que estos se necesita el atributo content aunque sea vacío. Es decir:
div.miclase:before {
content: '';
}
View scripts.js
This file contains 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
trasweb = trasweb | {}; | |
trasweb.getSize = function () { | |
var w = window, | |
d = document, | |
e = d.documentElement, | |
g = d.getElementsByTagName('body')[0], | |
x = w.innerWidth || e.clientWidth || g.clientWidth, | |
y = w.innerHeight || e.clientHeight || g.clientHeight; |
View scripts.js
This file contains 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
trasweb.getPosition = function (el) { | |
var xPos = 0; | |
var yPos = 0; | |
while (el) { | |
if (el.tagName === "BODY") { | |
// deal with browser quirks with body/window/document and page scroll | |
var xScroll = el.scrollLeft || document.documentElement.scrollLeft; | |
var yScroll = el.scrollTop || document.documentElement.scrollTop; |
View scripts.js
This file contains 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
/** Basado en: https://stackoverflow.com/questions/15040408/achieving-min-width-with-viewport-meta-tag */ | |
document.addEventListener('DOMContentLoaded', function () { | |
trasweb.orientationchange(); | |
}); | |
trasweb.orientationchange = function (force_orientation) { | |
var vp = document.getElementById('viewport'); | |
var orientation = window.orientation; | |
var is_desktop = document.body.classList.contains('desktop'); |
View scripts.js
This file contains 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
/** | |
Alternativa de menos de 1kb: https://apoorv.pro/lozad.js/demo/ | |
*/ | |
document.addEventListener('DOMContentLoaded', function () { | |
var bLazy = new Blazy({ | |
src: 'data-src', | |
selector: '*[data-src]', | |
offset: 500, | |
breakpoints: [ |
NewerOlder