Oleg K %!s(int64=4) %!d(string=hai) anos
achega
1bcf9a1bdb
Modificáronse 3 ficheiros con 66 adicións e 0 borrados
  1. 14 0
      AutoloadExample.php
  2. 31 0
      README.md
  3. 21 0
      composer.json

+ 14 - 0
AutoloadExample.php

@@ -0,0 +1,14 @@
+<?php
+
+namespace ptenchik0\referral;
+
+/**
+ * This is just an example.
+ */
+class AutoloadExample extends \yii\base\Widget
+{
+    public function run()
+    {
+        return "Hello!";
+    }
+}

+ 31 - 0
README.md

@@ -0,0 +1,31 @@
+Referral system
+===============
+Referral system desc
+
+Installation
+------------
+
+The preferred way to install this extension is through [composer](http://getcomposer.org/download/).
+
+Either run
+
+```
+php composer.phar require --prefer-dist ptenchik0/yii2-referral "*"
+```
+
+or add
+
+```
+"ptenchik0/yii2-referral": "*"
+```
+
+to the require section of your `composer.json` file.
+
+
+Usage
+-----
+
+Once the extension is installed, simply use it in your code by  :
+
+```php
+<?= \ptenchik0\referral\AutoloadExample::widget(); ?>```

+ 21 - 0
composer.json

@@ -0,0 +1,21 @@
+{
+    "name": "ptenchik0/yii2-referral",
+    "description": "Referral system desc",
+    "type": "yii2-extension",
+    "keywords": ["yii2","extension","referral"],
+    "license": "BSD-3-Clause",
+    "authors": [
+        {
+            "name": "Oleg",
+            "email": "ptenchik0@gmail.com"
+        }
+    ],
+    "require": {
+        "yiisoft/yii2": "~2.0.0"
+    },
+    "autoload": {
+        "psr-4": {
+            "ptenchik0\\referral\\": ""
+        }
+    }
+}