How to convert an array to a string in PHP

0 votes

What can I do to get the array values and store them as a comma-separated string?

Array ( [0] => 33160,
        [1] => 33280,
        [2] => 33180,
        [3] => 33163,
        [4] => 33181,
        [5] => 33164,
        [6] => 33162,
        [7] => 33179,
        [8] => 33154,
        [9] => 33008,
        [10] => 33009,
        [11] => 33161,
        [12] => 33261,
        [13] => 33269,
        [14] => 33169,
        [15] => 33022,
        [16] => 33141,
        [17] => 33168,
        [18] => 33020,
        [19] => 33023,
        [20] => 33019,
        [21] => 33153,
        [22] => 33238,
        [23] => 33138,
        [24] => 33167,
        [25] => 33082,) 
May 30 in PHP by Kichu
• 19,040 points
15 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In PHP

0 votes
0 answers

How to convert a string to an array in php

I want to convert a string into ...READ MORE

Jun 1 in PHP by Kichu
• 19,040 points
10 views
0 votes
1 answer

How to convert a string to JSON object in PHP?

Hello @kartik, it seems that your JSON is ...READ MORE

answered Oct 20, 2020 in PHP by Niroj
• 82,720 points
2,177 views
0 votes
1 answer

How to check if a string is an email address in PHP?

Hello, Try this without regular expressions: <?php ...READ MORE

answered Nov 3, 2020 in PHP by Niroj
• 82,720 points
364 views
0 votes
1 answer

How do I convert a string to a number in PHP?

You don't have to do this, since ...READ MORE

answered Feb 23 in PHP by Aditya
• 7,280 points
62 views
0 votes
0 answers

How to convert an array to object in PHP?

How can I convert an array like ...READ MORE

Jun 18 in PHP by narikkadan
• 10,640 points
8 views
0 votes
1 answer

How to pass an array within a query string?

Hello, Submitting multi-value form fields, i.e. submitting arrays ...READ MORE

answered Apr 8, 2020 in PHP by Niroj
• 82,720 points
9,767 views
0 votes
1 answer

How to check if array is multidimensional or not?

Since the 'second dimension' could be just ...READ MORE

answered Nov 5, 2018 in Others by DataKing99
• 8,240 points
3,916 views
0 votes
1 answer

How to store input value into array then localstorage?

Hello @ abhittac, You have create the array everytime the ...READ MORE

answered Jul 24, 2020 in Java-Script by Niroj
• 82,720 points
4,498 views
0 votes
1 answer

Convert a PHP object to an associative array

Start with simply typecasting the line:- $array = ...READ MORE

answered Feb 23 in PHP by Aditya
• 7,280 points
104 views
0 votes
0 answers

php var_dump() vs print_r()

What is the difference between var_dump() and print_r() in terms of ...READ MORE

May 28 in PHP by Kichu
• 19,040 points
8 views
webinar REGISTER FOR FREE WEBINAR X
Send OTP
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP