locked
Need to call a c# function from a script async render src RRS feed

  • Question

  • Hello

    I have this script in a aspx page

        <script

            src="https://maps.googleapis.com/maps/api/js?key=" + "<%=LeerWebKey() %>" + "&callback=initMap">

        </script>

    And in aspx.cs code file I have

        public string LeerWebKey()

        {

            return (string)Session["GoogleMaps_WebKey"];

        }

    Works fine, I can see my map

    But I need to make the script async defer

        <script async defer

            src="https://maps.googleapis.com/maps/api/js?key=" + "<%=LeerWebKey() %>" + "&callback=initMap">

        </script>

    I cannot see the map

    Any ideas?

    Regards

    Rubenc


    Saludos rubenc http://foro.controlc.com.mx

    • Moved by Bill_Stewart Friday, March 15, 2019 6:40 PM Off-topic
    Tuesday, January 29, 2019 12:27 AM

All replies

  • This is not an ASP.Net forum.  You need to post here: http://forums.asp.net

    This is an administrative scripting forum and not an IIS forum.


    \_(ツ)_/

    Tuesday, January 29, 2019 12:37 AM
  • sorry


    Saludos rubenc http://foro.controlc.com.mx

    Tuesday, January 29, 2019 12:42 AM
  • Not a problem.  Most people think C# is a scripting language.


    \_(ツ)_/

    Tuesday, January 29, 2019 1:02 AM