One of the great things on Pandora is that it's extremely flexible. While trying to send markup strings from a generic_data_string module, data packets were either: 1) being discarded and not processed 2) generating input as hash(x?x?) value on Pandora Web Examples of this are modules that return HTML input: Pandora Web Page The above string is interpreted by the server as XML and not as a string while processing the data packet (using XMLin input). We have resolved this in the meantime by analysing if the incoming string is an XML value. If so, we transform it again to a string. Code location: pandora_server/bin/pandora_db.pm Code function: sub module_generic_data_string (%$$$$$) Code inserted: use XML::Simple; (...) if (ref($m_data) eq "HASH") { $m_data = XMLout($m_data, RootName=>undef); } Hope this helps. Cheers
Pandora Server generic_data_string markup problem
Joao · 6 feb 2006, 21:10 · 6 mensajes · 41 visitas
- Inicio del debate
Thanks a lot for the fix !!. It will be tested and included for 1.2 release.
I actually get some extrange data, for example Data string: Feb 7 02:07:00 rhino Pandora Web Page Converts to: Pandora Web Page Feb 7 02:07:00 rhino XML conversion seems to be invalid :(, its better than nothing, but i need to improve it.
My modules that return XML/HTML markup always have a primary tag, like in Pandora Web Page The example you posted has some text before the tag making it an invalid XML/HTML subset. Unfortunately, I did not test the XML conversion this way. Don't know if you are aware of it but Data::Dumper extension could help in this case. Juse [m]use Data::Dumper[/m] in the beginning of the code and then [m]print Dumper($m_data)[/m] to get a representation of the XML tree structure. You might want probably to print it to the logger ;-) . I'll try to take a look into it. Should I find some additional info, I'll post it :-)
Labeled as bug PS-060103-1
Solved in the last update of Pandora Server 1.2 Beta
Entra en tu cuenta para publicar.
