Skip to content
Checks if Cordova is running in a 12 or 24 hour time convention.
Objective-C JavaScript
Branch: master
Clone or download

Latest commit

Fetching latest commit…
Cannot retrieve the latest commit at this time.

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src/ios
www
LICENSE
README.md
plugin.xml

README.md

Check Time Convention

Checks if Cordova is running in a 12 (AM/PM) or 24 hour environment in iOS.

How To Use

Install the plugin to your project.

$ cordova plugin add https://github.com/tomskarning/cordova-ios-checktimeconvention

Call the plugin from your JavaScript.

	var success = function(is24h) {
		if (is24h === true) {
			alert("24 hours.");
			// Do what you want.
		} else if (is24h === false) {
			alert("12 hours.");
			// Do what you want.
		}
	}
    	
	var failure = function() {
		alert("Error calling CheckTimeConvention plugin!");
	}
	
	CheckTimeConvention.timeConvention(success, failure);
You can’t perform that action at this time.