php - How can i make all array values in variable -


this question has answer here:

i want make array values in 1 variable

example:

i have title

$title = "my name medo"; $words = explode(' ', $title); 

the result a

$words['0'] = $words['1'] = name  $words['2'] =  $words['3'] = medo 

i want make that

$allwords = "my,name,is,medo"; 

thanks all

you can use implode:

implode ( "," , $words ); 

Comments

Popular posts from this blog

javascript - RequestAnimationFrame not working when exiting fullscreen switching space on Safari -

Python ctypes access violation with const pointer arguments -