troubleshooting Question

how can i do it with cURL for automation

Avatar of Mehran Goudarzi
Mehran Goudarzi asked on
PHP* Automation* Curl
10 Comments2 Solutions75 ViewsLast Modified:
i have PHP file and upload it on my localhost . here is my include file on php :

<?php
set_time_limit(0);
date_default_timezone_set('UTC');

require_once '/var/www/html/insta/vendor/autoload.php';

//////////////////////
/////// MEDIA ////////
$mediaId = '1479882119026549924_4483535640';
$commentText = 'Test';
//////////////////////
try {
    $debug = true;
    $ig = new \InstagramAPI\Instagram($debug);
    $ig->setUser($username, $password);
    $ig->login();
   // $ig->enableMediaComments($mediaId);
    $result = $ig->comment($mediaId, $commentText);
    var_dump($result);
} catch (\Exception $e) {
    echo $e->getMessage()."\n";
}

Now i want
$mediaId = '1479882119026549924_4483535640';
 this id change every time ,

for example i have one text File include 100 media_id , now every time cURL send it with different Media_id .
SOLUTION
Join our community to see this answer!
Unlock 2 Answers and 10 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 2 Answers and 10 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros