Created
July 19, 2019 15:22
-
-
Save bjoerntx/65233add661cfd476ea2e8182970dc0c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// get available dictionary names and add them to select element | |
function getUserDictionaryFilenames() { | |
var serviceURL = "/api/Dictionary/UserDictionaryFilenames/"; | |
$.ajax({ | |
type: "GET", | |
url: serviceURL, | |
contentType: 'application/json', | |
success: successFunc, | |
error: errorFunc | |
}); | |
function successFunc(data, status) { | |
data.forEach(function (item) { | |
// append the options | |
$("#availableDictionaries").append("<option>" + item + "</option>"); | |
}); | |
} | |
function errorFunc() { | |
console.log("error"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment