Ask coding questions

← Back to all posts
Ok why isn't this working? (JAVASCRIPT)
AzureScripts (150)

If you check join.html.
I am trying to make a CTF challenge where you need to try and get into the Admin panel by finding out the username and password.

But however, when i click "Login" nothing happens?
Please tell me how to fix this!

Commentshotnewtop
vedprad1 (732)

I believe that the problem is with the onclick attribute in the button. The way you did it is:

<button onclick("[ID of script]")>Login</button>

However, I don't think that is valid.
You are supposed to do it like this.

<button onclick="[function or code]">Login</button>

So put all of your script code in a function, and use the above format to activate the button.

If this answers your question, please check the checkmark on the left side of this message. Thanks and Good Luck!