PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
snicolas
Forum Commoner
Posts: 97 Joined: Tue Nov 09, 2004 8:32 am
Post
by snicolas » Mon Feb 07, 2005 11:01 am
hI gUYS,
sORRY I KNOW IT'S 5 PM HERE BUT I NEED SOME HELP
I have a variable containing value as
$value=5;
I need to insert this value in my db (SQLS ERVER) as 00005.
I know i should use Format() but i am not sure about the way to do it.
thx in advance
s
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Mon Feb 07, 2005 11:07 am
sprintf('%05d', $value);
please don't place "urgent" or any other mark such as that in your topic titles.
snicolas
Forum Commoner
Posts: 97 Joined: Tue Nov 09, 2004 8:32 am
Post
by snicolas » Mon Feb 07, 2005 11:09 am
cheers feyd, you're the man.....
s