Skip to content

Commit e5cb4a2

Browse files
fix broken html syntax in scraping
1 parent 7b2515c commit e5cb4a2

File tree

1 file changed

+18
-30
lines changed

1 file changed

+18
-30
lines changed

source/reading.Rmd

Lines changed: 18 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -899,37 +899,25 @@ entire source
899899
is [included with the code for this book](https://github.com/UBC-DSCI/introduction-to-datascience/blob/main/img/reading/website_source.txt):
900900

901901
```html
902-
<span class="result-meta">
903-
<span class="result-price">$800</span>
904-
905-
<span class="housing">
906-
1br -
907-
</span>
908-
909-
<span class="result-hood"> (13768 108th Avenue)</span>
910-
911-
<span class="result-tags">
912-
<span class="maptag" data-pid="6786042973">map</span>
913-
</span>
914-
915-
<span class="banish icon icon-trash" role="button">
916-
<span class="screen-reader-text">hide this posting</span>
917-
</span>
918-
919-
<span class="unbanish icon icon-trash red" role="button" aria-hidden
920-
<a href="#" class="restore-link">
921-
<span class="restore-narrow-text">restore</span>
922-
<span class="restore-wide-text">restore this posting</span>
923-
</a>
924-
902+
<span class="result-meta">
903+
<span class="result-price">$800</span>
904+
<span class="housing">
905+
1br -
906+
</span>
907+
<span class="result-hood"> (13768 108th Avenue)</span>
908+
<span class="result-tags">
909+
<span class="maptag" data-pid="6786042973">map</span>
910+
</span>
911+
<span class="banish icon icon-trash" role="button">
912+
<span class="screen-reader-text">hide this posting</span>
925913
</span>
926-
</p>
927-
</li>
928-
<li class="result-row" data-pid="6788463837">
929-
930-
<a href="https://vancouver.craigslist.org/nvn/apa/d/north-vancouver-luxu
931-
<span class="result-price">$2285</span>
932-
</a>
914+
<span class="unbanish icon icon-trash red" role="button"></span>
915+
<a href="#" class="restore-link">
916+
<span class="restore-narrow-text">restore</span>
917+
<span class="restore-wide-text">restore this posting</span>
918+
</a>
919+
<span class="result-price">$2285</span>
920+
</span>
933921
```
934922

935923
Oof...you can tell that the source code for a web page is not really designed

0 commit comments

Comments
 (0)