split values


Posted on 16th Feb 2014 07:03 pm by admin

I have values that are returned to me in this format:

name=>test,age=>49

Did you know?Explore Trending and Topic pages for more stories like this.
What I want to get out of this is an array like this

array('name'=>'test','age'=>'49');

I was hoping some one could let me know the best way to do this. I was thinking about using preg_split() but wasnt sure if it was the best method. Also not that good with regex. Any help is appreciated.
No comments posted yet

Your Answer:

Login to answer
330 Like 6 Dislike
Previous forums Next forums
Other forums

How to assign JS screen.width to ASP.Net variable
I've got this ASP.net routine that gets the cookie value of the screen width, but now I need to chan

Mail Script Problems
I have created a PHP mail script. I am having a problem though. In $body i am trying to put two va

function to return url
Hi,

Can you guys help me giving a function that takes all the contents in a particular field

(sub)screen resize modification doesn't work after ECC 6 EhP 4 installation
Hello,

We have previously extended the size of the custom data tab on PO transaction ME23

passing data from one page to another
hey guys
i have the follwoing code to get information from one page and place on another:

Problem with Subscreen
Dear Experts ,
I am facing a problem with the subscreens. My senario is as follows :

send() and recv() parameters confusion
On server Side:
int recv (Socket,Buffer, Length, Flags)
On Client Side:
int send (Soc

xml
<?php

echo "<h1>XML Articles</h1>";

$home

simple php table loop
Hi all,

I've the following code

<?php // Create category options

Convert .fdf to .pdf
I currently have a web form that uploads the form data to an .fdf file and emails it.

However

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash