Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* I'm trying to make an extremely simple chrome extension that alerts something when you click a button, but it's not working. Can anyone help? This is what I have right now: */
- //**popup.html**
- <html>
- <body>
- <input type = "button" id = "aButton" value = "My button" ></input>
- </body>
- </html>
- //**popup.js**
- src = "http://code.jquery.com/jquery-1.10.2.js"
- $(document).ready(function() {
- $("#aButton").click(function() {
- alert("You clicked me!")
- })
- })
- //**manifest.json**
- {
- "manifest_version": 2,
- "name": "Test",
- "description": "Test Extension",
- "version": "1.0",
- "icons": {
- "48": "icon.png"
- },
- "permissions": [
- "http://*/*",
- "https://*/*"
- ],
- "browser_action": {
- "default_title": "This is a test",
- "default_icon": "icon.png",
- "default_popup": "popup.html"
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement