Call function in an array in a property of a class


This question already has an answer here:


$myClass = new myClass();

class myClass {

    public $array;

    function myClass(){
        $this -> array =  array( 'test' => rand(1,5) );


For more details: What is the better approach to initialize class variables?

Need Your Help

Overriding OnPaint on Button - Font different winforms override onpaint

i am trying to Override OnPaint in WinForms Button controll. I want to align the Image and Text in the center, next to each other. As i am aware there is no way to do this with the default control....