Roku Developer Program

Join our online forum to talk to Roku developers and fellow channel creators. Ask questions, share tips with the community, and find helpful resources.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
bbakernc
Visitor

Add Date Released

We have everything working great, but now we need to add Date Released to the detailed page. We have it in the XML file and we can make the datereleased tag populate the "TITLE" but we don't see in the Date Realeased field on the detailed page.

We are assuming we have to enable this to be displayed?

We have disabled the StarRating, but we can't find then datereleased.enabled(true) type of code.

Can someone tell us where to enable this?

THANKS
0 Kudos
15 REPLIES 15
RokuChris
Roku Employee
Roku Employee

Re: Add Date Released

You don't explicitly enable/disable the release date. It will be displayed based on the values of the contentType and releaseDate attributes of your content-meta-data object. releaseDate can be an arbitrary string. The most common values for contentType that will display the release date are "movie" or "episode". Other possible values are documented in section 3.3 of the Component Reference.
0 Kudos
bbakernc
Visitor

Re: Add Date Released

Going back to the basics, Starting with the Example VideoPlayer

We added; in CreateObject("roAssociativeArray")
o.ReleaseDate = ""

Then, in showList = xml.GetChildElements()
we added;
item.ReleaseDate = validstr(curShow.releasedate.GetText())

This displayed nothing.

Then we changed
item.Title = validstr(curShow.releasedate.GetText())

On the detailed page in the TITLE area, it displayed, 01/10/2011 (our date)
This proves, the XML file is passing the date, but it will not display on the detailed page???????
0 Kudos
RokuChris
Roku Employee
Roku Employee

Re: Add Date Released

And what is the value of your contentType attribute?

It might also be worth double checking that you aren't overriding the contentType by calling SetDescriptionStyle() on your springboard.

You could also try printing the contents of releaseDate to the debug console at the time the springboard is populated to be sure the value is actually there.
0 Kudos
bbakernc
Visitor

Re: Add Date Released

item.ContentType = "episode"

Is this correct?
0 Kudos
RokuChris
Roku Employee
Roku Employee

Re: Add Date Released

"bbakernc" wrote:
item.ContentType = "episode"

Is this correct?


That's right. So the next thing is to confirm those values are not being changed between the time you parse the XML and the time you actually populate the springboard.
0 Kudos
bbakernc
Visitor

Re: Add Date Released

Being new to this progaming language, where would be a good place to start looking.

I have search the Detailed/Springboard file and releasedate was not found.
0 Kudos
destruk
Streaming Star

Re: Add Date Released

I think you need to add a line for SetDescriptionStyle to either "movie" or "video" to get it to show the releasedate
By default is sets itself to "generic" if it's not specified.

“audio”: All tags on audio screen above are substituted with Content Meta-Data.
“movie”: All tags on the video screen above are substituted with Content Meta-Data
“video”: All tags except <Directors> and <Ratings> are on the video screen above are replaced with Content Meta-Data.
“generic”: Only the <Title> and <Description> tags on the video screen above are replaced with Content Meta-Data.

Function preShowDetailScreen() As Object
port=CreateObject("roMessagePort")
screen = CreateObject("roSpringboardScreen")
screen.SetDescriptionStyle("movie")
screen.SetStaticRatingEnabled(FALSE)
screen.SetMessagePort(port)
return screen
End Function
0 Kudos
TheEndless
Channel Surfer

Re: Add Date Released

"destruk" wrote:
I think you need to add a line for SetDescriptionStyle to either "movie" or "video" to get it to show the releasedate
By default is sets itself to "generic" if it's not specified.

“audio”: All tags on audio screen above are substituted with Content Meta-Data.
“movie”: All tags on the video screen above are substituted with Content Meta-Data
“video”: All tags except <Directors> and <Ratings> are on the video screen above are replaced with Content Meta-Data.
“generic”: Only the <Title> and <Description> tags on the video screen above are replaced with Content Meta-Data.

Function preShowDetailScreen() As Object
port=CreateObject("roMessagePort")
screen = CreateObject("roSpringboardScreen")
screen.SetDescriptionStyle("movie")
screen.SetStaticRatingEnabled(FALSE)
screen.SetMessagePort(port)
return screen
End Function

You should only need to call SetDescriptionStyle if the ContentType of the item being displayed doesn't accurately set it intrinsically. With a ContentType of "Episode", the springboard should display release date without the need to call SetDescriptionStyle.
My Channels: http://roku.permanence.com - Twitter: @TheEndlessDev
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)
0 Kudos
destruk
Streaming Star

Re: Add Date Released

It's a bug then because in actual practice, even with the content type of episode it acts as generic, with only the title and description being populated like the componentguide says it does.
I just know because I had to set the content to episode, and the descriptionstyle to movie to get it to display the runtime of a video file. Generic and 'unspecified' descriptionstyle prevent the runtime from displaying too.
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.