Scraping WEBSITE: Google Play Store and APK Pure In Same Time

Today i created script to scrap website. And, the target is Google Play Store And APK Pure in same time.

Play store is official market of android applications. APK Pure is another market that needed by user that has no google play apps or who got problem with their google service.

I used APK pure to download any app. Instead Google Play Store.

Basic Knowledge

We need basic knowledge of :

  1. cURL
  2. Simple HTML Dom
  3. MySQL Query
  4. Php

Logical Flow

  1. User input search string in a form
  2. Simple Dom and cURL reach target: APK Pure and Google Play
  3. Results inserted to database using Mysql Query
  4. Remove duplicate item
  5. Done

 

Explanation and Code

  1. User input search string in a form
    <form action="" method="POST" class="form-inline">
        <div class="form-group">
    <input name="q" type="text" class="form-control" placeholder="cari apk">
            </div>
        <div class="form-group">
    <button type="submit" name="cari" class="btn btn-danger">CARI APK</button>    
        </div>
    </form>
    
  2. Simple Dom and cURL reach target: APK Pure and Google Play AND Results inserted to database using Mysql Query
     

    If $q is Ok, try to execute another function to remove duplicate, unique by package name, remove past id.

     

    Now, function to get og:image (banner) from Google Play Store,

     
  3. And Put code to gether like this.

DEMO RESULTS CLICK HERE

Share to

Do You Know!