[GIS] How to add href to popup (infoWindow) in ArcGIS API

arcgis-javascript-apiarcgis-serverjavascript

I'm a newbie in programming. I'm trying to make a href link inside of arcGIS js infoWindow (popup). I don't know how to make this link work. The code that I'm trying is shown below.
Could you please suggest a solution?

    map.on("click", addPoint);
    function addPoint(evt) {
        var latitude = evt.mapPoint.getLatitude();
        var longitude = evt.mapPoint.getLongitude();
        var link = "<a href="www.google.com">Google Office</a>"
        map.infoWindow.setTitle("Coordinates");
        map.infoWindow.setContent(
          "lat: " + latitude.toFixed(7) + "<br> lon: " + longitude.toFixed(7) + "<br> Link: " + link
        );
        map.infoWindow.show(evt.mapPoint, map.getInfoWindowAnchor(evt.screenPoint));
      };

Best Answer

It should work if you replace "www.google.com" with 'http://www.google.com' (note the single quotes).

var link = "<a href='http://www.google.com'>Google Office</a>"