This file contains hidden or 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
public class MailgunWebhook extends HttpServlet { | |
private static final long serialVersionUID = 1L; | |
public void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { | |
try { | |
resp.setContentType("application/json"); | |
String token = null; |
This file contains hidden or 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
body { | |
padding: 20px; | |
} | |
div { | |
width: 200px; | |
height: 200px; | |
margin-right: 20px; | |
overflow-y: scroll; /* has to be scroll, not auto */ | |
float: left; |
This file contains hidden or 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
/** | |
* Finding number of times subarray repeats in array <br> | |
* @param array must be >= @param subarray | |
* @return # of subarray repeats or 0 | |
*/ | |
public int findSubarrayCount(List<String> array, List<String> subarray, int fromIndex) { | |
int cntTotal = 0; | |
String firstElement = null; | |
if (subarray.size() > 0) { |
This file contains hidden or 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
{ | |
"BD": { | |
"alpha_2": "BD", | |
"name": "Bangladesh" | |
}, | |
"BE": { | |
"alpha_2": "BE", | |
"name": "Belgium" | |
}, | |
"BF": { |
This file contains hidden or 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
# Eclipse | |
.classpath | |
.project | |
.settings/ | |
# Intellij | |
.idea/ | |
*.iml | |
*.iws |
This file contains hidden or 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
Tomcat7 add to config: | |
<Host name="localhost" appBase="webapps" | |
unpackWARs="true" autoDeploy="true"> | |
<Context path="" docBase="administracija"> | |
<WatchedResource>WEB-INF/web.xml</WatchedResource> | |
</Context> | |
<!-- SingleSignOn valve, share authentication between web applications | |
Documentation at: /docs/config/valve.html --> |
NewerOlder