solved Top List chart by Genre

alt=
@msimon117
6 years ago
7 posts
I would like to have an ajax link that will list songs by genre in a top list.
{jrCore_list module="jrAudio" quota_id="2" chart_field="audio_file_stream_count" chart_days="360" template="song_chart_row2.tpl" search = "audio.genre = `$item.audio_genre`" pagebreak="10" page=$_post.p}

how do I get {$item.audio_genre} from the previous page. I tried search = "audio.genre = `$item.audio_genre`" but it won't work in that way. I'm not sure how with this version of Jamroom
updated by @msimon117: 11/09/18 04:39:59PM
nate
@nate
6 years ago
917 posts
I'm not 100% sure of what you're trying to do, but don't use audio.genre use audio_genre.

search="audio_genre = `$item.audio_genre`"
alt=
@msimon117
6 years ago
7 posts
nate:
I'm not 100% sure of what you're trying to do, but don't use audio.genre use audio_genre.

search="audio_genre = `$item.audio_genre`"

thanks I tried that before and it didn't work. i have a list with the genre in a column. i'm trying to allow the genre to be clicked on and a top list off that genre will display.
michael
@michael
6 years ago
7,744 posts
use {debug} to make sure that there is a value at {$item.audio_genre} where you're trying to use the {jrCore_list} call. If there is no value in that variable your jrCore_list call will fail for sure.

You're going to need a way to choose a genre, so probably that's going to come from the url
site.com/the-genre-choosing-page/genre=punk

if you had a URL like that then inside the the-genre-choosing-page.tpl file the {debug} panel would show you that you have the work "punk" available on {$_post.genre}, so use THAT in your jrCore_list call.

--edit--
Docs: "{debug}"
https://www.jamroom.net/the-jamroom-network/documentation/module-developer-guide/1477/debug
updated by @michael: 08/06/18 09:13:28PM
alt=
@msimon117
6 years ago
7 posts
michael:
use {debug} to make sure that there is a value at {$item.audio_genre} where you're trying to use the {jrCore_list} call. If there is no value in that variable your jrCore_list call will fail for sure.

You're going to need a way to choose a genre, so probably that's going to come from the url
site.com/the-genre-choosing-page/genre=punk

if you had a URL like that then inside the the-genre-choosing-page.tpl file the {debug} panel would show you that you have the work "punk" available on {$_post.genre}, so use THAT in your jrCore_list call.

--edit--
Docs: "{debug}"
https://www.jamroom.net/the-jamroom-network/documentation/module-developer-guide/1477/debug

Thanks @michael that pointed me in the right direction got it to work

Tags