94 Topics

Member Avatar for
Member Avatar for joshl_1995

Hello Daniweb, I was wondering how come a cURL API I made to call a function from my other website (but on the same hosting plan) no longer works. I even tried making a test API to call in the same directory, eg... :api.php <?php die(json_encode("something")); ?> :testing.php <?php $url …

Member Avatar for Dani
0
3K
Member Avatar for ramyayarrapothu

$curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => 'https://livehealth.solutions/getAllTestsAndProfiles/?token=3f115cd0-c79b-11eb-b07b-0aa43715764a', CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => '', CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => 'GET', )); $response = curl_exec($curl); curl_close($curl); $resArr = json_decode($response); echo "<pre>"; print_r($resArr); echo "</pre>"; **displays the list of array values... as shown …

Member Avatar for Dani
0
1K
Member Avatar for michael.dewitt.716

I know this title is rather confusing, but here it goes. I have a PHP cURL request and the return is in a string. Normally i can easily echo specific objects from the JSON response, but i have never dealt with string returns. Here is my php <?php $url = …

Member Avatar for michael.dewitt.716
0
21K
Member Avatar for happygeek

OK, so in [this thread](https://www.daniweb.com/hardware-and-software/microsoft-windows/threads/507918/presentation-loads-with-error) I offered advice to visit the Microsoft troubleshooter here: https://support.microsoft.com/en-gb/help/927477/how-to-troubleshoot-a-damaged-presentation-in-powerpoint-2007-and-powerpoint-2010 and DaniWeb broke the link and struck a line through it to say it didn't exist, when it quite clearly does. It may well break again here, let's see. I suspect that DaniWeb isn't handling …

Member Avatar for happygeek
1
899
Member Avatar for double_cola

I have a form that creats a json array from user input data. Array ( [full_name] => First Name + Last Name [company_name] => Company Name [email] => Email [free_trial] => trial (Yes/No) [quota] => quota [contract] => 0 (0/1) [per_gb] => cost per gb [per_month] => contract length in …

Member Avatar for cereal
0
1K
Member Avatar for blueguy777

How to store the following curl_exec output into mysql table? sent,success,114661698,709081462,+919900123456 sent,success,134707665,937687314,+917795987654 Eg: var1='sent' var2='success' var3='114661698' var4='709081462' var5='+919900123456' --------------------------------------------------- var1='sent' var2='success' var3='134707665' var4='937687314' var5='+917795987654' Thanks in advance

Member Avatar for cereal
0
2K
Member Avatar for Dani

Hi everyone, I really hope that you can help me diagnose an issue with my new API. I'm having the following issue: I'm not happy with the performance of the app client at http://app.dazah.com that connects to it ... It uses cURL to issue about 3-4 API requests per page …

Member Avatar for rproffitt
0
2K
Member Avatar for iveto89

Hello! I'm making cURL request to neteller API and it returns 401 not authorized. My IP is whitelisted in neteller test account. I have the following code: $url = 'https://test.api.neteller.com/v1/oauth2/token; $clientId = NETELLER_CLIENT_ID; $clientSecret = NETELLER_CLIENT_SECRET; $grantType = 'grant_type=client_credentials'; $curl = curl_init($url); curl_setopt($curl, CURLOPT_POST, true); curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); curl_setopt($curl, CURLOPT_USERPWD, …

Member Avatar for iveto89
0
1K
Member Avatar for shubhamjain1

By this script you can remotely login into facebook account with your password and username and fetch/send data.

Member Avatar for Tùng
2
8K
Member Avatar for FarrisFahad

Hello, I am trying to understand PayPal IPN proccess. I have built this simple script to test with the IPN simulator in the developer section of PayPal. I have tried different type of transaction status but it keeps returning VERIFIED. Can someone please explain to me how does this work? …

Member Avatar for FarrisFahad
0
374
Member Avatar for azegurb

I want to learn how HTTP PUT method is used with PHP? I googled at the web and found some tutorials about it with cURL. But i dont know how to use it (Like REST API). Can anyone help me? Thank in advance

Member Avatar for cereal
0
260
Member Avatar for anitg

I am trying to use a sms gateway app for android called SMSGateway with a http header request using curl as below; $curl_handle=curl_init(); curl_setopt($curl_handle, CURLOPT_URL,"http://192.168.1.2:9090/sendsms?phone=$phone&text=$message1&password=xxxxxxxx"); curl_setopt($curl_handle, CURLOPT_CONNECTTIMEOUT, 10000); curl_setopt($curl_handle, CURLOPT_TIMEOUT,50000); curl_setopt($curl_handle, CURLOPT_RETURNTRANSFER, 1); curl_setopt($curl_handle, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 6.1; rv:36.0) Gecko/20100101 Firefox/36.0'); $query = curl_exec($curl_handle); if($query){echo "Message Sent to $phone …

Member Avatar for anitg
0
546
Member Avatar for PsychicTide

Hey guys, this seems to be a thorn in my side. I've been working on scraping a website which uses aspx and has eventvalidation/viewstate inputs. Every other scraping experiment I've made was not this difficult. Maybe one of you geniuses here at Daniweb has an idea of how to solve …

Member Avatar for PsychicTide
0
887
Member Avatar for Prince_9

I'm trying to make a curl through php below is the command line : curl -i -H "Accept: application/json" -d "{"username": "divmesselibrary", "password": "677Sure1@"}" https://openlibrary.org/account/login Please I need your help

Member Avatar for broj1
0
327
Member Avatar for sam230

http://api.ean.com/ean-services/rs/hotel/v3/list?minorRev=4&cid=55505&apiKey=5q4gzx43g6ukcrq798z2hz75&customerSessionId=&locale=en_US&currencyCode=USD&xml=<HotelListRequest><city>new%20delhi</city><RoomGroup><Room><numberOfAdults>2</numberOfAdults><numberOfResults></numberOfResults></Room></RoomGroup></HotelListRequest> when i call api directly to browser i got right data in xml format. but when i call it through curl.. sometime i get data in json format or sometimes no data.. [CODE] $ch = curl_init(); curl_setopt($ch, CURLOPT_URL,"http://api.ean.com/ean-services/rs/hotel/v3/list?minorRev=4&cid=55505&apiKey=5q4gzx43g6ukcrq798z2hz75&customerSessionId=&locale=en_US&currencyCode=USD&xml=<HotelListRequest><city>new%20delhi</city><RoomGroup><Room><numberOfAdults>2</numberOfAdults><numberOfResults></numberOfResults></Room></RoomGroup></HotelListRequest>"); curl_setopt($ch, CURLOPT_FAILONERROR,1); curl_setopt($ch, CURLOPT_FOLLOWLOCATION,1); curl_setopt($ch, CURLOPT_RETURNTRANSFER,1); curl_setopt($ch, CURLOPT_TIMEOUT, 15); $retValue = …

Member Avatar for Terrymol
0
914
Member Avatar for protas

Hello Guys, I apologized if I may have misplaced this post as I cannot see CURL on any category. Here is my situation. I am trying to create a batch file which will pull up information from a fleet of devices via its web interface. I am using CURL to …

Member Avatar for BobMCT
0
310
Member Avatar for fheppell

I have some code that takes a URL and downloads it using CURL. Here's the code: $url= $row['loc']; $path = 'tmp/'; $path .= rand(100,999); $path .= $row['name']; $fp = fopen($path, 'w'); $ch = curl_init($url); curl_setopt($ch, CURLOPT_FILE, $fp); $data = curl_exec($ch); curl_close($ch); fclose($fp); $downloadarray[] = array($path, $row['name']); However the file is …

Member Avatar for Isaac_4
0
282
Member Avatar for sammry

This is a SMS DLR application from http://www.smsgatewaycenter.com which is sent by them to my client's url and I need to configure for my client the same from my client's url to his reseller's url. This script uses every 1 hour to post data to my client's reseller/customer. So, it …

Member Avatar for Isaac_4
0
2K
Member Avatar for Ingska

Hi all! I am trying to post from a form to an URL, using cURL. I have managed to do the posting bit, and my data is coming thew to the URL just like I wanted. Here is my code: <?php //create array of data to be posted $post_data['Application.Ssn'] = …

Member Avatar for broj1
0
573
Member Avatar for patk570

Hello, I am getting a weird error when i try to run this array: //leafly api keys $appID ='Blah'; $appKEY = 'blah'; //init curl $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "http://data.leafly.com/strains/".strtolower($data)); //change the strain dynamically of course for your app curl_setopt($ch,CURLOPT_HTTPHEADER,array('APP_ID:'.$appID,'APP_KEY:'.$appKEY)); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); $output = curl_exec($ch); //Clean it into an …

Member Avatar for broj1
0
1K
Member Avatar for deshazer.jad

Server information: Ubuntu 14.04 Apache2 I installed PHP5 on my webserver and tried to run a script that contained a call to the function curl_init(). The server responded with an error indicating that the function curl_init() was undefined. I installed PHP-CURL and restarted my webserver and encountered the same error. …

Member Avatar for deshazer.jad
0
1K
Member Avatar for abaddon2031

Ok i have a daily csv file that i am trying to get python to post to my database every day. I have used curl befor to post it but i want to set python up so that it post it for me is there a way to do this …

Member Avatar for abaddon2031
0
301
Member Avatar for abaddon2031

I am new to cURL and im trying to get it to add new contacts to my database. i have all my information right but when it reads my csv file it tells me no email column was found in the file you are uploading> I know for a fact …

Member Avatar for abaddon2031
0
171
Member Avatar for cfv1000

Hello I made some tries to get info from http://portal.onrc.ro The workflow is like: 1. Login => redirects to a page 2. Get the form (GET /ONRCPortalWeb/appmanager/myONRC/wicket?p=bpi.buletinBpiOnline) 3. Change the search type (POST /ONRCPortalWeb/appmanager/myONRC/wicket?_nfpb=true&_windowLabel=TestWicket03_1&_urlType=action&wlpTestWicket03_1__wu=%2FONRCPortalWeb%2Fappmanager%2FmyONRC%2Fwicket%2F%3Fwicket%3Ainterface%3D%3A1%3AformCautare%3A%3AIFormSubmitListener%3A%3A) => redirect to an interface (GET /ONRCPortalWeb/appmanager/myONRC/wicket/?wicket:interface=:<@interface_NO>:1:::) After changing the search type, i don't get redirected. …

0
150
Member Avatar for abaddon2031

Ok so i didnt know where to post this but i am getting two errors while useing cURL. The first says cURL: (26) coudn't open file "test.csv". The second one keeps saying please upload a file. I have been trying to fix this for over a hour now and can …

0
146
Member Avatar for Amir_6

Hi, I'm developing a software in C++/Qt5 and I would like to create a button, which when u click on it, a "status" is posted on the user own wall. So I created a facebook app on https://developers.facebook.com/ but I don't know how to configure it. Also I tried to …

Member Avatar for Amir_6
0
425
Member Avatar for kishoresai438

This is regarding paypal through Curl. I am trying to access paypal by using below code. The code is working fine in one server. After moving this code to live server, getting the below error. Can anybody tell me the solution for this. $API_Endpoint = "https://api-3t.sandbox.paypal.com/nvp"; $version = urlencode('76.0'); $ch …

Member Avatar for nauticalmac
0
448
Member Avatar for fheppell

I have this code for my site, the zip is generating (but corrupted because of the 0 byte files...) but the actual curled files (in the tmp/ directory) are there, just with nothing in them. if ($_GET['download']== 'true'){ $downloadarray = array(); while($row = mysql_fetch_array($res)){ $url= $row['loc']; $path = 'tmp/'; $path …

Member Avatar for fheppell
0
2K
Member Avatar for fheppell

I wrote this code to integrate with filepicker.io, it takes the URL of the file and gets the header information: $info = curl_init() or die('error 1'); curl_setopt($info, CURLOPT_RETURNTRANSFER, 1); //curl_setopt($info, CURLOPT_PORT , 8089); curl_setopt($info, CURLOPT_URL, $url); curl_setopt($info, CURLOPT_CONNECTTIMEOUT, 30); curl_setopt($info, CURLOPT_NOBODY, true); //curl_setopt($info, CURLOPT_SSL_VERIFYPEER, 0); curl_exec($info); if(!curl_errno($info)){ $response = curl_getinfo($info); …

Member Avatar for diafol
0
606
Member Avatar for VNexus

Hi Everyone, I'm not sure if I may be in the wrong venue to post as this would have to do with PHP, CURL and SSL, so I've decided to place the question here. Please feel free to let me know if the question should be dropped in some other …

Member Avatar for Lsmjudoka
1
487

The End.