Commits

Guido Draheim committed 9391297

adding "Staffel" (season) and "Folge" (episode) automatically from "tvspielfilm"

Comments (0)

Files changed (1)

src/dvbcronrecording/htdocs/js/dvbcronrecording_tvspielfilm.user.js

 	var time = $(film_items.get(1)).text();
 	var channel = $(film_items.get(2)).text();
 	var title = $($("h1").get(0)).text();
+	var text = film_info.text();
+	var found = text.match(/Staffel \w+/);
+	if (found) {
+		for (var i=0; i<found.length; i++)
+			title += " " + found[i];
+	}
+	var found = text.match(/Folge \w+/);
+	if (found) {
+		for (var i=0; i<found.length; i++)
+			title += " " + found[i];
+	}
 	// alert("DATE:"+date+" TIME:"+time+" CHANNEL:"+channel+" TITLE:"+title);
 	save_send(date, time, channel, title);
 }