how to put a javascript variable in an alert code example Example: javascript alert variable var text = "hello world"; alert(text);