How to write \ simbols to mysql?
#10

Eh, I think that function won't do what you want.
Try this:
PHP код:
ReplaceNewString(string[])
{
    for(new 
i;strlen(string) < i;i++)
    {
        if(
string[i] == '|' && string[i+1] == 'n')string[i] = '\';
        else if(string[i] == '
\' && string[i+1] == 'n')string[i] = '|';
    }

So you can convert "\n" into "|n" and you can save this into your mysql database. When you read this and save it in a string you convert it to "\n" back.
Reply


Messages In This Thread
How to write \ simbols to mysql? - by StRaphael - 18.11.2018, 18:17
Re: How to write \ simbols to mysql? - by Jefff - 18.11.2018, 19:07
Re: How to write \ simbols to mysql? - by StRaphael - 18.11.2018, 19:08
Re: How to write \ simbols to mysql? - by Jefff - 18.11.2018, 19:28
Re: How to write \ simbols to mysql? - by StRaphael - 18.11.2018, 20:05
Re: How to write \ simbols to mysql? - by Jefff - 18.11.2018, 22:21
Re: How to write \ simbols to mysql? - by StRaphael - 19.11.2018, 16:27
Re: How to write \ simbols to mysql? - by Mencent - 19.11.2018, 16:30
Re: How to write \ simbols to mysql? - by StRaphael - 19.11.2018, 16:44
Re: How to write \ simbols to mysql? - by Mencent - 19.11.2018, 17:00

Forum Jump:


Users browsing this thread: 2 Guest(s)