Jump to content

[SOLVED] replace "-" with "/"


inferium

Recommended Posts

Hey all,

 

So I have this problem. I've got a program set up that sends out data to another system, and we have to convert it a certain way to where theirs will accept it.

 

Now, the only piece of information that isn't sending correctly is the 'dob'. I need the dashes in the birthdate (it's in our system as mm-dd-yyyy) to be replaced with dashes. How could I alter the following code to allow me to do this. Thanks in advance!!!  :)

 

'work_phone'             => preg_replace('/[^0-9]/i','',$value['leadWorkPhone']),

'email'                  => $value['leadEmail'], 

'ssn' 			 => preg_replace('/[^0-9]/i','',$value['leadSSN']),

'dob'             	 => preg_replace('/[^0-9]/i','',$value['leadBirthdate']),

Link to comment
https://forums.phpfreaks.com/topic/156453-solved-replace-with/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.