Search
Generic filters
Exact matches only
  • Global Variables in JavaScript

    25th April 2014

    Javascript

    javascript category codehaven

    If you declare a variable outside of a function, it becomes global.
    If you have problems, you can attach the variable to the window.

    and check it by

    Was this code snippet helpful?

    Comment on this Code Snippet?