Skip to content

Instantly share code, notes, and snippets.

View marjanbonus's full-sized avatar

Marjan Bonus marjanbonus

  • Osijek, Croatia
View GitHub Profile
@marjanbonus
marjanbonus / target safari-ie
Last active August 29, 2015 14:13
Target Safari only
if (navigator.userAgent.indexOf('Safari') != -1 && navigator.userAgent.indexOf('Chrome') == -1) {
console.log("Safari!");
}
if (!!navigator.userAgent.match(/Trident\/7\./)) {
console.log("IE!!!");
}
@marjanbonus
marjanbonus / custom-select.html
Created October 8, 2014 16:49
HTML select element custom arrow
<!DOCTYPE html>
<html>
<head>
<title>custom select</title>
<style>
.container-width { width: 135px; }
.select-wrapper {
overflow: hidden;
background: url('https://cdn2.iconfinder.com/data/icons/picol-vector/32/arrow_sans_down-16.png') no-repeat 108px 7px;
border: 1px solid #888;
@marjanbonus
marjanbonus / mage-script.sh
Created July 18, 2014 12:04
Magento & Waterlee boilerplate auto install via ssh
#!/bin/bash
# Magento & Waterlee boilerplate auto install (auto prepare for web-based installation process)
# Just change in script mysql username and password and that's it
# This is a script with two parameters, first for magento folder name and second for database name
# Simply run in command-line with './mage-script.sh folder_name database_name'
clear
echo "Magento&Waterlee auto install."
wget http://www.magentocommerce.com/downloads/assets/1.9.0.1/magento-1.9.0.1.tar.gz
tar -zxvf magento-1.9.0.1.tar.gz
mv magento $1