Hi
Im abit confused. I need to compare two dates.
The dates are stored as yyyy-mm-dd.
I have a function that works for this but it is yyyymmdd
This is fine and I was applying the strtotime function.
Problem is one of the dates I must pick up from an input box so Im using javascript.
I cant apply the php strtotime in javascript sure I cant?
So I was going to store the variable and change it in php but then realised that I cant pass a variable from Javascript to PHP
I'm now thinking hsould I apply a regualr expression to the date as I only need to remove - between yyy-mm-dd
Im not sure how to apply regular expressions though.
I was trying something like this but it doesnt work?
<script>
function change()
{
form=document.bookingFrm
booking_date=form.showing_date.value
boking_date $myString =~ t/-/ /;
}
</script>
Could anyone help me Please
Thank you