I am revisiting C strings, trying to get hang of the pesky things. I am attempting to make a set of functions to get, parse and manipulate strings etc.

This is my first function which gets user input. My hope was to create a very generic function which can be used in most circumstances. I wondered if there is a chance of getting some critical feedback on it - are there better ways to do it, are there risks of writing past the array limits, how could it be improved etc

would people go for dynamic memory allocation instead? I had the impression there is a trade off between extra resources in using dynamic memory vs flexibility it offers. Would it be better to write 2 functions - one for dynamic allocation (potentially very large character arrays) and one for static allocation (smaller arrays) or just one catch all function?

Sorry for all the questions. Just want to get the hang of this once and for all. Thanks in advance for any help with this

Here's the function

Code:
char * GC_GetUserInput() {
    printf("\n::  ");
    char temp[256];
    for (int i = 0; i < 256; i++) {
        temp[i] = '\0';
    }

    int len = 0;
    char * text;
    char c;
    c = fgetc(stdin);
    while (c != '\n') {
        printf("\n%c", c);
        if ((len = strlen(temp)) < 255) {
            temp[len] = c;
            c = fgetc(stdin);
        }
        else {
            temp[len] = '\0';
            c = '\n';
        }            
    }
    text = temp;
    return text;
}