Arguement type mismatch (arguement 3)
#1

PHP код:
new INI:File INI_Open(UserPath(playerid));
new 
plrIP[16];
GetPlayerIp(playeridplrIPsizeof(plrIP));
INI_WriteInt(File"IP"plrIP);
INI_Close(File); 
Did I do something wrong here? The error line is this
PHP код:
INI_WriteInt(File"IP"plrIP); 
Reply
#2

GetPlayerIp(); return a string so plrIP var will be a string
and 3rd arguement on INI_WriteInt(_, _,int); is an integer
you can use INI_WriteString() for this purpose
Reply
#3

You use WriteInt for a string...a string is not an Integer...

So use INI_WriteString
Reply
#4

Oh...
Never used GetPlayerIp before. Thanks! +rep

EDIT: Kaliber, the system is not letting me give you a rep. lol I'll give you soon.
Reply
#5

Sorry for bumping

PHP код:
INI_WriteString(File,"Password",strval(inputtext)); //I'm just curious if you can save a user's password without using any hash. 
It's called on OnDialogResponse
Reply
#6

No, you should NEVER save a user's un-hashed password. It's a breach of their personal security and is in most cases illegal.

This function was added for people who refused to use includes or plugins that were required for more secure hashes:
https://sampwiki.blast.hk/wiki/SHA256_PassHash

Another popular method is Whirlpool:
https://sampforum.blast.hk/showthread.php?tid=570945

If you don't know how to use SHA256_PassHash, here's a small tutorial for you:
https://sampforum.blast.hk/showthread.php?tid=581336
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)