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 reload () { | |
STATUS=$(sudo apache2ctl configtest 2>&1) | |
OK=$(echo $STATUS | grep "OK" | wc -l) | |
if [[ $OK -eq 1 ]]; then | |
echo "reloading Apache..." | |
sudo service apache2 reload | |
else | |
echo "$STATUS" | |
LINEOF=$(echo "$STATUS" | grep -Eo "line ([0-9]+) of [^:]+") | |
if [ ! -z "$LINEOF" ]; then |
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/bash | |
DEB_FILE=/tmp/skype.deb | |
# remove old file if any | |
rm $DEB_FILE | |
# get download link | |
if [ -z "$1" ]; then | |
DOWNLOAD_LINK=https://go.skype.com/skypeforlinux-64.deb | |
else | |
DOWNLOAD_LINK="$1" |
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
location = /gotoapp { | |
if ($http_user_agent ~* "iphone|ipod|ipad|appletv") { | |
return 301 https://www.apple.com/lae/ios/app-store/; | |
} | |
if ($http_user_agent ~* "android") { | |
return 301 https://play.google.com/store; | |
} | |
if ($http_user_agent ~* "Windows") { | |
return 301 https://www.microsoft.com/store/apps?rtc=1; |
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
/* | |
* FancyBox - jQuery Plugin | |
* Simple and fancy lightbox alternative | |
* | |
* Examples and documentation at: http://fancybox.net | |
* | |
* Copyright (c) 2008 - 2010 Janis Skarnelis | |
* That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated. | |
* | |
* Version: 1.3.4 (11/11/2010) |
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($) { | |
"use strict"; | |
$.fn.aRise = function() { | |
// vars first of all | |
var links = this, total = this.length; | |
// add styles to head | |
$('head').append('<style type="text/css">#arise-div{position:absolute;top:20%;left:50%;cursor:pointer;background-color:#fff;border:1px #aaa solid;padding:2px 4px;border-radius:4px;}</style>'); | |
links.each(function(index) { | |
$(this).click(function(e) { | |
e.preventDefault(); |
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( $ ) { | |
$.fn.eaSlyder = function( millisec ) { | |
var $this = this, total = $this.length, cur = 0, timeout = millisec || 4000; | |
this.each(function(index) { | |
if (index) $(this).hide(); | |
}); | |
setInterval(function() { | |
$this.eq(cur).fadeOut(function() { | |
cur = ( cur == total-1 ) ? 0 : cur+1; | |
$this.eq(cur).fadeIn(); |