Use implode
implode("|",$type);
More Related Contents:
- Array Comparision with a string PHP
- Split a comma-delimited string into an array?
- Remove empty array elements
- Parse query string into an array
- How create an array from the output of an array printed with print_r?
- Convert backslash-delimited string into an associative array
- Convert a comma-delimited string into array of integers?
- Convert flat array to a delimited string to be saved in the database
- String with array structure to Array [duplicate]
- php implode (101) with quotes
- use strings to access (potentially large) multidimensional arrays
- How to split a long string without breaking words?
- String contains any items in an array (case insensitive)
- Convert a String into an Array of Characters
- Merge array items into string
- How to cast array elements to strings in PHP?
- PHP: Split string into array, like explode with no delimiter
- Search and replace multiple values with multiple/different values in PHP5?
- Explode string into array with no empty elements?
- Fastest way of deleting a value in a comma separated list
- PHP get values from SimpleXMLElement array
- How to implode array with key and value without foreach in PHP
- How to convert array values to lowercase in PHP?
- Convert a String to Variable
- Search and replace multiple values with multiple/different values in PHP?
- Check if string contains word in array [duplicate]
- Merge two arrays as key value pairs in PHP
- php – How do I fix this illegal offset type error
- PHP array_filter with arguments
- How are associative arrays implemented in PHP?