Demo entry 3494930

php

   

Submitted by anonymous on Jan 04, 2016 at 14:38
Language: PHP. Code size: 446 Bytes.

    public static function createObject(Array $params = array()) {
        $defaultParams = array("name" => "TestTagTracker",
                               "account_id" => 1035,
                               "status" => 1);
        $params = array_merge($defaultParams, $params);

        $object = new models\Object();
        $object = self::fillProperties($object, $params);
        $object->save();

        return $object;
    }

This snippet took 0.00 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).