MySQL UPDATE with INNER JOIN and Subquery Optimisation
Recently working on a project I discovered and learnt something new so I thought I would share it amongst everyone.
Recently working on a project I discovered and learnt something new so I thought I would share it amongst everyone.
Within the Wordpress head tags it can be quite messy. So here is some code to get rid of unwanted tags within the HTML
tag.Now that we know how to convert a formatted date in PHP to timestamp. Let’s move on to compare two dates. At my workplace I came across and instance where I had to check the posted date wasn’t less than today’s date, so let’s put this in picture so you know the concept behind date [...]
Whether you are posting a date or a passing variable that is a formatted date you can use the function below to convert it into a timestamp function convert_timestamp($delimeter,$date){ $explode_date = explode($delimeter,$date); $new_date = mktime(0,0,0,$explode_date[1],$explode_date[0],$explode_date[2]); return $new_date; } Now to test the function we have created is shown below. $date = “01/12/2009″; $delimeter = “/”; [...]