Category PHP

Parse and get xml node using php

XML Parsing using PHP

XML parsing essentially means traversing through the XML and returning the data. Nowadays, A number of web services return data in JSON format, but a large number still use XML. There are two methods for loading XML, the simplexml_load_file() will load the…

Add hours in DateTime in PHP

Date Time

In PHP, you can get the current Date and Time by using the function date(): date()     OR   date(‘Y-m-d H:i:s’)   Manipulating Date/Time is very easy in PHP and you can easily add something to this, like add hours, days, minutes…