X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/351e2a633425b85d99a284b8836f375f81cc8dce..2422dc2dcc6f61e6c7e905862bd670eb11939050:/platforma/static/js/main.js?ds=sidebyside diff --git a/platforma/static/js/main.js b/platforma/static/js/main.js index ddbe756b..0928bf8d 100644 --- a/platforma/static/js/main.js +++ b/platforma/static/js/main.js @@ -1,5 +1,5 @@ -if (!console) { - console = { +if (!window.console) { + window.console = { log: function() {} } } @@ -94,7 +94,7 @@ function gallery(element, url) { zoom(); }); $('.change-gallery', element).click(function() { - $('.chosen-gallery').val($('#document-meta .gallery').html() || STATIC_URL + 'gallery/'); + $('.chosen-gallery').val($('#document-meta .gallery').html() || '/platforma/gallery/'); $('.gallery-image').animate({top: 53}, 200); $('.chosen-gallery').focus(); }); @@ -361,8 +361,8 @@ $(function() { CodeMirror.fromTextArea('id_text', { parserfile: 'parsexml.js', - path: "/static/js/lib/codemirror/", - stylesheet: "/static/css/xmlcolors.css", + path: STATIC_URL + "js/lib/codemirror/", + stylesheet: STATIC_URL + "css/xmlcolors.css", parserConfig: { useHTMLKludges: false },