function saveSetting(settingName, settingValue){
	// Use Chrome cloud storage where available (will sync across multiple computers).
	if(useChromeStorage()){
		var objectToPersist = {}; // can't use an object-literal to do it, or chrome will make an object whose key is literally 'settingName'
		objectToPersist[settingName] = settingValue;
		chrome.storage.sync.set(objectToPersist, function() {
			// console.log("Chrome saved " + settingName + ".");
		});
	} else if(typeof(Storage) !== "undefined"){
		localStorage[settingName] = settingValue;
	} else {
		// No LocalStorage support... use cookies instead.
		setCookie(settingName, settingValue);
	}
} // end saveSetting()
/**
 * Saves the Setting (defined by 'settingName') to be whatever is in 'settingValue'.
 *
 * This will use Chrome cloud-storage if available, then will fall back to LocalStorage
 * if possible and fall back to cookies otherwise.
 *
 * NOTE: Remember to enver store confidential or user information in Chrome cloud
 * storage (it's not encrypted).
 */
Saves the Setting (defined by 'settingName') to be whatever is in 'settingValue'.
This will use Chrome cloud-storage if available, then will fall back to LocalStorage
if possible and fall back to cookies otherwise.

Remember to enver store confidential or user information in Chrome cloud
storage (it's not encrypted).
Saves the Setting ( defined by ' settingName ' ) to be whatever is in ' settingValue ' . This will use Chrome cloud - storage if available then will fall back to LocalStorage if possible and fall back to cookies otherwise . Remember to enver store confidential or user information in Chrome cloud storage ( it ' s not encrypted ) .
function saveSetting(settingName, settingValue){
	if(useChromeStorage()){
		var objectToPersist = {}; 
		objectToPersist[settingName] = settingValue;
		chrome.storage.sync.set(objectToPersist, function() {
		});
	} else if(typeof(Storage) !== "undefined"){
		localStorage[settingName] = settingValue;
	} else {
		setCookie(settingName, settingValue);
	}
} 
function saveSetting ( settingName , settingValue ) { if ( useChromeStorage ( ) ) { var objectToPersist = { } ; objectToPersist [ settingName ] = settingValue ; chrome . storage . sync . set ( objectToPersist , function ( ) { } ) ; } else if ( typeof ( Storage ) !== "undefined" ) { localStorage [ settingName ] = settingValue ; } else { setCookie ( settingName , settingValue ) ; } }
Saves the Setting (defined by 'settingName') to be whatever is in 'settingValue'.
Saves the Setting ( defined by ' settingName ' ) to be whatever is in ' settingValue ' .
// Use Chrome cloud storage where available (will sync across multiple computers). // can't use an object-literal to do it, or chrome will make an object whose key is literally 'settingName' // console.log("Chrome saved " + settingName + "."); // No LocalStorage support... use cookies instead. // end saveSetting()