Conversion_Kitchen_Code/kitchen_counter/conversion/subtitling/templates/generate.html

175 lines
9.1 KiB
HTML
Raw Permalink Normal View History

2024-04-27 09:33:09 +00:00
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"></script>
<title>Document</title>
</head>
<body>
<div class="container">
<h3 class="mb-5">Welcome to Subtitling!</h3>
<p style="font-size:1.3em;">Get accurate subtitlies in 100 languages across the globe!</p>
<form>
<div class="form-group row">
<div class="col-xs-2" id="qwert">
<label for="video" style="float: right;">Upload Film:</label>
</div>
<div class="col-xs-2">
<input type="file" name="video" id="video" label="Film">
</div>
<div class="col-xs-2">
<label for="script" style="float: right;">Upload Film Script:</label>
</div>
<div class="col-xs-2">
<input type="file" name="script" id="script" label="Film">
</div>
<div class="col-xs-2">
<label style="float: right;">Source Language of video:</label>
</div>
<div class="col-xs-2">
<select class="form-control select2 form-control-md kt-select2" name="lang">
{% for i in lang %}
<option value="{{i}}">{{i}}</option>
{% endfor %}
</select>
</div>
<div class="form-group row">
<div id="qwert">
<button style="margin-left: 45%; padding-left: 30px; padding-right: 30px;"
class="btn btn-danger mx-3" type="submit">Submit</button>
</div>
</div>
</div>
</form>
<script>
function configureDropDownLists(ddl1, ddl2) {
var English = ['Afrikaans', 'Albanian', 'Amharic', 'Arabic', 'Armenian', 'Azerbaijani', 'Basque', 'Belarussian', 'Bengali', 'Bosnian', 'Bulgarian', 'Catalan', 'Cebuanos', 'Chinese', 'Corsican', 'Croatian', 'Czech', 'Danish', 'Dutch', 'English', 'Esperanto', 'Estonian', 'Filipino', 'Finnish', 'French', 'Frisian', 'Galician', 'Georgian', 'German', 'Greek', 'Gujrati', 'Haitian', 'Hausa', 'Hawaiian', 'Hebrew', 'Hindi', 'Hmong', 'Hungarian', 'Icelandic', 'Igbo', 'Indonesian', 'Irish', 'Italian', 'Japanese', 'Javanese', 'Kannada', 'Kazak', 'Khmer', 'Kinyarwanda', 'Korean', 'Kurdish', 'Kyrgyz', 'Lao', 'Latin', 'Latvian', 'Lithuanian', 'Luxembourgish', 'Macedonian', 'Malagasy', 'Malay', 'Maltese', 'Malyalam', 'Maori', 'Marathi', 'Mongolian', 'Myanmar', 'Nepali', 'Norwegian', 'Odia', 'Pashto', 'Persian', 'Polish', 'Portugese', 'Punjabi', 'Romanian', 'Russian', 'Samoan', 'Scots Gaelic', 'Serbian', 'Sesotho', 'Shona', 'Sindhi', 'Singhala', 'Slovak', 'Slovenian', 'Somali', 'Spanish', 'Sudanese', 'Swahili', 'Swedish', 'Tagalog', 'Tamil', 'Tatar', 'Telugu', 'Thai', 'Turkish', 'Turkmen', 'Ukranian', 'Urdu', 'Uyghur', 'Uzbek', 'Vietnamese', 'Welsh', 'Xhosa', 'Yiddish', 'Yoruba', 'Zulu'];
var Hindi = ['English', 'Hindi', 'Malayalam', 'Marathi', 'Tamil', 'Telugu', 'Urdu'];
var Urdu = ['Afrikaans', 'Arabic', 'Belarussian', 'English', 'Greek', 'Hindi', 'Javanese', 'Persian', 'Sindhi', 'Urdu', 'Uzbek'];
var Kannada = ["English","Kannada",'Malayalam','Tamil','Telugu'];
var Marathi = ["English","Marathi", "Punjabi","Gujarati", "Odia", "Chinese-Simplified", "Chinese-Traditional","Nepali","French","Spanish", "Indonesian","Kurdish","Turkmen","Finnish","Haitian Creole","Hawaain","Lithuanian","Luxembourgish","Maltese","Polish","Esperanto","Tatar","Hausa","Somali","Swahili","Yiddish","Albanian","Basque","Catalan","Cebuano","Corsican","Estonian","Frisian","Galician","Haitian Creole","Hmong","Kinyarwanda","Latvian","Maori","Samoan","Scots Gaelic","Sesotho","Shona","Slovak","Xhosa","Zulu"];
var Bengali = ["Bengali","English","Punjabi","Gujarati", "Odia", "Chinese-Simplified","Greek","Javanese","Belarusian","Uzbek","Sindhi","Afrikaans", "Chinese-Traditional","Nepali","French","Spanish", "Indonesian","Kurdish","Turkmen","Finnish","Haitian Creole","Hawaain","Lithuanian","Luxembourgish","Maltese","Polish","Esperanto","Tatar","Hausa","Somali","Swahili","Yiddish","Albanian","Basque","Catalan","Cebuano","Corsican","Estonian","Frisian","Galician","Haitian Creole","Hmong","Kinyarwanda","Latvian","Maori","Samoan","Scots Gaelic","Sesotho","Shona","Slovak","Xhosa","Zulu","Tajik","Uyghur"];
var Arabic = ['Afrikaans', 'Arabic', 'Azerbaijani', 'Belarusian', 'Bengali', 'Bosnian', 'Chinese-Simplified','Chinese-Traditional', 'English', 'French', 'Greek', 'Hausa', 'Javanese', 'Kazakh', 'Kurdish', 'Kyrgyz', 'Macedonian', 'Malagasy', 'Malay', 'Mongolian', 'Pashto', 'Persian', 'Russian', 'Sindhi', 'Somali', 'Spanish', 'Swahili', 'Tajik', 'Tatar', 'Turkish', 'Turkmen', 'Urdu', 'Uyghur', 'Uzbek', 'Yoruba'];
var Tamil = ["English","Kannada","Malayalam","Telugu",'Tamil',];
var Turkish = ["Turkish", "English", 'Indonesian', 'Spanish', 'French', 'Chinese-Simplified', 'Chinese-Traditional', 'Greek', 'Javanese', 'Belarusian', 'Uzbek', 'Sindhi', 'Afrikaans',"Kurdish","Turkmen","Finnish","Haitian Creole","Hawaain","Lithuanian","Luxembourgish","Maltese","Polish","Esperanto","Tatar","Hausa","Somali","Swahili","Yiddish","Albanian","Basque","Catalan","Cebuano","Corsican","Estonian","Frisian","Galician","Haitian Creole","Hmong","Kinyarwanda","Latvian","Maori","Samoan","Scots Gaelic","Sesotho","Shona","Slovak","Xhosa","Zulu"];
var Bulgarian = ['Bulgarian', 'Croatian','Chinese-Simplified','Chinese-Traditional','French','Spanish', 'English','Indonesian', 'Persian', 'Russian', 'Serbian', 'Ukranian',"Greek","Javanese","Belarusian","Uzbek","Sindhi","Afrikaans","Kurdish","Kyrgyz","Turkmen","Finnish","Haitian Creole","Hawaain","Lithuanian","Luxembourgish","Maltese","Polish","Esperanto","Tatar","Hausa","Somali","Swahili","Yiddish","Albanian","Basque","Catalan","Cebuano","Corsican","Estonian","Frisian","Galician","Haitian Creole","Hmong","Kinyarwanda","Latvian","Maori","Samoan","Scots Gaelic","Sesotho","Shona","Slovak","Xhosa","Zulu"];
switch (ddl1.value) {
case 'English':
ddl2.options.length = 0;
for (i = 0; i < English.length; i++) {
createOption(ddl2, English[i], English[i]);
}
break;
case 'Hindi':
ddl2.options.length = 0;
for (i = 0; i < Hindi.length; i++) {
createOption(ddl2, Hindi[i], Hindi[i]);
}
break;
case 'Urdu':
ddl2.options.length = 0;
for (i = 0; i < Urdu.length; i++) {
createOption(ddl2, Urdu[i], Urdu[i]);
}
break;
case 'Kannada':
ddl2.options.length = 0;
for (i = 0; i < Kannada.length; i++) {
createOption(ddl2, Kannada[i], Kannada[i]);
}
break;
case 'Marathi':
ddl2.options.length = 0;
for (i = 0; i < Marathi.length; i++) {
createOption(ddl2, Marathi[i], Marathi[i]);
}
break;
case 'Bengali':
ddl2.options.length = 0;
for (i = 0; i < Bengali.length; i++) {
createOption(ddl2, Bengali[i], Bengali[i]);
}
break;
case 'Arabic':
ddl2.options.length = 0;
for (i = 0; i < Arabic.length; i++) {
createOption(ddl2, Arabic[i], Arabic[i]);
}
break;
case 'Tamil':
ddl2.options.length = 0;
for (i = 0; i < Tamil.length; i++) {
createOption(ddl2, Tamil[i], Tamil[i]);
}
break;
case 'Turkish':
ddl2.options.length = 0;
for (i = 0; i < Turkish.length; i++) {
createOption(ddl2, Turkish[i], Turkish[i]);
}
break;
case 'Bulgarian':
ddl2.options.length = 0;
for (i = 0; i < Bulgarian.length; i++) {
createOption(ddl2, Bulgarian[i], Bulgarian[i]);
}
break;
default:
ddl2.options.length = 0;
break;
}
}
function createOption(ddl, text, value) {
var opt = document.createElement('option');
opt.value = value;
opt.text = text;
ddl.options.add(opt);
}
</script>
</div>
<!-- <script>
const Language = document.getElementById('lang1');
const dropdown = document.getElementById('lang');
function createOption2(elem, key){
var option = document.createElement('option');
option.value = key;
option.innerHTML = key;
elem.appendChild(option)
}
function FirstLanguage(ELE){
const selectedPrimaryObj = subjectObject.find(
(item) => item.ELE === ELE
);
selectedPrimaryObj.options.map((lang) => {
createOptions2(dropdown, lang);
});
}
const codeValue = Language.value;
FirstLanguage(codeValue);
</script> -->
</body>
</html>