Find Jobs
Hire Freelancers

Post data from string PHP

$10-15 USD

Completed
Posted over 5 years ago

$10-15 USD

Paid on delivery
HI, I want to post slice string and make data out of it to post in in below method How to make the post fields dynamic in PHP ? <? $url = '[login to view URL]'; $string = "name=John|age=33|country=USA|.................." // what post fields? $fields = array( 'name' => John, 'age' => 33, 'country' => USA, . . . . ); // build the urlencoded data $postvars = http_build_query($fields); // open connection $ch = curl_init(); // set the url, number of POST vars, POST data curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, count($fields)); curl_setopt($ch, CURLOPT_POSTFIELDS, $postvars); // execute post $result = curl_exec($ch); // close connection curl_close($ch); ?>
Project ID: 18319833

About the project

2 proposals
Remote project
Active 5 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
Awarded to:
User Avatar
Hello sir, i have 10 years of exp, i have read the description and ready to start work right now. .....................................................................
$10 USD in 10 days
4.9 (348 reviews)
7.0
7.0
2 freelancers are bidding on average $14 USD for this job
User Avatar
Hello, I have checked your job description and I am okay to get this done for you. I can able to solve your problem with in an hour. I can able to start right now. Thanks
$17 USD in 1 day
5.0 (41 reviews)
5.4
5.4

About the client

Flag of OMAN
muscat, Oman
5.0
34
Payment method verified
Member since Oct 14, 2012

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.