Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update scrapper #9

Merged
merged 2 commits into from
Jan 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Or API :
- For my project **PriceComparator**
- Developpement of your own tools is important to understand and learn many things.

## Usage
## Usage
- `project.php` for known how the different tools works
- `scrapper*.php` the differents files for scraping mission
- `vendor` add lib for php
Expand All @@ -43,10 +43,12 @@ Or API :
- [x] http, https
- [x] html content generate by JS -> `puppeteer`
- [ ] cloudflare security
- [x] text in tag with another tag $\color{green}\textsf{(V2.0\ scrapper.php)}$


- Specific version for specific website :
- The french supermarket compagny :
- [Leclerc)](https://leclerc.fr) :
- [Leclerc](https://leclerc.fr) :
- [x] usage of https of basic version
- [x] parse specific JS -> json
- [ ] bypass cloudflare -> no cloudflare on this website
Expand Down
17 changes: 6 additions & 11 deletions infos_programs.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ function print_info_scrapper() {
[PARAMETERS]
[URL] -> \033[01;37mhttps://example.com\033[0m
[QUERY] -> the start of research,\033[01;37m html/body\033[0m is obvious but if we known
the website it's possible to precise the path
maybe aftet a first scrape with the query\033[01;37m html/body/div/article \033[0mfor example
the website it's possible to precise the path
maybe aftet a first scrape with the query\033[01;37m html/body/div/article \033[0mfor example

[OPTIONS]\n";
echo " php $prog --test --with-openssl\n";
Expand Down Expand Up @@ -52,13 +52,11 @@ function print_info_scrapper_leclerc() {
(Not usage of the second parameters for the moment)

[MAIN]
php $prog [url] [research_product_type] --with-openssl\n
php $prog [url] [research_product_type] --with-openssl

[PARAMETERS]
[URL] -> \033[01;37m https://fd7-courses.leclercdrive.fr/magasin-037301-037301-Voglans/recherche.aspx?TexteRecherche=lardons\033[0m
[research_product_type] -> the product we search,\033[01;37m lardons/allumettes\033[0m
\n";

[research_product_type] -> the product we search,\033[01;37m lardons/allumettes\033[0m\n\n";
echo "[**END LECLERC BASIC SCRAPPER INFORMATIONS**]\n";
}

Expand All @@ -85,14 +83,11 @@ function print_info_scrapper_carrefour() {
(Not usage of the second parameters for the moment)

[MAIN]
php $prog [url] [research_product_type] --with-openssl\n
php $prog [url] [research_product_type] --with-openss

[PARAMETERS]
[URL] -> \033[01;37m https://www.carrefour.fr/s?q=lardons \033[0m
[research_product_type] -> the product we search,\033[01;37m lardons/allumettes\033[0m
\n";


[research_product_type] -> the product we search,\033[01;37m lardons/allumettes\033[0m\n\n";
echo "[**END CARREFOUR SCRAPPER INFORMATIONS**]\n";
}

Expand Down
Loading
Loading