I am tying to convert a ruby code into php, from scratch. I have a few questions:
1.how would look the attr_accessor :ID :code
in php?
Something like this?
private $ID=null;
private $code=null;
- how would look the code in php for:
def initialize(attributes={}) self.ID = attributes[:ID] self.CODE = attributes[:code]
Hope you can help, Kind regards, jhonnatan
Edited:
3.
def get_ID
get('get_ID')
end
Will it be something like this:
public function __construct(ID)
get('...')