You are required to install and get working the "Yiifilemanager extension".
+1. requirednstall and get working "Yiifilemanager extension".
You must install the provided SQL script. (see package)
+2. nstall the provided SQL script. (see package)
-Because all the incoming messages are saved into the Yiifilemanager managed
-domain the you can use: "Yiifilemanagerfilepicker" to manage files online.
1. clone it from bitbucket into your 'protected/extensions' directory.
2. Register this extension in your imports:
-4. Edit the
class method to feet your needs, pay attention to:
+4. Edit the to feet your needs, pay attention to:
-6. Now you are required to create a URL for a given CLASSNAME and IDENTITY,
- you can do so by using the provided API:
+6. You are required to create a URL for a given CLASSNAME and IDENTITY
+(this will be the Listener in your app, per instance), you can do so by using the provided API:
- // suppose you want to receive data for this object instance:
+ // suppose you want to receive data for a given object instance, so all
+ // incoming data received using from this remote interface will be
+ // stored in the model's file space. (see yiifilemanager extension)
$model = SomeClassName::model()->findByPk('123');
$api = new YiiFileManagerRemoteApi();
$CRC32_UID = $api->newListener("SomeClassName","123");
$URL = CHtml::normalizeUrl(array('/site/incoming','uid'=>$CRC32_UID));
echo "Dear user, send a POST['content']='hello world' to this URL: ".$URL;
+ // please note we are not using the $model instance here, it is
+ // in this document only as a reference in help to clarify the idea.
+ // in place of it we are using the model primarykey and the model class
7. When some one uses this URL to send messages to you then it will be
received in the "SomeClassName" only if: