Spaces:
Sleeping
Sleeping
Commit ·
ca05260
1
Parent(s): f36ba97
Update scraper_script.py
Browse files- scraper_script.py +5 -5
scraper_script.py
CHANGED
|
@@ -7,11 +7,11 @@ def scrape_flipkart_products(search_query, filters, brands):
|
|
| 7 |
url = "https://www.flipkart.com/search?q="
|
| 8 |
if search_query:
|
| 9 |
url += f"{search_query.replace(' ', '+')}"
|
| 10 |
-
if brands:
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
if gender == 'Male':
|
| 16 |
url += "&p[]=facets.ideal_for%255B%255D%3DMen"
|
| 17 |
elif gender == 'Female':
|
|
|
|
| 7 |
url = "https://www.flipkart.com/search?q="
|
| 8 |
if search_query:
|
| 9 |
url += f"{search_query.replace(' ', '+')}"
|
| 10 |
+
# if brands:
|
| 11 |
+
# for brand in brands:
|
| 12 |
+
# brand=brand.split(" ")
|
| 13 |
+
# brand="%2B".join(brand)
|
| 14 |
+
# url += f"&p%5B%5D=facets.brand%255B%255D%3D{brand}"
|
| 15 |
if gender == 'Male':
|
| 16 |
url += "&p[]=facets.ideal_for%255B%255D%3DMen"
|
| 17 |
elif gender == 'Female':
|