Jump to content

Search the Community

Showing results for tags 'api integration'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (PhpStorm, VS Code, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Age


Donation Link

Found 1 result

  1. Hi guys, I am having a little trouble getting my head around how to tackle an issue. I am working with an API :- https://www.photoshelter.com/developer/index/endpoints/public Connecting up to it no problem and getting the information via cURL is also no bother. The point is I am needing to loop through galleries to retrieve 400 gallery IDs so I can pass in the data I need so for example I execute my first cURL response which gives me all the gallery IDs from here :- /psapi/v3/collection/root/children Now then I need to run a foreach loop to get each gallery ID to pass to :- /psapi/v3/gallery/{gallery_id} /psapi/v3/gallery/{gallery_id}/key_image Now the problem is I am having to use cURL to get the JSON data from here too and then finally the last one :- /psapi/v3/gallery/{gallery_id}/images/{image_id} To get the gallery featured image. Now the first cURL works fine but when I introduce the others in foreach loops it cripples it on loading time, but looking through of course it would as its excuting cURL a ridiculous amount of times. Is there a better way of tackling an issue like this as I feel cURL and file_get_contents is the wrong way going about this. Normally it's one execution and I get all the data I have never worked with something like this before. I would show my code but I feel it is unnecessary at this point on the grounds of I do not think this is the most productive way of even looking at this Currently the only thing I can think of is creating a query string to execute via a CRON job that would execute twice a day to check through the galleries API at Photoshelter and add everything to a database that I need. Any information would be greatly appreciated Thanks in advance Jamie
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.