How to detect \n when loading from SQL to string?
#2

In save use some special character for \n for example #

pawn Код:
SaveMyString(str[])
{
    for(new i = strlen(str) - 1; i > -1; i--)
        if(str[i] == '\n')
            str[i] = '#';
}
next in loading

pawn Код:
ReplaceChar(str[])
{
    for(new i = strlen(str) - 1; i > -1; i--)
        if(str[i] == '#')
            str[i] = '\n';
}
Reply


Messages In This Thread
How to detect \n when loading from SQL to string? - by czop1223 - 01.09.2016, 19:45
Re: How to detect \n when loading from SQL to string? - by Jefff - 01.09.2016, 19:51

Forum Jump:


Users browsing this thread: 1 Guest(s)