userpoints:developer
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
userpoints:developer [2024/02/07 17:04] – admin | userpoints:developer [2025/03/07 14:28] (current) – admin | ||
---|---|---|---|
Line 28: | Line 28: | ||
<code php> | <code php> | ||
use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | ||
- | UserPoints:: | + | |
+ | | ||
+ | } | ||
</ | </ | ||
Line 46: | Line 48: | ||
<code php> | <code php> | ||
use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | ||
- | $upid = UserPoints:: | + | |
- | if ( $bupid ) UserPoints:: | + | |
+ | if ( $bupid ) UserPoints:: | ||
+ | } | ||
</ | </ | ||
Line 56: | Line 60: | ||
<code php> | <code php> | ||
use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | ||
- | $keyreference = UserPoints:: | + | |
- | UserPoints:: | + | |
+ | UserPoints:: | ||
+ | } | ||
</ | </ | ||
Line 66: | Line 72: | ||
<code php> | <code php> | ||
use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | ||
- | $keyreference = UserPoints:: | + | |
- | UserPoints:: | + | |
+ | UserPoints:: | ||
+ | } | ||
</ | </ | ||
Line 76: | Line 84: | ||
<code php> | <code php> | ||
use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | ||
- | $keyreference = UserPoints:: | + | |
- | UserPoints:: | + | |
+ | UserPoints:: | ||
+ | } | ||
</ | </ | ||
Line 86: | Line 96: | ||
<code php> | <code php> | ||
use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | ||
- | $keyreference=UserPoints:: | + | |
- | if (UserPoints:: | + | |
- | { | + | if (UserPoints:: |
- | | + | { |
+ | [... code for successful operation ...] | ||
+ | } | ||
} | } | ||
</ | </ | ||
Line 103: | Line 115: | ||
<code php> | <code php> | ||
use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | use BlackSheepResearch\Component\UserPoints\Site\UserPoints; | ||
- | UserPoints:: | + | |
+ | | ||
string $pluginfunction, | string $pluginfunction, | ||
[string $BUPIDotheruser = '' | [string $BUPIDotheruser = '' | ||
Line 112: | Line 125: | ||
[integer $force=0], | [integer $force=0], | ||
[string $frontmessage='' | [string $frontmessage='' | ||
- | | + | |
+ | } | ||
</ | </ | ||
Line 119: | Line 133: | ||
==== Step 2 - XML file creation ==== | ==== Step 2 - XML file creation ==== | ||
- | Then developers have to create an xml file to make easier the installation process in the UserPoints component. This xml file has to be utf-8 encoded | + | To complete the integration of an application with UserPoints, |
- | Administrator of the website which install a third component | + | |
- | This xml file has to be utf-8 encoded (required) but not be zipped! Just put this file at the root of frontend | + | An example of userpoints_rule.xml is the file for Remository which reads: |
+ | |||
+ | < | ||
+ | <?xml version=" | ||
+ | < | ||
+ | <component> | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
=== Code list for categories : === | === Code list for categories : === | ||
Line 144: | Line 186: | ||
</ | </ | ||
- | NOTE : Optionally, you can avoid this step manually by filling all the fields in the creation of a new rule directly in the rule manager (button ' | + | === Code list for methods: === |
+ | |||
+ | You can add a < | ||
+ | |||
+ | < | ||
+ | 1 -> Only once | ||
+ | 2 -> Once a day per user | ||
+ | 3 -> Once a day for a single user on all users | ||
+ | 4 -> Whenever | ||
+ | 5 -> Once per week | ||
+ | 6 -> Once per month | ||
+ | 7 -> Once per year | ||
+ | </ | ||
- | ==== Plugin/Rule installation ==== | + | NOTE : It is possible to create new rules manually by filling all the fields in the creation of a new rule directly in the rule manager (button ' |
- | - auto-detect xml file at the root of frontend component: | ||
- | Click on the button “Auto-detect plugins” in the control panel of UserPoints after installation of third component, plugin or module. Check regularly or periodically by clicking on this button. | ||
- | ==== Using UserPoints information in a third party component ==== | + | ===== Using UserPoints information in a third party component |
You can use easily the profil informations of a user directly in a third component. | You can use easily the profil informations of a user directly in a third component. | ||
Line 414: | Line 467: | ||
* Created on 15 January 2016. | * Created on 15 January 2016. | ||
- | * Last updated on 7 February | + | * Last updated on 25 November |
userpoints/developer.1707325480.txt.gz · Last modified: 2024/02/07 17:04 by admin