k to me this sounds a bit wierd based on the fact that on declaration of variables you dont set data types
i.e int $varname, you just go ahead and whatever you want in var name without setting a type in php. but i've been having this lil problem.
PHP Code:
$socialsecurity = 123456789;
$date = date('y');
$manid = $socialsecurity . $date
manid should be equal to 123456789 + the year wich is 05 making it 12345678905 now when i pass that value for manid into my object constructor { yes, i'm using object orientation in php} and assign it to the id for the person object the value is a completely different thing it becomes 21226.... [ cant remember the exact value ] but i really don't understand the problem.
i tried making the id being the socialsecurity alone i.e [123456789] and it was passproperly and assigned properly an in the object the value was the same, but when i concatanate it with the date i get that other number.
so i was thinking is it a situation where i'm concatanating 2 different datatypes bing an int and a date , would i need to convert both to strings [ cuase i have no problem with storing it in the backend as a string aslong as the data is accurate.
so if ne body know how to covert form date to string or better yet the contents of a variable to a string let me know please. if you havene suggestions toma problem i welcome it.