We are going to edit playlist.jsp. Here is the part we are going to edit:
- Code: Select all
if ($("genre" + id)) {
dwr.util.setValue("genre" + id, song.genre);
}
if ($("year" + id)) {
dwr.util.setValue("year" + id, song.year);
}
if ($("bitRate" + id)) {
dwr.util.setValue("bitRate" + id, song.bitRate);
}
replace the year with
- Code: Select all
if ($("year" + id)) {
if (song.year) {
dwr.util.setValue("year" + id, song.year.substring(0,4));
} else {
dwr.util.setValue("year" + id, song.year);
}
}
Hope this helps!
