brucerothwell
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-21-2011
06:31 AM
Reading An HTML File with ReadAsciiFile?
I'm using the MRSS template.
In the main.brs, I have changed the line that uses ReadAsciiFile to read the config.opml from a URL location, thusly:
However, the file does not seem to be getting read, as the channel will not play in Roku.
The config.opml does exist at that URL location, though.
So, my question is this: How can I make this work, so the config.opml file does not have to be part of the package?
(NOTE: I have also experimented with the videoplayer example, and can point to a URL location for the category.xml file just fine)
Thx!
-
Bruce
In the main.brs, I have changed the line that uses ReadAsciiFile to read the config.opml from a URL location, thusly:
raw = roURLTransfer("http://www.clearperception.org/wordchannel/config.opml")
However, the file does not seem to be getting read, as the channel will not play in Roku.
The config.opml does exist at that URL location, though.
So, my question is this: How can I make this work, so the config.opml file does not have to be part of the package?
(NOTE: I have also experimented with the videoplayer example, and can point to a URL location for the category.xml file just fine)
Thx!
-
Bruce
3 REPLIES 3
renojim
Community Streaming Expert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-21-2011
02:14 PM
Re: Reading An HTML File with ReadAsciiFile?
xfer = CreateObject("roUrlTransfer")
xfer.SetUrl("http://www.clearperception.org/wordchannel/config.opml")
raw = xfer.GetToString()
It's all in the documentation for roUrlTransfer.
-JT
Roku Community Streaming Expert
Help others find this answer and click "Accept as Solution."
If you appreciate my answer, maybe give me a Kudo.
I am not a Roku employee.
Help others find this answer and click "Accept as Solution."
If you appreciate my answer, maybe give me a Kudo.
I am not a Roku employee.
brucerothwell
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-21-2011
04:10 PM
Re: Reading An HTML File with ReadAsciiFile?
JT,
Thanks for the example code.
Ya know, it is odd that I searched on "("http:" in the Brightscript PDF file that came with the SDK and never found anything.
Is this kind of thing documented in a different PDF file?
-
Bruce
Thanks for the example code.
Ya know, it is odd that I searched on "("http:" in the Brightscript PDF file that came with the SDK and never found anything.
Is this kind of thing documented in a different PDF file?
-
Bruce
renojim
Community Streaming Expert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-21-2011
04:37 PM
Re: Reading An HTML File with ReadAsciiFile?
You want to be looking at the Component Reference. The BrightScript reference mostly just has language elements.
-JT
-JT
Roku Community Streaming Expert
Help others find this answer and click "Accept as Solution."
If you appreciate my answer, maybe give me a Kudo.
I am not a Roku employee.
Help others find this answer and click "Accept as Solution."
If you appreciate my answer, maybe give me a Kudo.
I am not a Roku employee.