Grow your CSS skills. Land your dream job.

Last updated on:

Basic Alert

<script type="text/javascript">
       alert('ALERT!')
</script>

Comments

  1. Dhaval

    This is very nice as a designer i have to find some where else and not get proper way for alert

    thanks

  2. Will this alert on by clicking or on page load ?

  3. Permalink to comment#

    Wonderful, I was looking everywhere on the internet since hours to know how to do such a thing, now I’m gunna do that on all my website page !!

    But I still have a question though, is it possible to change the message ALERT! into something else, like HELLO! or something ?

    Thanks for your help !

    • Elijah
      Permalink to comment#

      Julia, yes you can. You just edit the “ALERT!” to whatever you want it to be.

  4. Reem
    Permalink to comment#

    it is very easy please upload more examples so i can clear the concept

Leave a Comment

Posting Code

Markdown is supported in the comment area, so you can write inline code in backticks like `this` or multiline blocks of code in in triple backtick fences like ```this```. You don't need to escape code in backticks, Markdown does that for you.

Sadly, it's kind of broken. WordPress only accepts a subset of HTML in comments, which makes sense, because certainly some HTML can't be allowed, like <script> tags. But this stripping happens before the comment is processed by Markdown (via Jetpack). It seems to me that would be reversed, because after Markdown processes code in backticks, it's escaped, thus safe. If you think you can fix this issue, get in touch!

If you need to make sure the code (typically HTML) you post absolutely posts correctly, escape it and put it within <pre><code> tags.

Current ye@r *

*May or may not contain any actual "CSS" or "Tricks".