Wednesday, December 17, 2008, 9:28:24 PM, Stéphane Heckel wrote:
> Implementing the feature on the server side is the best option. The concept
> works :
> // xmlrpc backend - $shoutmessage is the message sent by the desktop
> application
> ...
> $page = RetrieveAuthPage($pagename, "read", false, READPAGE_CURRENT);
> $content = $shoutmessage."\n\n".$page['text'];
> ...
> return BloggerXMLRPC::PostWikiPage($pagename, $content, $publish, true);
> // I have to transform $shoutmessage, to something like below, and this is
> where I fail
> "'''[[{$PageAuthId}|{$AuthId}]]''': {$$shout} - [-''{(ftime fmt="%d/%m
> %H:%M")}''-] [[<<]]"
> ie : final output would be
> '''[[Profiles.Steph|[email protected]]]''': Welcome ! - [-''01/12 09:58''-]
> [[<<]]
> So I don't know how to translate the fox/markup syntax and implement the
> equivalent in the php function.
perhaps something like this:
$page = RetrieveAuthPage($pagename, "read", false, READPAGE_CURRENT);
$shoutmessage = "'''[[".$PageAuthId."|".$AuthId."]]''': $shoutmessage -
[-''"
.strftime('%d/%m %H:%M', time() )."''-] [[<<]]";
$content = $shoutmessage."\n\n".$page['text'];
...
return BloggerXMLRPC::PostWikiPage($pagename, $content, $publish, true);
if this is in a function, you also need to set in it (at the
beginning):
global $PageAuthId,$AuthId;
~Hans
_______________________________________________
pmwiki-users mailing list
[email protected]
http://www.pmichaud.com/mailman/listinfo/pmwiki-users