Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript join address to string

var address = "foo";
var city;
var state = "bar";
var zip;

text = [address, city, state, zip].filter(Boolean).join(", ");
console.log(text)
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #javascript #join #address #string
ADD COMMENT
Topic
Name
8+8 =