https://github.com/bborrel/google-scholar-profile-parser
Google Scholar Profile Parser is a PHP library which parses the HTML of a scholar's profile page from Google Scholar website and transforms its data into a regular PHP data structure.
https://github.com/bborrel/google-scholar-profile-parser
google-scholar parser php publications scholar statistics
Last synced: 16 days ago
JSON representation
Google Scholar Profile Parser is a PHP library which parses the HTML of a scholar's profile page from Google Scholar website and transforms its data into a regular PHP data structure.
- Host: GitHub
- URL: https://github.com/bborrel/google-scholar-profile-parser
- Owner: bborrel
- License: gpl-3.0
- Created: 2019-03-05T04:53:16.000Z (almost 7 years ago)
- Default Branch: main
- Last Pushed: 2025-04-29T17:50:45.000Z (9 months ago)
- Last Synced: 2025-11-27T14:42:54.060Z (2 months ago)
- Topics: google-scholar, parser, php, publications, scholar, statistics
- Language: PHP
- Homepage:
- Size: 201 KB
- Stars: 14
- Watchers: 2
- Forks: 4
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Google Scholar Profile Parser
[](https://packagist.org/packages/bborrel/google-scholar-profile-parser)
[](https://packagist.org/packages/bborrel/google-scholar-profile-parser)
[](https://packagist.org/packages/bborrel/google-scholar-profile-parser)
[](https://packagist.org/packages/bborrel/google-scholar-profile-parser)
[](https://travis-ci.com/bborrel/google-scholar-profile-parser)
[](https://app.travis-ci.com/bborrel/google-scholar-profile-parser)
[](https://coveralls.io/github/bborrel/google-scholar-profile-parser?branch=master)
[](https://stryker-mutator.github.io)
[](https://codeclimate.com/github/codeclimate/codeclimate/maintainability)
Google Scholar Profile Parser is a PHP library which parses the HTML of a scholar's profile page from Google Scholar
website and transforms its data into a regular PHP data structure.
The parsed data from a scholar is:
- his/her list of publications (title, link, authors, publisher details, citations)
- his/her citations' statistics (number of citations, h-index, i10-index)
## Table of content
- [Project Rationale](#project-rationale)
- [Requirements](#requirements)
- [Installation](#installation)
- [Usage](#usage)
- [Versioning](#versioning)
- [Code Quality](#code-quality)
- [Author](#author)
- [License](#license)
## Project Rationale
As explained by this [Wikipedia page][1]:
> Google Scholar is a freely accessible web search engine that indexes the full text or metadata of scholarly literature
> across an array of publishing formats and disciplines.Google Scholar is a website which indexes scholars' publications
> and citations.
Unfortunately [Google Scholar][2] website doesn't provide an API and I needed a way to fetch a scholar's data.
So, while I was looking for a PHP library which parses a profile page from Google Scholar website, I only found
[Scholar parser][3] from [Daniel Schreij][4]. But I was unhappy with this library's dependency upon [PhantomJS][5]
which development is suspended (and will likely not resume, leaving users without support). So I decided to rewrite this
library redesigning it to depend only on PHP, and no more Javascript.
## Requirements
Major versions vs. PHP:
- 3.x: PHP 8.1+
- 2.x: PHP 7.1+
- 1.x: PHP 5.6+
As stated in [composer.json][6], it requires PHP extension DOM.
## Installation
Use [Composer][7] to download and install this library as well as its dependencies.
```bash
composer require bborrel/google-scholar-profile-parser
```
## Usage
See the examples in the [library's documentation][8].
## Versioning
This library use [SemVer][9] for versioning. For available versions, see the [tags on this repository][10]. For feature
changes, see the [CHANGELOG.md][11] file for details.
## Code Quality
The code of this library:
- follows the [PSR-1][12] and [PSR-12][13] coding standards
- follows the [PSR-4][14] autoloading standard
- is statically analysed with [PHPQA][15] (which wraps several tools, notably [PHPCS][16], [PHPMD][17], [PHPStan][18]
and [Psalm][19]), and by Code Climate (which is setup with plugins [Phan][20], [PHPMD][17], [SonarPHP][21])
- is unit tested with [PHPUnit][22] (code coverage on [Coveralls][23])
- is mutation tested with [Infection][24]
- is tested for compatibility with different versions of PHP (see [.travis.yml][25] for details)
- has its dependencies checked for known security issues by [Packagist API][26]
- is continuously integrated on [TravisCI][27]
These tools are installed with the library as long as you do not specify the option `--no-dev` when running the
`install` or `update` [Composer][7] commands.
To run the static analysis tools and the unit tests via [PHPQA][15]:
```bash
./vendor/bin/phpqa
```
To see the reports generated by [PHPQA][15] use a browser to open the file `./build/phpqa.html`.
## Author
[Benoit Borrel][28]
## License
This library is licensed under the GPL-3.0-only License, see the [LICENSE.md][29] file for details.
[1]: https://en.wikipedia.org/wiki/Google_Scholar
[2]: https://scholar.google.com/
[3]: https://github.com/dschreij/scholar_parser
[4]: https://github.com/dschreij
[5]: http://phantomjs.org/
[6]: composer.json
[7]: https://getcomposer.org/
[8]: doc
[9]: http://semver.org/
[10]: https://github.com/bborrel/google-scholar-profile-parser/tags
[11]: CHANGELOG.md
[12]: https://www.php-fig.org/psr/psr-1/
[13]: https://www.php-fig.org/psr/psr-12/
[14]: https://www.php-fig.org/psr/psr-4/
[15]: https://github.com/EdgedesignCZ/phpqa
[16]: https://github.com/squizlabs/PHP_CodeSniffer
[17]: https://phpmd.org/
[18]: https://github.com/phpstan/phpstan
[19]: https://psalm.dev/
[20]: https://github.com/phan/phan
[21]: https://www.sonarsource.com/products/codeanalyzers/sonarphp.html
[22]: https://phpunit.de/
[23]: https://coveralls.io/github/bborrel/google-scholar-profile-parser?branch=master
[24]: https://github.com/infection/infection
[25]: .travis.yml
[26]: https://packagist.org/apidoc#list-security-advisories
[27]: https://travis-ci.com/bborrel/google-scholar-profile-parser
[28]: https://github.com/bborrel
[29]: LICENSE.md