What do you want to save?
Add Code snippet
New code examples
-
Javascript 2021-09-30 02:12:04
event bubbling in javascript
<script> form.onclick = function(event) { event.target.style.backgroundColor = 'yellow'; // chrome needs some time to paint yellow setTimeout(() => { alert("target = " + event.target.tagName + ", this=" + this.tagN... Add solution -
Javascript 2021-09-28 19:26:04
javascript document.createElement add function
var newTH = document.createElement('th'); newTH.innerHTML = 'Hello, World!'; newTH.onclick = function () { this.parentElement.removeChild(this); }; var table = document.getElementById('content'); table.appendChild(newTH); Add solution -
Javascript 2021-09-28 10:36:06
how to get values from select multiple in js
document.getElementById('submit').onclick = function() { var selected = []; for (var option of document.getElementById('pets').options) { if (option.selected) { selected.p... Add solution -
Java 2021-09-28 03:19:04
simple yes no dialog android default java
DialogInterface.OnClickListener dialogClickListener = new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int which) { switch (which){ case DialogInterface.BUTTON_POSITIVE: //Ye... Add solution -
Javascript 2021-09-27 20:45:02
js copy paragraph onclick
var copy = document.querySelectorAll(".copy"); for (const copied of copy) { copied.onclick = function() { document.execCommand("copy"); }; copied.addEventListener("copy", function(event) { event.preventD... Add solution -
C# 2021-09-26 00:44:02
unity ads tutorial
using UnityEngine; using UnityEngine.UI; using UnityEngine.Advertisements; // how to start a rewarded ad in unity games after pressign a button [RequireComponent (typeof (Button))] public class RewardedAdsButton : MonoBehaviour, IUnityAdsListener { ... Add solution -
Javascript 2021-09-25 22:47:03
build a trivia and answer javascript
// code by webdevtrick (https://webdevtrick.com) function Quiz(questions) { this.score = 0; this.questions = questions; this.questionIndex = 0; } Quiz.prototype.getQuestionInde... Add solution -
Java 2021-09-25 15:49:02
create notification android
package com.example.notificationdemo; import android.app.Activity; import android.app.NotificationManager; import android.app.PendingIntent; import android.content.Context; import android.content.Intent; import android.support.v4.app.NotificationCompat; ... Add solution -
Java 2021-09-25 09:16:04
not running on tomcat manager app
package com.onclickinfo.tnoadmin; import java.io.IOException; import javax.servlet.Filter; import javax.servlet.FilterChain; import javax.servlet.FilterConfig; import javax.servlet.ServletException; import javax.servlet.ServletRequest; import javax.servl... Add solution
Best helpers
Ranking is empty