klepak/php-js-webrequest

There is no license information available for the latest version (v0.1) of this package.

Installs: 11

Dependents: 1

Suggesters: 0

Security: 0

Stars: 0

Watchers: 2

Forks: 0

Open Issues: 0

Language:JavaScript

v0.1 2019-05-23 15:22 UTC

This package is auto-updated.

Last update: 2024-12-24 05:13:32 UTC


README

Use headless chrome to get contents of webpage after running javascript. Tested on Windows 10.

Requirements

  • Node/NPM
  • Puppeteer

Getting started

composer require klepak/php-js-webrequest
npm install puppeteer

Usage

$req = (new PhpJsWebRequest);

echo $req->get('https://url.tld');

The package assumes your node executable is located in C:\Program Files\nodejs. If it is located elsewhere, you may call the setNodeExecutablePath method.

$req = (new PhpJsWebRequest)
    ->setNodeExecutablePath('path');

echo $req->get('https://url.tld');