Weather App wont show temperature

I cant figure out why my code wont show the temperature heres my code thanks for the help

js:
$(document).ready(function() {

if (navigator.geolocation.getCurrentPosition) {
    
  navigator.geolocation.getCurrentPosition(function(position) {
      var latitude = position.coords.latitude;
      var longitude = position.coords.longitude;
   

      
      
    $.getJSON("https://crossorigin.me/https://api.darksky.net/forecast/my api key/" + latitude + ',' + longitude + "?units=auto&exclude=minutily,hourly,daily,alerts", function(responseText,statusText, xhr) { 
                
           
      if (statusText == "success") {
        
                
        
                var splitTimezoneArray = responseText.timezone.split("/"); 
                console.log(splitTimezoneArray);
        
                
        
            /* Celcius */
            if (responseText.flags.units == "si") {
                var celciusFlag = true;
                 $("#temp").html(Math.round(responseText.currently.temperature,-1) + " °C");
                
                $("#temp").click(function() {
                    
                if (celciusFlag) {
                     var f = responseText.currently.temperature * 9/5 + 32;
                    $("#temp").html(Math.round(f,-1) + " °F");
                    
                    celciusFlag = false;
                    
                    }  else {
                     $("#temp").html(Math.round(responseText.currently.temperature,-1) + " °C");
                        
                        celciusFlag = true;
                    }
                
                }); 
        
            /* Fahrenheit */
            } else {
                celciusFlag = false;
                $("#temp").html(Math.round(responseText.currently.temperature,-1) + " °F");
                
                $("#temp").click(function() {
                    
                if (celciusFlag) {
                    $("#temp").html(Math.round(responseText.currently.temperature ,-1) + " °F");
                    
                    celciusFlag = false;
                    
                    }  else {
                      var c = (responseText.currently.temperature - 32) * 5/9;
                    $("#temp").html(Math.round(c,-1) + " °C");
                        
                        celciusFlag = true;
                    }
                
                }); 
            }
            $("#summary").html(responseText.currently.summary);
      
          } else {
              $("#summary").html("There was an error");
              }     
                
            });
      
        }); 
    } 
});

Please post a link to your codepen

Silly question, did you replace “my api key” with your API key?

    $.getJSON("https://crossorigin.me/https://api.darksky.net/forecast/my api key/" + latitude + ',' + longitude + "?units=auto&exclude=minutily,hourly,daily,alerts", function(responseText,statusText, xhr)

i replace my api key with my api key

here is my code pen: https://codepen.io/gavski02/pen/yXVbgw

I tested, the temp shows for me.

interesting its still not showing any temperature for me

The temperature is showing up for me too. Have you waited a few minutes for the temperature to show up? I’ve noticed sometimes it can take a while for the data to be received.

I’ll try and wait longer glad to know its working for others

Check if your browser is blocking location services.

Initially, my temperature wasn’t showing. I then allowed codepen access to my location, and now the temp is showing for me.

Your browser has blocked location services . Go to content setting and allow codepen to retrieve your location .

I have allowed code pen to access my location but still doesn’t work