Question: I just learned how to implement specific rounded corners, but now it seems nothing will align to the top of the screen, even with spacers. How can I get it to align to the top of the screen?

Additionally, I would like the green to ignore the top safe area, but it wasn't doing that earlier either.

```
import SwiftUI

struct Dashboard: View {

    @State var bottomLeft: CGFloat = 25

    var body: some View {
        ZStack {
            Color("background")
                .edgesIgnoringSafeArea(.all)

            VStack {
                VStack {
                    Text("Good Morning, Sarah")
                        .font(Font.system(size: 36))
                        .foregroundColor(.standaloneLabelColor)
                        .fontWeight(.semibold)
                        .frame(maxWidth: .infinity, alignment: .leading)
                        .padding(.horizontal)

                    Text("We're glad to see you and hope you're doing well. Let's take on the day.")
                        .font(Font.system(size: 20))
                        .foregroundColor(.standaloneLabelColor)
                        .frame(maxWidth: .infinity, alignment: .leading)
                        .padding(.horizontal)
                        .padding(.bottom)
                }
                .background(Color.appColor)
                .cornerRadius(bottomLeft, corners: .bottomLeft)
                .padding(.bottom, 10)

        }

            Spacer()
        }

    }
}

```

Thanks in advance.

Answer: 
Can you try the below code, I have used php file\_get\_contents instead of wordpress finction, I hope that will make sense to you

```
$body = trim(file_get_contents('https://loopwi.com/json'), "\xEF\xBB\xBF");
$json = json_decode($body);
echo $json->message;  
echo $json['message'];

```

Refer [link](https://stackoverflow.com/questions/38469427/php-file-get-contents-with-json-decode-not-working-together) for explanation
Thanks guys for your replies. As @Ajith pointed out regarding trim(); by using

```
trim();

```

function on the response body, the problem solves.
There are ways to achieve this:

```
$response = wp_remote_request( "https://loopwi.com/json");
$body = trim(wp_remote_retrieve_body($response), "\xEF\xBB\xBF"); 
$body = trim($body, "\xEF\xBB\xBF"); 
$json = json_decode($body);
echo $json->message; 

```

Or by this:

```
$url = "https://loopwi.com/json";
$response = wp_remote_get( $url );

if ( is_array( $response ) && ! is_wp_error( $response ) ) {
    $headers = $response['headers']; // array of http header lines
    $body    = trim($response['body'], "\xEF\xBB\xBF"); // use the content
    $json = json_decode($body);
       echo $json->status; 
       echo $json->message;
}

```

These are functions in the WordPress WordPress's
HTTP API - wp\_remote\_get, wp\_remote\_request

Your project may get rejected if you use file\_get\_contents() in WordPress. Use the HTTP API functions instead.

Thanks for all those who answered and commented. Cheers!