Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not use iframe for whole button #156

Open
techboyg5 opened this issue Jul 26, 2020 · 3 comments
Open

Do not use iframe for whole button #156

techboyg5 opened this issue Jul 26, 2020 · 3 comments

Comments

@techboyg5
Copy link

Instead, use img with a inside on native document. iframes should be used only for count.

@AadiSharma49
Copy link

I just create an example using HTML,CSS,JS to not use iframe

<title>Button without iframe</title>

Click Me

<script src="script.js"></script>

@AadiSharma49
Copy link

AadiSharma49 commented Sep 25, 2024

#myButton {
background-color: #4CAF50;
border: none;
color: white;
padding: 15px 32px;
text-align: center;
text-decoration: none;
display: inline-block;
font-size: 16px;
margin: 4px 2px;
cursor: pointer;
border-radius: 8px;
}

#myButton:hover {
background-color: #45a049;
}

@AadiSharma49
Copy link

// Adding a click event listener to the button
document.getElementById("myButton").addEventListener("click", function() {
alert("Button clicked!");
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants