Prevent deletion of server section
[pyTivo.git] / plugins / admin / templates / settings.tmpl
blob7221d78bb9c75e0999738db6967d559d8d232469
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">\r
2 <html>\r
3 <head>\r
4 \r
5   <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">\r
6   <title>pyTivo Web Configuration</title>\r
7 \r
8 \r
9   <script language="javascript" type="text/javascript">\r
10 function fillBlank(){\r
11 var texts=document.getElementsByTagName('input')\r
12 for (var i_tem = 0; i_tem < texts.length; i_tem++)\r
13 if (texts[i_tem].value=='')\r
14 texts[i_tem].value=' '\r
15 }\r
16 function switchDiv(pass, type){ \r
17 hideallids(type);\r
18 showDiv(pass);\r
19 }\r
20 function hideallids(type){\r
21 //loop through the array and hide each element by id\r
22 var divs = document.getElementsByTagName('div');\r
23 for (var i=0;i<divs.length;i++){\r
24 if(divs[i].id.match(type)){\r
25 hideDiv(divs[i].id);\r
26 }\r
27 } }\r
28 function hideDiv(pass) {\r
29 var divs = document.getElementsByTagName('div');\r
30 for(i=0;i<divs.length;i++){\r
31 if(divs[i].id.match(pass)){//if they are 'see' divs\r
32 if (document.getElementById) // DOM3 = IE5, NS6\r
33 divs[i].style.visibility="hidden";// show/hide\r
34 else\r
35 if (document.layers) // Netscape 4\r
36 document.layers[divs[i]].display = 'hidden';\r
37 else // IE 4\r
38 document.all.hideshow.divs[i].visibility = 'hidden';\r
39 }\r
40 }\r
41 }\r
42 function showDiv(pass) {\r
43 var divs = document.getElementsByTagName('div');\r
44 for(i=0;i<divs.length;i++){\r
45 if(divs[i].id == pass){\r
46 if (document.getElementById)\r
47 divs[i].style.visibility="";\r
48 else\r
49 if (document.layers) // Netscape 4\r
50 document.layers[divs[i]].display = '';\r
51 else // IE 4\r
52 document.all.hideshow.divs[i].visibility = '';\r
53 }\r
54 }\r
55 }\r
56 function deleteSection(id){\r
57 if (select_section.section.options[id].text == 'Global Server Settings'){\r
58         alert('Delete Error:\n\nSorry the Global Server Settings Section is required for pyTivo to run and cannot be deleted');\r
59         return true;\r
60 }\r
61 var name = select_section.section.options[id].text;\r
62 var answer = confirm("Are you sure you wish to delete the '" + name + "' Section?")\r
63 if (answer){\r
64         switchDiv('set-delete', 'set-');\r
65         select_section.section.options[id] = null;\r
66         var field = document.getElementById(name).value;\r
67         document.getElementById(field).value = 'Delete_Me';\r
68         saveNotify();\r
69         return true;\r
70 }\r
71 else{\r
72         //Don't delete\r
73 }\r
74 }\r
75 function resetpyTivo(){\r
76 var answer = confirm("Are you sure you wish to reset the pyTivo Server? Any unsaved changes will be lost!")\r
77 if (answer){\r
78         window.location="/TiVoConnect?Command=Reset&Container=$container"\r
79 }\r
80 else{\r
81         //Don't reset\r
82 }\r
83 }\r
84 function showData(form) {\r
85         var section = ""\r
86         var setting = ""\r
87         re=/[\[\]<>|]/;\r
88         inputs = form.getElementsByTagName("input");\r
89         for (i = 0; i < inputs.length; i++){\r
90                 if (inputs[i].type == 'text' && re.exec(inputs[i].value)){\r
91                         setting = inputs[i].name;\r
92                         break;\r
93                 }\r
94         }\r
95         if (setting != ""){\r
96                 var map = document.getElementById('Section_Map').value.split(']');\r
97                 map.pop();\r
98                 splitSetting = setting.split('.');\r
99                 for(i=0;i<map.length;i++){\r
100                         key = map[i].split('|');\r
101                         //buffer += key[0] + "---" + key[1] + "===" + splitSetting[0] + "\n";\r
102                         if (splitSetting[0] == 'Server'){\r
103                                 section = 'server';\r
104                                 break;\r
105                         }\r
106                         if (key[0] == splitSetting[0]){\r
107                                 section = key[1];\r
108                                 break;\r
109                         }\r
110                 }\r
111                 alert("Invalid Entry:\nSorry these are not allowed \n!@#$%^&*()|}{\][?></.,:;\" '=`~");\r
112                 switchDiv('set-' + section, 'set-');\r
113                 document.getElementById(setting).select();\r
114                 return false;\r
115         }\r
116         fillBlank();\r
117         document.config.submit();\r
119 function saveNotify(){\r
120         document.getElementById('B1').style.fontWeight= 'bold';\r
121         document.getElementById('B2').disabled = true;\r
123 </script>\r
124 </head>\r
127 <body style="background-color: rgb(250, 250, 250);">\r
129 <p align="center"><font size="6">pyTivo Web\r
130 Configuration</font> <a href="#">help</a></p>\r
131 <center>\r
132 <table style="border: 1px solid rgb(220, 220, 220);background-color: rgb(255, 255, 255);text-align: left; margin-left: auto; margin-right: auto;" border="0" cellpadding="0" cellspacing="4">\r
134   <tbody>\r
136     <tr>\r
138       <td style="border-right: 1px dotted rgb(153, 153, 153); vertical-align: top;">\r
139       <div id="leftframe" style="position: relative; text-align: center; width: 200px;">\r
140       <form name="select_section">Sections\r
141         <select name="section" size="7">\r
142         <option value="set-server">Global Server Settings</option>\r
143 #for $name, $data in $shares_data\r
144         <option value="set-$name">$name</option>\r
145 #end for\r
146 #for $name, $data in $tivos_data\r
147         <option value="set-$name">$name</option>\r
148 #end for\r
149         </select>\r
151         <input name="B3" value="Edit Section" type="button" onclick="switchDiv(select_section.section.options[select_section.section.selectedIndex].value, 'set-');return true;"> \r
152         <input name="B4" value="Delete Section" type="button" onclick="deleteSection(select_section.section.selectedIndex)">\r
153         <input name="B5" value="Add Section" type="button" onclick="switchDiv('set-add', 'set-');return true;"></form>\r
155       <hr>Administration\r
156       <form method="post">\r
157         <p align="center"><input name="B1" id="B1" value="Save Changes" type="button" onclick="showData(document.config);return true;">\r
158         <input id="B2" name="B2" value="Soft Reset pyTivo" type="button" onclick="resetpyTivo();"></p>\r
160       </form>\r
162 View Raw File </div>\r
164       </td>\r
166       <td style="vertical-align: top;">\r
167       <div id="settings" style="width: 300px; overflow: scroll; height: 450px; position: relative;">\r
168       <form name="config" method="GET" action="TiVoConnect" onsubmit="fillBlank();showData(this);">\r
169       <input type="hidden" name="Command" value="UpdateSettings">\r
170       <input type="hidden" name="Container" value="$container">\r
171 <div id="set-server" style="width: 280px; text-align: center;position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
172         <b>Global Server Settings</b><br>\r
173         <hr style="width: 100%; height: 2px;"> \r
174         <table align="center">\r
175 #set $i = 0\r
176 #for $key in $server_known\r
177 #set $i += 1\r
178 #if $i%2\r
179 <tr style="background-color: rgb(250, 250, 250);">\r
180 #else\r
181 <tr>\r
182 #end if\r
183 <td>\r
184 #if $key in $server_data\r
185         $key :</td><td><input size="20" id="Server.$key" name="Server.$key" value="$server_data[$key]" onChange="saveNotify();" onfocus="switchDiv('help-$key', 'help-');return true;" type="text">\r
187 #else\r
188         $key :</td><td><input size="20" id="Server.$key" name="Server.$key" value="" onChange="saveNotify();" onfocus="switchDiv('help-$key', 'help-');return true;" type="text">\r
190 #end if\r
191 </td></tr>\r
192 #end for\r
193 <tr><td colspan="2" align="center" style="border-bottom: 1px solid rgb(153, 153, 153);">User Defined Settings:</td></tr>        \r
194 #set $i = 0\r
195 #for $key in $server_data \r
196         #if not $key in $server_known\r
197                 #set $i += 1\r
198                 #if $i%2\r
199                         <tr style="background-color: rgb(250, 250, 250);">\r
200                 #else\r
201                         <tr>\r
202                 #end if\r
203                 <td>         $key :</td><td>\r
204                 <input size="20" id="Server.$key" name="Server.$key" value="$server_data[$key]" onChange="saveNotify();" onfocus="switchDiv('help-$key', 'help-');return true;" type="text">\r
205                 </td></tr>\r
206         #end if \r
207 #end for \r
208         </table>\r
209         <div style="width: 280px; position: relative;">\r
210                 <div id="add-server-button" style="width: 280px; position: absolute; position: absolute; left: 0px; top: 0px;">\r
211                         <br>\r
212                         <center>\r
213                         <input type="button" value="Add Setting" onclick="switchDiv('add-server-field', 'add-server-');return true;">\r
214                         </center>\r
215                 </div>\r
216                 <div id="add-server-field" style="position: absolute; position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
217                         <table style="width: 265px;">\r
218                         <tr><td colspan="2" align="center" style="border-bottom: 1px solid rgb(153, 153, 153);">Add a Setting</td></tr>\r
219                         <tr><td>Setting Name:</td><td>Setting Value:</td></tr>\r
220                         <tr><td><input size="16" id="Server.new_settting" name="Server.new__setting" onChange="saveNotify();" type="text" value=""></td><td><input size="16" type="text" onChange="saveNotify();" id="Server.new_value"  name="Server.new__value" value=""></td></tr>\r
221                         </table>\r
222                 </div>\r
223         </div>\r
224 </div>\r
225 #set $section_count = 0\r
226 #set $section_map = ''\r
227 #for $name, $data in $shares_data\r
228         #set $section_count += 1\r
229         #set $section_number = 'section-' + str($section_count)\r
230         <input type="hidden" name="$name" id="$name" value="$section_number">\r
231         #set $section_map += $section_number + '|' + $name + ']'\r
232         <div id="set-$name" style="text-align: center;position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
233         [<input size="20" onChange="saveNotify();" id="$section_number" name="$section_number" value="$name">]<br>\r
234         <hr style="width: 100%; height: 2px;"><table align="center">\r
235         #set $i = 0\r
236         #for $key in $shares_known\r
237                 #set $i += 1\r
238                 #if $i%2\r
239                         <tr style="background-color: rgb(250, 250, 250);">\r
240                 #else\r
241                         <tr>\r
242                 #end if\r
243                 #if $key in $data\r
244                         <td>$key :</td><td><input onChange="saveNotify();" size="20" id="$section_number.$key" name="$section_number.$key" value="$data[$key]" onfocus="switchDiv('help-$key', 'help-');return true;" type="text">\r
245                         </td>\r
246                 #else\r
247                         <td>$key : </td><td><input onChange="saveNotify();" size="20" id="$section_number.$key" name="$section_number.$key" value="" onfocus="switchDiv('help-$key', 'help-');return true;" type="text">\r
248                         </td>\r
249                 #end if\r
250                 </tr>\r
251         #end for\r
253         <tr><td colspan="2" align="center" style="border-bottom: 1px solid rgb(153, 153, 153);">User Defined Settings:</td></tr> \r
254         #set $i = 0\r
255         #for $key in $data \r
256                 #if not $key in $shares_known\r
257                         #set $i += 1\r
258                         #if $i%2\r
259                                 <tr style="background-color: rgb(250, 250, 250);">\r
260                         #else\r
261                                 <tr>\r
262                         #end if\r
263                         <td> $key : </td><td>\r
264                         <input size="20" onChange="saveNotify();" id="$section_number.$key" name="$section_number.$key" value="$data[$key]" onfocus="switchDiv('help-$key', 'help-');return true;" type="text">\r
265                         </td></tr>\r
266                 #end if \r
267         #end for\r
268         </table>\r
269                 <div style="position: relative;">\r
270                         <div id="add-$name-button" style="width: 280px; position: absolute; position: absolute; left: 0px; top: 0px;">\r
271                                 <br>\r
272                                 <center>\r
273                                 <input type="button" value="Add Setting" onclick="switchDiv('add-$name-field', 'add-$name-');return true;">\r
274                                 </center>\r
275                         </div>\r
276                         <div id="add-$name-field" style="position: absolute; position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
277                                 <table style="width: 265px;">\r
278                                 <tr><td colspan="2" align="center" style="border-bottom: 1px solid rgb(153, 153, 153);">Add a Setting</td></tr>\r
279                                 <tr><td>Setting Name:</td><td>Setting Value:</td></tr>\r
280                                 <tr><td><input onChange="saveNotify();" size="16" id="$(section_number).new__setting" name="$(section_number).new__setting" type="text" value=""></td><td><input onChange="saveNotify();" size="16" type="text" id="$(section_number).new__value" name="$(section_number).new__value" value=""></td></tr>\r
281                                 </table>\r
282                         </div>\r
283                 </div>\r
284         </div>\r
285 #end for\r
287 #for $name, $data in $tivos_data\r
288         #set $section_count += 1\r
289         #set $section_number = 'section-' + str($section_count)\r
290         <input type="hidden" name="$name" id="$name" value="$section_number">\r
291         #set $section_map += $section_number + '|' + $name + ']'\r
292         <div id="set-$name" style="text-align: center;position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
293         [<input size="20" onChange="saveNotify();" id="$section_number" name="$section_number" value="$name">]<br>\r
294         <hr style="width: 100%; height: 2px;"><table align="center">\r
295         #set $i = 0\r
296         #for $key in $tivos_known\r
297                 #set $i += 1\r
298                 #if $i%2\r
299                         <tr style="background-color: rgb(250, 250, 250);">\r
300                 #else\r
301                         <tr>\r
302                 #end if\r
303                 #if $key in $data\r
304                         <td>$key :</td><td><input onChange="saveNotify();" size="20" id="$section_number.$key" name="$section_number.$key" value="$data[$key]" onfocus="switchDiv('help-$key', 'help-');return true;" type="text">\r
305                         </td>\r
306                 #else\r
307                         <td>$key :</td><td><input onChange="saveNotify();" size="20" id="$section_number.$key" name="$section_number.$key" value="" onfocus="switchDiv('help-$key', 'help-');return true;" type="text">\r
308                         </td>\r
309                 #end if\r
310                 </tr>\r
311         #end for\r
313         <tr><td colspan="2" align="center" style="border-bottom: 1px solid rgb(153, 153, 153);">User Defined Settings:</td></tr> \r
314         #set $i = 0\r
315         #for $key in $data \r
316                 #if not $key in $tivos_known\r
317                         #set $i += 1\r
318                         #if $i%2\r
319                                 <tr style="background-color: rgb(250, 250, 250);">\r
320                         #else\r
321                                 <tr>\r
322                         #end if\r
323                         <td> $key :</td><td> \r
324                         <input size="20" onChange="saveNotify();" id="$section_number.$key" name="$section_number.$key" value="$data[$key]" onfocus="switchDiv('help-$key', 'help-');return true;" type="text">\r
325                         </td></tr>\r
326                 #end if \r
327         #end for\r
328         </table>\r
329                 <div style="position: relative;">\r
330                         <div id="add-$name-button" style="width: 280px; position: absolute; position: absolute; left: 0px; top: 0px;">\r
331                                 <br>\r
332                                 <center>\r
333                                 <input type="button" value="Add Setting" onclick="switchDiv('add-$name-field', 'add-$name-');return true;">\r
334                                 </center>\r
335                         </div>\r
336                         <div id="add-$name-field" style="position: absolute; position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
337                                 <table style="width: 265px;">\r
338                                 <tr><td colspan="2" align="center" style="border-bottom: 1px solid rgb(153, 153, 153);">Add a Setting</td></tr>\r
339                                 <tr><td>Setting Name:</td><td>Setting Value:</td></tr>\r
340                                 <tr><td><input onChange="saveNotify();" size="16" id="$(section_number).new__setting" name="$(section_number).new__setting" type="text" value=""></td><td><input onChange="saveNotify();" size="16" type="text" id="$(section_number).new__value" name="$(section_number).new__value" value=""></td></tr>\r
341                                 </table>\r
342                         </div>\r
343                 </div>\r
344         </div>\r
345 #end for\r
346 <div id="set-add" style="text-align: center;position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
347         Add a New Section\r
348         <hr>\r
349         <table>\r
350         <tr>\r
351         <td> Section Name :</td><td> \r
352                 <input onChange="saveNotify();" type="text" size="20" name="new_Section" value="" onfocus="switchDiv('help-add', 'help-');return true;">\r
353         </td></tr></table>\r
354         The new section name will be added to the pyTivo.conf file when you click <b>Save Changes</b>.\r
355 </div>\r
356 <div id="set-delete" style="text-align: center;position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
357         Delete a Section\r
358         <hr>\r
359         <br>\r
360         The Section has been marked for deletion. However it will not be actually deleted until you click the <b>Save Changes</b> button.\r
361 </div>\r
362 <input type="hidden" id="Section_Map" name="Section_Map" value="$section_map">\r
363       </form>\r
365       </div>\r
367       </td>\r
369       <td style="border-left: 1px dotted rgb(153, 153, 153); vertical-align: top;">\r
370       <div id="sidesections" style="width: 400px; position: relative;"><!-- HELP SECTIONS -->\r
371       <div id="help-instructions" style="position: absolute; left: 0px; top: 0px; visibility: visible;">\r
372       <p align="center"><strong>Instructions</strong>\r
373       </p>\r
375 Instructions and sample settings will appear here when you click on the\r
376 settings boxes</div>\r
378         <div id="help-add" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
379       <p align="center"><strong>Add a New Section</strong> </p>\r
381       <p> Add the name of a new section.<br>\r
383       Remember if you want to add TiVo section remember it must start with _tivo_<br>\r
385       You must save your settings before the new section will be editable.<br>\r
386         </p>\r
388       </div>\r
390       <div id="help-port" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
391       <p align="center"><strong>port</strong> </p>\r
393       <p> <strong>Default Setting:</strong> None,\r
394 must be entered. Distributed conf file uses 9032<br>\r
396       <strong>Valid Entries:</strong> Valid port number<br>\r
398       <strong>Required:</strong> Yes, without a port\r
399 setting in the conf file pyTivo will not start.<br>\r
401       <strong>Skill:</strong> Basic<br>\r
403       <strong>Description:</strong> The port which pyTivo\r
404 uses to serve your files. Can be changed if it conflicts with another\r
405 program. It is reported on Ubuntu that this port is already used so you\r
406 may need to change it to something like port=9254.<br>\r
408       <strong>Example Settings:</strong> 9032 </p>\r
410       </div>\r
412       <div id="help-guid" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
413       <p align="center"><strong>guid</strong> </p>\r
415       <p> <strong>Default Setting:</strong> 123456<br>\r
417       <strong>Valid Entries:</strong> Any 6 digit number<br>\r
419       <strong>Required:</strong> Generally NO, will default\r
420 to '123456' if left blank. If you use more than one pyTivo server on\r
421 the same network a different random number is required here.<br>\r
423       <strong>Skill:</strong> Advanced<br>\r
425       <strong>Description:</strong> A unique identifier\r
426 used in the beacon to identify this server. If you have 2 or more\r
427 pyTivo servers on one network each server must use its own unique\r
428 identifier.<br>\r
430       <strong>Example Settings:</strong> Any 6 digit\r
431 number. </p>\r
433       </div>\r
435       <div id="help-ffmpeg" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
436       <p align="center"><strong>ffmpeg</strong>\r
437       </p>\r
439       <p> <strong>Default Setting:</strong> There is\r
440 none.<br>\r
442       <strong>Valid Entries:</strong> Operating system path<br>\r
444       <strong>Required:</strong> Yes! <br>\r
446       <strong>Skill:</strong> Basic<br>\r
448       <strong>Description:</strong> This is the full path\r
449 to your ffmpeg binary. For windows users ffmpeg is distributed with\r
450 pyTivo and is in the plugins/video folder<br>\r
452       <strong>Example Settings:</strong> <span class="underline">Linux</span> = /usr/bin/ffmpeg | <span class="underline">Windows</span> = c:\Program\r
453 Files\pyTivo\plugins\video\ffmpeg_mp2.exe </p>\r
455       </div>\r
457       <div id="help-beacon" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
458       <p align="center"><strong>beacon</strong>\r
459       </p>\r
461       <p> <strong>Default Setting:</strong>\r
462 255.255.255.255<br>\r
464       <strong>Valid Entries:</strong> A Subnet or Listen<br>\r
466       <strong>Required:</strong> No, defaults to\r
467 255.255.255.255<br>\r
469       <strong>Skill:</strong> Advanced<br>\r
471       <strong>Description:</strong> The subnet which the\r
472 beacon should broadcast on. Most people can leave this at the default\r
473 setting. If set to listen will accept incoming TCP requests.<br>\r
475       <strong>Example Settings:</strong> 255.255.255.255 </p>\r
477       </div>\r
479       <div id="help-hack83" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
480       <p align="center"><strong>hack83</strong>\r
481       </p>\r
483       <p> <strong>Default Setting:</strong> False<br>\r
485       <strong>Valid Entries:</strong> True/False<br>\r
487       <strong>Required:</strong> No<br>\r
489       <strong>Skill:</strong> Moderate<br>\r
491       <strong>Description:</strong> Available in the <a class="wiki" href="/wiki/SubFoldersBranch">SubFoldersBranch</a>.\r
492 Allows TiVos with software 8.3 and above to display subfolders as users\r
493 are accustomed too prior to the 8.3Software glitch. If you use this\r
494 then you don't need to use <a href="http://pytivo.armooo.net/wiki/ConfigurepyTivo#auto_subshares">auto_subshares</a>.\r
495       <strong>Warning:</strong> navigating folders too fast\r
496 with this setting enabled may cause <a class="wiki" href="/wiki/TiVo">TiVo</a> to reboot. <br>\r
498       <strong>Example Settings:</strong> True/False </p>\r
500       </div>\r
502       <div id="help-debug" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
503       <p align="center"><strong>debug</strong>\r
504       </p>\r
506       <p> <strong>Default Setting:</strong> False<br>\r
508       <strong>Valid Entries:</strong> True/False<br>\r
510       <strong>Required:</strong> No<br>\r
512       <strong>Skill:</strong> Advanced<br>\r
514       <strong>Description:</strong> Will create a file\r
515 named debug.txt in the base folder of pyTivo. This file will contain\r
516 debug information helpful in diagnosing problems. Generally only\r
517 necessary if you are having a problem and the information is requested\r
518 by support staff.<br>\r
520       <strong>Example Settings:</strong> True/False </p>\r
522       </div>\r
524       <div id="help-optres" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
525       <p align="center"><strong>optres</strong>\r
526       </p>\r
528       <p> <strong>Default Setting:</strong> False<br>\r
530       <strong>Valid Entries:</strong> True/False<br>\r
532       <strong>Required:</strong> No<br>\r
534       <strong>Skill:</strong> Moderate<br>\r
536       <strong>Description:</strong> Allows for the use of\r
537 the Optimal Resolution in transcoding. By setting optes = true pyTivo\r
538 will treat the <a href="http://pytivo.armooo.net/wiki/ConfigurepyTivo#height">height</a>\r
539 and <a href="http://pytivo.armooo.net/wiki/ConfigurepyTivo#width">width</a>\r
540 settings in the conf file as a maximum. If the video to be transcoded\r
541 has smaller dimensions that are closer to other acceptable TiVo\r
542 dimensions then pyTivo will use these dimensions. This allows for\r
543 faster transcoding and small files when the initial video is a lower\r
544 quality.<br>\r
546       <strong>Example Settings:</strong> True/False </p>\r
548       </div>\r
550       <div id="help-audio_br" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
551       <p align="center"><strong>audio_br</strong>\r
552       </p>\r
554       <p> <strong>Default Setting:</strong> 192K<br>\r
556       <strong>Valid Entries:</strong> Any valid Bit rate.\r
557 Up to 384K for SD TiVos. Up to 448K for HD TiVos.<br>\r
559       <strong>Required:</strong> No<br>\r
561       <strong>Skill:</strong> Advanced<br>\r
563       <strong>Description:</strong> This allows you to\r
564 choose the default server audio bit rate used in transcoding. The\r
565 default is likely fine for most users. Users with HD units and high\r
566 quality videos to transcode will want to use higher value. Higher\r
567 values may slow down transcoding and will increase the file size.\r
568 Increased file sizes take up more room on the <a class="wiki" href="/wiki/TiVo">TiVo</a> and take longer to transfer\r
569 over the network.<br>\r
571       <strong>Example Settings:</strong> 192K, 384K, 448K. </p>\r
573       </div>\r
575       <div id="help-max_audio_br" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
576       <p align="center"><strong>max_audio_br</strong>\r
577       </p>\r
579       <p> <strong>Default Setting:</strong> 448K<br>\r
581       <strong>Valid Entries:</strong> Any valid Bit rate. <br>\r
583       <strong>Required:</strong> No<br>\r
585       <strong>Skill:</strong> Advanced<br>\r
587       <strong>Description:</strong> This sets the maximum\r
588 audio bit rate that can be sent to the <a class="wiki" href="/wiki/TiVo">TiVo</a>. Files having a higher bit\r
589 rate will be transcoded to ensure <a class="wiki" href="/wiki/TiVo">TiVo</a> compatibilty. <br>\r
591       <strong>Example Settings:</strong> 384K, 448K. </p>\r
593       </div>\r
595       <div id="help-video_br" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
596       <p align="center"><strong>video_br</strong>\r
597       </p>\r
599       <p> <strong>Default Setting:</strong> 4096K\r
600 for SD <a class="wiki" href="/wiki/TiVo">TiVo</a>'s,\r
601 8192K for HD <a class="wiki" href="/wiki/TiVo">TiVo</a>'s<br>\r
603       <strong>Valid Entries:</strong> Any valid Bit rate.\r
604 1024K = 1Mi<br>\r
606       <strong>Required:</strong> No<br>\r
608       <strong>Skill:</strong> Advanced<br>\r
610       <strong>Description:</strong> This allows you to\r
611 choose the default server video bit rate used in transcoding. FFmpeg\r
612 does not strictly follow this bit rate, there is a certain level of\r
613 tolerance that is allowed. Also a low quality file will always have a\r
614 low bit rate. The default is likely fine for most users. Higher values\r
615 may slow down transcoding and will increase the file size. Increased\r
616 file sizes take up more room on the <a class="wiki" href="/wiki/TiVo">TiVo</a> and take longer to transfer\r
617 over the network.<br>\r
619       <strong>Example Settings:</strong> 4096K, 8Mi, 12Mi </p>\r
621       </div>\r
623       <div id="help-max_video_br" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
624       <p align="center"><strong>max_video_br</strong>\r
625       </p>\r
627       <p> <strong>Default Setting:</strong> 17408k<br>\r
629       <strong>Valid Entries:</strong> Any valid Bit rate.\r
630 1024K = 1Mi<br>\r
632       <strong>Required:</strong> No<br>\r
634       <strong>Skill:</strong> Advanced<br>\r
636       <strong>Description:</strong> This allows you to\r
637 choose the maximum bit rate and is more strict than the <a href="http://pytivo.armooo.net/wiki/ConfigurepyTivo#video_br">video_br</a>\r
638 setting above. However setting this can cause buffer overflows and can\r
639 cause issues with ffmpeg. In addition to setting the ffmpeg maxrate\r
640 option, this setting is used to determine if the video bitrate of the\r
641 source video file is too high for the <a class="wiki" href="/wiki/TiVo">TiVo</a>. Otherwise compatible\r
642 mpeg's with a video bitrate above this setting will be transcoded\r
643 rather than sent to the <a class="wiki" href="/wiki/TiVo">TiVo</a>\r
644 untouched. Raising this setting much higher than the default will likly\r
645 result in pixelation during playback. Recommended only for skilled\r
646 users. <strong>Note:</strong> there is a report that\r
647 ffmpeg throws an error with 17Mi but accepts 17408K just fine. <br>\r
649       <strong>Example Settings: 17408k</strong> </p>\r
651       </div>\r
653       <div id="help-width" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
654       <p align="center"><strong>width</strong>\r
655       </p>\r
657       <p> <strong>Default Setting:</strong> 544<br>\r
659       <strong>Valid Entries:</strong> Any valid pixel\r
660 dimension. Setting will be rounded to nearest acceptable <a class="wiki" href="/wiki/TiVo">TiVo</a>\r
661 dimension<br>\r
663       <strong>Required:</strong> No<br>\r
665       <strong>Skill:</strong> Moderate<br>\r
667       <strong>Description:</strong> Allows you to choose\r
668 the output dimension of the transcoded videos. SD units are limited to\r
669 544 and below. Likely HD users will want to choose a higher value.\r
670 Higher values may slow down transcoding and will increase the file\r
671 size. Increased file sizes take up more room on the TiVo and take\r
672 longer to transfer over the network.<br>\r
674       <strong>Example Settings:</strong> 1920, 1440, 1280,\r
675 720, 704, 544, 480, 352. </p>\r
677       </div>\r
679       <div id="help-height" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
680       <p align="center"><strong>height</strong>\r
681       </p>\r
683       <p> <strong>Default Setting:</strong> 480<br>\r
685       <strong>Valid Entries:</strong> Any valid pixel\r
686 dimension. Setting will be rounded to nearest acceptable <a class="wiki" href="/wiki/TiVo">TiVo</a>\r
687 dimension<br>\r
689       <strong>Required:</strong> No<br>\r
691       <strong>Skill:</strong> Moderate<br>\r
693       <strong>Description:</strong> Allows you to choose\r
694 the output dimension of the transcoded videos. SD units are limited to\r
695 480 and below. Likely HD users will want to choose a higher value.\r
696 Higher values may slow down transcoding and will increase the file\r
697 size. Increased file sizes take up more room on the TiVo and take\r
698 longer to transfer over the network.<br>\r
700       <strong>Example Settings:</strong> 1080, 720, 480 </p>\r
702       </div>\r
704       <div id="help-ffmpeg_prams" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
705       <p align="center"><strong>ffmpeg_prams</strong>\r
706       </p>\r
708       <p> <strong>Default Setting:</strong> -vcodec\r
709 mpeg2video -r 29.97 -b %(video_br)s -maxrate %(max_video_br)s -bufsize\r
710 %(buff_size)s %(aspect_ratio)s -comment pyTivo.py -ac 2 -ab\r
711 %(audio_br)s -ar 44100 -f vob -<br>\r
713       <strong>Valid Entries:</strong> A valid ffmpeg command<br>\r
715       <strong>Required:</strong> No<br>\r
717       <strong>Skill:</strong> Very Advanced<br>\r
719       <strong>Description:</strong> This allows you to\r
720 control the parameters passed to ffmpeg. Most users will be just fine\r
721 with the default setting. Some HD users are experimenting with the\r
722 following line:<br>\r
724 -vcodec mpeg2video -maxrate %(max_video_br)s -qscale 1.2 -bufsize\r
725 %(buff_size)s -comment pyTivo.py -acodec ac3 -ab %(audio_br)s -ar 48000\r
726 -f vob -<br>\r
728 The major difference is that this does not alter the dimensions of the\r
729 video. The native height and width setting of the video used to\r
730 transcode the video. This will only work for HD and S3 units. So far\r
731 there has not been any report of dimensions which the HD units will not\r
732 accept. Additionally this line increases the audio frequency setting to\r
733 48000 too. <strong>Example Settings:</strong> See Above\r
734 and the forum. </p>\r
736       </div>\r
738       <div id="help-bufsize" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
739       <p align="center"><strong>bufsize</strong>\r
740       </p>\r
742       <p> <strong>Default Setting:</strong> 1024k<br>\r
744       <strong>Valid Entries:</strong> Any valid byte size<br>\r
746       <strong>Required:</strong> No<br>\r
748       <strong>Skill:</strong> Very Advanced<br>\r
750       <strong>Description:</strong> Allows you to set the\r
751 buffer size used by ffmpeg. I don't know much about this setting, but\r
752 from what I can tell it is rather touchy and should only be edited by\r
753 advanced users.<br>\r
755       <strong>Example Settings:</strong> 1024k<br>\r
757       </p>\r
759       </div>\r
761       <div id="help-type" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
762       <p align="center"><strong>type</strong> </p>\r
764       <p> <strong>Default Setting:</strong> None<br>\r
766       <strong>Valid Entries:</strong> Video, Music, or any\r
767 other valid plugin name.<br>\r
769       <strong>Required:</strong> Yes<br>\r
771       <strong>Skill:</strong> Basic<br>\r
773       <strong>Description:</strong> Sets the type of share\r
774 that this will be. This must be set to something otherwise pyTivo will\r
775 not start.<br>\r
777       <strong>Example Settings:</strong> Video or Music </p>\r
779       </div>\r
781       <div id="help-path" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
782       <p align="center"><strong>path</strong> </p>\r
784       <p> <strong>Default Setting:</strong> None<br>\r
786       <strong>Valid Entries:</strong> Any operating system\r
787 path<br>\r
789       <strong>Required:</strong> Yes<br>\r
791       <strong>Skill:</strong> Basic<br>\r
793       <strong>Description:</strong> Sets the base path to\r
794 your media content. While pyTivo will start with an invalid path your\r
795 shares will not work at all.<br>\r
797       <strong>Example Settings:</strong> <span class="underline">Windows</span> = C:\videos | <span class="underline">Linux</span> = /home/user/media </p>\r
799       </div>\r
801       <div id="help-subshares" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
802       <p align="center"><strong>auto_subshares</strong>\r
803       </p>\r
805       <p> <strong>Default Setting:</strong> false<br>\r
807       <strong>Valid Entries:</strong> True/False<br>\r
809       <strong>Required:</strong> No<br>\r
811       <strong>Skill:</strong> Moderate<br>\r
813       <strong>Description:</strong> Subfolders of the share\r
814 paths you define will be seen by pyTivo and displayed as subfolders in\r
815 the Now Playing List. This is an alternative to the <a href="http://pytivo.armooo.net/wiki/ConfigurepyTivo#hack83">hack83</a>\r
816 setting which enables the <a class="wiki" href="/wiki/SubFoldersBranch">SubFoldersBranch</a><br>\r
818       <strong>Example Settings:</strong> True/False </p>\r
820       </div>\r
822       <div id="help-precache" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
823       <p align="center"><strong>precache</strong>\r
824       </p>\r
826       <p> <strong>Default Setting:</strong> false<br>\r
828       <strong>Valid Entries:</strong> True/False<br>\r
830       <strong>Required:</strong> No<br>\r
832       <strong>Skill:</strong> Moderate<br>\r
834       <strong>Description:</strong> In order to verify that\r
835 the video files present on your computer were compatible with ffmpeg in\r
836 older versions pyTivo would query ffmpeg for each file. While this\r
837 information was cached it still caused a delay in the initial loading\r
838 of a list of files. This precache setting forced pyTivo to inspect each\r
839 video prior to starting the pyTivo server. However, this had two\r
840 drawbacks. 1. It took time as much as two minutes before pyTivo was\r
841 ready to accept requests. 2. It did not update the cache if new files\r
842 were added while the pyTivo server was running. <br>\r
844 In the more recent releases, anything after Feb 16, 2008, pyTivo no\r
845 longer needs to query ffmpeg when creating a file list. Instead pyTivo\r
846 has a list of accepted video format extensions. If the file extension\r
847 falls within this list it is displayed on the TiVo. This achieves the\r
848 same speed increase as the precache method without the delay in loading\r
849 the pyTivo server. <br>\r
851 There are still two drawbacks to this method. 1. The video file must\r
852 have an extension that is in the list. There is a possibility that a\r
853 new video file extension could come out before pyTivo is updated. 2.\r
854 Incomplete or video files with errors will still appear in the TiVo\r
855 listing if they have the correct extension, even though they are not\r
856 valid files. Both of these concerns are minimal. 1. Very few new\r
857 formats of video files come out very often. And all extensions are\r
858 stored in the video.ext file which is easily edited. 2. When viewing\r
859 the file details before transferring the pyTivo server queries ffmpeg\r
860 to make sure it is valid. If the file is not valid it will show up as a\r
861 copyrighted file and transferring it will be prevented by TiVo. <br>\r
863 It is recommended that you leave precaching turned off as it is no\r
864 longer needed.<br>\r
866       <strong>Example Settings:</strong> True/False </p>\r
868       </div>\r
870       <div id="help-aspect169" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
871       <p align="center"><strong>aspect169</strong>\r
872       </p>\r
874       <p> <strong>Default Setting:</strong> True<br>\r
876       <strong>Valid Entries:</strong> True/False<br>\r
878       <strong>Required:</strong> No<br>\r
880       <strong>Skill:</strong> Moderate<br>\r
882       <strong>Description:</strong> Most TiVos, even S2,\r
883 can handle 16:9 videos perfectly. Some S2s are known not to handle 16:9\r
884 and will default to false in this setting. If you are experiencing\r
885 major distortion you can try setting this to false. Likely mos users\r
886 will not have to mess with this.<br>\r
888       <strong>Example Settings:</strong> True/False </p>\r
890       </div>\r
892       <div id="help-shares" style="position: absolute; left: 0px; top: 0px; visibility: hidden;">\r
893       <p align="center"><strong>shares</strong>\r
894       </p>\r
896       <p> <strong>Default Setting:</strong> Blank,\r
897 which is equivalent to allow all shares on this TiVo.<br>\r
899       <strong>Valid Entries:</strong> The name of any share\r
900 in your pyTivo.conf file. A comma separated list.<br>\r
902       <strong>Required:</strong> No<br>\r
904       <strong>Skill:</strong> Easy<br>\r
906       <strong>Description:</strong> Only the shares listed\r
907 in this setting will be visible on this TiVo. Will ignore invalid\r
908 shares. If no valid shares are listed or the setting does not exist,\r
909 all shares will be visible on this TiVo.<br>\r
911       <strong>Example Settings:</strong> Movies, Kids Stuff\r
912       </p>\r
914       </div>\r
916 <!-- END HELP SECTIONS --> </div>\r
918       </td>\r
920     </tr>\r
922   </tbody>\r
923 </table>\r
924 </center>\r
925 </body>\r
926 </html>\r