Categories
Coding

How to convert a multidimensional array to an object in PHP

Today I was working on creating an object from an array of data, I didn’t want a full blown class as I was only accessing the data as application settings  and thankfully due to PHP’s stdClass class this can be easily achieved like so:- $obj = new stdClass($array); or like… $obj = (object) $array However, problems occur […]

Categories
Coding

Creating *NIX user accounts without need for a password prompt!

It is likely that in future I will be implementing SSH access and generally changing the way that users are handled by ZPanel (on the *NIX platform). Currently all user accounts across ZPanel are ‘virtual’ accounts and not system accounts and for various reason’s I may want to change this in future. I have written […]