fwrite_blocks
Hey guys.
I make a string: PHP Code:
PHP Code:
PHP Code:
"blabla[NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL][NULL].... etc...." at the amount of 65 (which is the str length) - blabla characters, which is 6. I see it then 59 times. Why is that? I do the EOS thing, what is wrong with the code? (there is no code to show, its really only these 3 lines after I fopen(some_file_i_opened, "rt+") |
Re: fwrite_blocks
You are writing the entire string to the file. The EOS is the NULL character, which is repeated after "blabla" because the string is empty.
If you only want to write "blabla" then you should use strlen(str) instead of charsmax(str) in fwrite_blocks. |
Re: fwrite_blocks
Quote:
Thanks. |
| All times are GMT -4. The time now is 07:49. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.