oricoun 4 Posted May 7, 2015 Report Share Posted May 7, 2015 Guys, I would like to transform XML feed into csv file, but I run into trouble of weird characters while getting data from XML, it is all nonsense, and I have no I idea how to go around it: Code: set(#xml, $plugin function("HTTP post.dll", "$http get", "http://www.hrnce-obchod.sk/192fc044e74dffea144f9ac5dc9f3395/heureka_sk_export.xml", "", "", "", 30), "Global")set(#DESCRIPTION, $plugin function("HTTP post.dll", "$xpath parser", #xml, "//DESCRIPTION", "InnerText", "XML"), "Global")load html(#DESCRIPTION) Basicaly, it will navigate to: http://www.hrnce-obchod.sk/192fc044e74dffea144f9ac5dc9f3395/heureka_sk_export.xml xpath parser will get "DESCRIPTION" And the result is absolute mess. Any help will be appreciated. THX. Quote Link to post Share on other sites
HelloInsomnia 1103 Posted May 7, 2015 Report Share Posted May 7, 2015 Ubot doesn't play nicely with certain encodings. Especially if you try to display them in their browser. Put this above your code: plugin command("HTTP post.dll", "http set encoding", "UTF8") Then run it and look in the debugger, not the browser output. You will see it reads much better and should be able to save it no problem from there. Quote Link to post Share on other sites
oricoun 4 Posted May 8, 2015 Author Report Share Posted May 8, 2015 Thanks so much. It works. 1 Quote Link to post Share on other sites
gavind 6 Posted May 14, 2015 Report Share Posted May 14, 2015 Great! I never knew the solution was just that simple. 1 Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.