Difference between revisions of "Ryzom API/Render"

From EncyclopAtys

Jump to: navigation, search
(category)
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
 
+
<noinclude>{{Trad|DE=Ryzom API/Render|EN=Ryzom API/Render|palette=api|H=1}}</noinclude>
  
 
This is a set of PHP function to render a web page using Ryzom style.
 
This is a set of PHP function to render a web page using Ryzom style.
Line 28: Line 28:
  
 
echo ryzom_render_window('Title', 'Hello World!', $links);</syntaxhighlight>
 
echo ryzom_render_window('Title', 'Hello World!', $links);</syntaxhighlight>
<noinclude>[[Category:Ryzom API|{{subst:SUBPAGENAME}] ]]</noinclude>
+
<noinclude>[[Category:Ryzom API|Render]]</noinclude>

Latest revision as of 13:26, 27 May 2023

de:Ryzom API/Render en:Ryzom API/Render
 
UnderConstruction.png
Translation to review
Don't blame the contributors, but come and help them 😎

Reference text ( Maintained text, used as reference ) :
Notes: (Leda, 2023-05-27)


This is a set of PHP function to render a web page using Ryzom style.


CSS file

You need to manually include ryzom css file :

<link href="https://api.ryzom.com/data/css/ryzom_ui.css" rel="stylesheet" media="all">

PHP interface

ryzom_render_window($title, $content, array $links)

Returns html markup resembling ingame window style

$title
$content
$links - (optional) associative array that defines right side buttons on window title bar
<?php
require_once "ryzomapi_lite.php";

$links = array(
  array('href' => 'http://www.ryzom.com/', 'text' => 'Ryzom website'),
  array('href' => 'http://app.ryzom.com/app_ryzomapi/', 'text' => 'RyzomAPI app'),
);

echo ryzom_render_window('Title', 'Hello World!', $links);