Login
Username:

Password:

Remember me



Lost Password?

Register now!
Main Menu
WFDownloads is developed by The SmartFactory (http://www.smartfactory.ca), a division of InBox Solutions (http://www.inboxsolutions.net)

Spectrum Color Picker Theme Change for VamShop 2

Spectrum Color Picker Theme Change for VamShop 2.

How to install
1. Copy files from archive.
2. Open Admin - Layout - Templates - Main Layout, after
{bender src="{base_path}/css/jquery/plugins/colorbox/colorbox.css"}
add:
{bender src="{base_path}/css/jquery/plugins/color-picker/spectrum.css"}

after:
{bender src="{base_path}/js/jquery/plugins/colorbox/jquery.colorbox-min.js"}

add:
{bender src="{base_path}/js/jquery/plugins/jquery.cookie.js"}
{bender src="{base_path}/js/jquery/plugins/color-picker/spectrum.js"}

And add this code to the most suitable place:
<input id="color-picker" />

3. Add this code to /app/webroot/js/vamshop.js

// Color Picker

function updateColors(color) {
var col = "transparent";
if(color) {
col = color.toHexString();
}
if(color != $.cookie("vamshop-color")) {
$.cookie("vamshop-color", color.toHexString(), { expires: 30, path: '/' })
}
$(".navbar-default").css("background", col);
$(".navbar-default .navbar-collapse").css("border-color", col);
$(".navbar-default .navbar-form").css("border-color", col);
$(".btn-warning").css({"background": col,"border": "1px solid "+col});
$(".btn-warning.checkout").css("background", col);
$(".featured-categories .thumbnail .title").css("background", col);
$(".shop-products .thumbnail .price").css("background", col);
}

$(function() {

var col = "transparent";

if(typeof $.cookie("vamshop-color") != "undefined"){
col = $.cookie("vamshop-color");
}
$(".navbar-default").css("background", col);
$(".navbar-default .navbar-collapse").css("border-color", col);
$(".navbar-default .navbar-form").css("border-color", col);
$(".btn-warning").css({"background": col,"border": "1px solid "+col});
$(".btn-warning.checkout").css("background", col);
$(".featured-categories .thumbnail .title").css("background", col);
$(".shop-products .thumbnail .price").css("background", col);

if (!col) { var col = "#ff6633";}

$("#color-picker").spectrum({
allowEmpty:true,
color: col,
showInput: true,
showButtons: false,
showInitial: true,
showPalette: true,
showSelectionPalette: true,
hideAfterPaletteSelect:true,
clickoutFiresChange: true,
showAlpha: true,
preferredFormat: "hex",
localStorageKey: "vamshop",
move: function (color) {
updateColors(color);
},
show: function () {
},
beforeShow: function () {
},
hide: function (color) {
updateColors(color);
},
palette: [
["rgb(255, 102, 51)", "rgb(0, 129, 194)", "rgb(26, 177, 36)", "rgb(208, 22, 22)", "rgb(210, 193, 82)", "rgb(163, 163, 163)", "rgb(85, 85, 85)"]
]
});

});

4. Reset cache files at Admin - Configurations - Store Settings - Reset Cache button at bottom right.
5. Delete /app/webroot/css/vamshop-packed.css file.


Support http://support.vamshop.com

  • Please do not vote for the same resource more than once.
  • The scale is 1 - 10, with 1 being poor and 10 being excellent.
  • Please be objective, if everyone receives a 1 or a 10, the ratings aren't very useful.
  • Do not vote for your own resource.
Rate resource
Review rating*

VamShop Facebook VamShop Twitter VamShop RSS