I am having trouble on passing time interval to javascript. The time interval is formatted using minus sign (Eg. 10-11 means from 10 to 11 AM/PM doesn't matter).
In markup I have something like this.
<? $mytime = '10-11';?>
<a href="" onclick="checkTime($mytime)"></a>
In Javascript I have this
function checkTime(mytime) {
console.log(mytime);
}
Console window show -1. i need to have the same string I passed. What should I do.