App
Version 1 (vl, 10/16/2009 12:24 pm)
1 | 1 | vl | h1. App |
---|---|---|---|
2 | 1 | vl | |
3 | 1 | vl | Create Ryzom application that will be available out the game (with the browser) and in game. |
4 | 1 | vl | |
5 | 1 | vl | h2. PHP Interface |
6 | 1 | vl | |
7 | 1 | vl | h3. @ryzom_app_authenticate()@ |
8 | 1 | vl | |
9 | 1 | vl | Check if the user is a valid one. If it's ok, the function setup globally these variables: |
10 | 1 | vl | * *$ig*: true if the user is in the game. false if the user is out of the game (browser) |
11 | 1 | vl | * *$user*: an array that contains information of the user (lang, cid, shard, shardid, name) |
12 | 1 | vl | |
13 | 1 | vl | h3. @ryzom_app_render($title, $content)@ |
14 | 1 | vl | |
15 | 1 | vl | Render the $content depending of if the user is in game or out game. |
16 | 1 | vl | |
17 | 1 | vl | h3. @ryzom_relative_time($timestamp)@ |
18 | 1 | vl | |
19 | 1 | vl | Return a human and translated readable time, for example "3 days ago". |
20 | 1 | vl | |
21 | 1 | vl | h3. @ryzom_get_param($var)@ |
22 | 1 | vl | |
23 | 1 | vl | Always use this function to get param because in game, the param can be pass by _GET or by _POST |