|
|
#1 |
|
Junior Member
![]() Posts: 6
Karma: 10
Join Date: Jan 2017
Device: Kindle
|
Soup selection not working if not matched all classes
Hi,
I am trying to select an element which has class 'article_date' and few other classes. i want to select element by one class but its not working, i had to give all classes in the element. where in my case i cant predict other classes as its created dynamically according to articles. this is not working when there are other class too in the element souparticle.find("div", { "class" : "article_date " }) |
|
|
|
|
|
#2 |
|
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,609
Karma: 28549044
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Code:
{"class": lambda x: x and 'article_date' in x.split()}
|
|
|
|
| Advert | |
|
|
|
|
#3 |
|
Junior Member
![]() Posts: 6
Karma: 10
Join Date: Jan 2017
Device: Kindle
|
THANK YOU
|
|
|
|
![]() |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Pseudo classes with classes | Macsurfcat | ePub | 4 | 01-07-2016 05:00 AM |
| Reference Francatelli, C E: A Plain Cookery Book for the Working Classes, v.1, 23 Dec 2007 | Patricia | IMP Books | 0 | 12-22-2007 09:05 PM |
| Reference Francatelli, C E: A Plain Cookery Book for the Working Classes, v.1, 23 Dec 2007 | Patricia | Kindle Books | 0 | 12-22-2007 09:01 PM |
| Reference Francatelli, C E: A Plain Cookery Book for the Working Classes, v.1, 25 July 2007 | Patricia | BBeB/LRF Books | 7 | 08-02-2007 12:19 PM |