14.07.2016, 07:53
Write arbitrary data to the database you can be achieved by simple conversion:
Output data StringToHexString is two times greater than the input data.
Include:
ADM.inc
PHP Code:
//Save example:
new tmpInput[256], tmpOutput[256 * 2];
format(tmpInput,sizeof tmpInput,"sdnajnda\n\tćłśą ...");
StringToHexString(tmpInput,tmpOutput);
//tmpOutput = "73646E616A6E64615C6E5C74E6B39CB9202E2E2E" - save this
//Load example:
new tmp_data[256], tmp_hexdata[256 * 2];
tmp_hexdata = "73646E616A6E64615C6E5C74E6B39CB9202E2E2E";
HexStringToString(tmp_hexdata,tmp_data);
//tmp_data = "sdnajnda\n\tćłśą ..."
Include:
ADM.inc