Menu
Is this the correct syntax?
// Determine domain used to access site
if (top.location.host.indexOf(‘.com’)) {
var DefaultURL = ‘
}
if (top.location.host.indexOf(‘.org’)) {
var DefaultURL = ‘
}
I need assign this variable based on how the site was accessed — either .org or .com. Thank you for your help!