Hi guys,
I need to store user IP addresses in my database and I've found out that storing them using the INET_ATON() function is the best way, as it only takes up 7 bytes if you store it as an unsigned integer.
Unfortunately I get this Fatal Error: Fatal error: Call to undefined function inet_aton() in …..
Here is my query:
PHP Code:
<?php $db_query = "INSERT INTO `test1`.`comments` (`comment_title`, `nickname_ID`, `ip_ID`, `comment_text`) VALUES ('".mysql_real_escape_string($formtitle)."', '".mysql_real_escape_string($formname)."', '".inet_aton($userIP)."', '".mysql_real_escape_string($formtext)."');"; ?>
Except for the inet_aton() bit, everything else is working fine. But how can inet_aton() be an undefined function when it is a built in MySQL function?
__________________
THE FORCE is with me at last! All I need now is some TALKUPATION ;)
|