PHP Code:
stock print_file()
{
// Open a file, path starts from cstrike folder
new fp = fopen("server.cfg"), buffer[100]
// Foef means is it end of file?
while (!foef(fp))
{
// Get the line
fgets(fp, buffer, charsmax(buffer)
// Print it in the server console
server_print("FILE CONTENT: %s", buffer)
}
// Close file handle
fclose(fp)
}
I have not tested it. Wrote it here.
Also check the funcwiki for more function details.
__________________