<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>potisan</author_name>
  <author_url>https://blog.hatena.ne.jp/potisan/</author_url>
  <blog_title>potisanのプログラミングメモ</blog_title>
  <blog_url>https://potisan-programming-memo.hatenablog.jp/</blog_url>
  <categories>
    <anon>Python</anon>
    <anon>スクレイピング</anon>
  </categories>
  <description>Python 3でurllib.requestを使用してURLからHTMLを読み込み、Beautiful Soup 4とlxmlを使用して要素一覧を取得するサンプルコードです。読み込むURLはYahoo! JAPANのURLをお借りしています。 サンプルコード 参考 サンプルコード import urllib.request from bs4 import BeautifulSoup #URLからウェブページを読み込みます。 url = &quot;https://www.yahoo.co.jp/&quot; with urllib.request.urlopen(url) as response: doc = …</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fpotisan-programming-memo.hatenablog.jp%2Fentry%2F2020%2F01%2F22%2F184820&quot; title=&quot;Python 3でURLからHTMLを読み込んで要素一覧を取得する - potisanのプログラミングメモ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2020-01-22 18:48:20</published>
  <title>Python 3でURLからHTMLを読み込んで要素一覧を取得する</title>
  <type>rich</type>
  <url>https://potisan-programming-memo.hatenablog.jp/entry/2020/01/22/184820</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
