vendredi 24 mars 2017

Laravel Database storing only value not array

$visitorphonenumber=DB::select('select phonenumber from visitortable where email=?',[Auth::user()->email]);

$booking=new bookingmodel(); $booking->visitorphonenumber=$visitorphonenumber; this stores the value like [{"phonenumber":"9874589608"}] in database but i want to store only the 9874589608



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire