See the following test script:
Code: Select all
<?php
$script = 'http://' . $_SERVER['SERVER_NAME'] . $_SERVER['SCRIPT_NAME'];
$param = htmlspecialchars(isset($_GET['param'])? $_GET['param'] : '', ENT_QUOTES, 'UTF-8');
header('Content-Type: text/xml;charset=utf-8');
echo <<<EOT
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<manialink version="1" background="0">
<entry id="entry" name="inputParam" sizen="100 5" default="Some special characters: äöüß 日本語"/>
<label id="label" posn="0 -10" style="CardButtonMediumWide" text="Send! (with ManiaScript)" ScriptEvents="1" />
<label posn="0 -20" style="CardButtonMediumWide" text="Send! (with label-manialink)" manialink="{$script}?param=inputParam" />
<label posn="0 -30" textcolor="000F">{$param}</label>
<script><!--
while(True) {
foreach(Event in PendingEvents) {
if (Event.Type == CGameManialinkScriptEvent::Type::MouseClick && Event.ControlId == "label") {
declare Text Link = "{$script}?param=" ^ (Page.GetFirstChild("entry") as CGameManialinkEntry).Value;
log("OpenLink: " ^ Link);
OpenLink(Link, ::LinkType::ManialinkBrowser);
}
}
yield;
}
--></script>
</manialink>
EOT;
?>
Already heard of that bug? Then you may remember my bug report over a year ago, yet it still persists... How about eventually fixing it?
