Posts

How to deploy webapp or war file in tomcat that is running in docker container -

i have created docker container , tomcat running in container. how can deploy webapp or war file in tomcat running in docker container. first create dockerfile: from library/tomcat run rm -rf /usr/local/tomcat/webapps/* add ./relative/path_to_war.war /usr/local/tomcat/webapps/root.war then build docker image $ docker build -t user/image_name . and run docker container. $ docker run --name container_name -p 80:8080 -d user/image_name after webapp should responding on docker host's ip on default http 80 port. you might need link database container webapp, see more on docker documentation

javascript - how to upload file through activeadmin modal window -

i want upload file using modal window,but activeadmin modal module doesn't support . so changed source file of activeadmin, actualy /app/assets/javascripts/active_admin/lib/modal_dialog.js.coffee activeadmin.modal_dialog = (message, inputs, callback)-> html = """<form id="dialog_confirm" title="#{message}"><ul>""" name, type of inputs if /^(datepicker|checkbox|text)$/.test type wrapper = 'input' else if type 'textarea' wrapper = 'textarea' else if $.isarray type [wrapper, elem, opts, type] = ['select', 'option', type, ''] else throw new error "unsupported input type: {#{name}: #{type}}" i add change code if /^(datepicker|checkbox|text)$/.test type if /^(datepicker|checkbox|text|file)$/.test type then can show file form, can't params ,can 1 help? here's code: $('a.upload').click (eve...

ios - How to create top and bottom corner radius different on WatchKit? -

i need set corner radius 6 on top of wkinterfacegroup , set 0 on bottom. there tips or ? thanks example : http://imgur.com/adasbny since many elements (images e. g.) can't given border radius in watchos, should use groups images element. in order achieve 2 different border sizes, try using 2 groups 2 different border sizes overlap themselves, 1 side of border isn't visible because it's overlapped other group.

debugging - Using console to access Meteor Template.name.helpers functions -

in meteor application, suppose have following template: template.templatename.helpers({ helper1: function () { alert("helper function called") } } how call helper1 function browser console? edit: 1 solution: template.templatename.__helpers[" helper1"]() is there more orthodox way?

html - On Edge Browser, how to change input placeholder text color using CSS? -

on edge browser, couldn't able change input placeholder color. :-ms-input-placeholder not working works fine on ie 10 & ie 11 . input:-ms-input-placeholder { font-style:italic; color: red; background-color: yellow; } is there anyway make work using css? from caniuse.com ::-webkit-input-placeholder (chrome/safari/opera) :-ms-input-placeholder ie. ::-ms-input-placeholder edge (also supports webkit prefix) note double colon syntax

html5 - HTML 5 - Do I need to declare DOCTYPE on includes and pages with decorator -

i'm using struts 2 , working through pages make them html 5 compliant. all pages using single decorator jsp declared in decorators.xml the decorator.jsp includes first line: <!doctype html> do need declare first line on pages (specified in struts.xml ) <!doctype html> on these? if yes, need same <s:include /> ed pages? the doctype declaration should first line of html document rendered result. can place space characters, comments, or bom character before doctype . see conformant documents in html syntax . pages decorated in head or body of document doctype should before these tags , before tag. place doctype on every page @ first line, either included or manual, , use page decorator. doctype declaration should rendered once per html document, shouldn't include every page <s:include/> -ed in main page.

angularjs - "show more" directive for angular material autocomplete in md-menu-class -

i using angular material autocomplete show results.everything coming perfect except want show results in set of 10 in dropdown , have "show more" kind of utility after last result in dropdown handle event next 10 results. has tried hook directive in md-menu-class template achieve same. here in md-autocomplete code in jade md-autocomplete(md-selected-item="selecteditem",md-search-text-change="textchange()", md-selected-item-change = "itemchange(item)", md-search-text="searchtext",md-items="item in getautosuggest(searchtext)",md-item-text="item.fields.input[0]",md-min-length="3",md-floating-label="search",hide-sm,show-gt-sm) md-item-template span(md-highlight-text="searchtext",md-highlight-flags="^i"){{item.fields.virgininput[0]}} in {{item.fields.location[0]}} in {{item.fields.identifier[0]}} ...