2017-09-14 21:39:01 +02:00
|
|
|
$(function() {
|
|
|
|
$.getJSON('js/apps.json', function(data) {
|
2017-10-14 11:18:05 +02:00
|
|
|
$.each(data, function(id, props) {
|
|
|
|
var div = $('#'+id).show();
|
2017-12-02 00:53:07 +01:00
|
|
|
if (props.hasOwnProperty('url')) {
|
|
|
|
var url = props.url.replace('{host}', window.location.hostname);
|
|
|
|
div.find('h2 a').attr('href', url);
|
|
|
|
div.find('.url').text(url);
|
|
|
|
}
|
2017-10-14 11:18:05 +02:00
|
|
|
if (props.hasOwnProperty('login'))
|
|
|
|
div.find('.login').text(props.login);
|
|
|
|
if (props.hasOwnProperty('password'))
|
|
|
|
div.find('.password').text(props.password);
|
2017-09-14 21:39:01 +02:00
|
|
|
});
|
|
|
|
});
|
|
|
|
});
|