<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>munibus</author_name>
  <author_url>https://blog.hatena.ne.jp/munibus/</author_url>
  <blog_title>Muni Bus</blog_title>
  <blog_url>https://munibus.hatenablog.com/</blog_url>
  <categories>
    <anon>PHP</anon>
  </categories>
  <description>printf関数使用時に、出力文字列の改行を行う場合、特殊文字（エスケープシーケンス、エスケープ文字）\nを使用する。以下、使用例。 $a = &quot;aaa&quot;; $b = &quot;bbb&quot;; printf(&quot;%s\n%s&quot;, $a, $b); （HTML出力） aaa bbb （画面出力） aaa bbb 上記の例では、\nを使用しても、出力するHTMLでは改行されているが、HTMLでは改行は区切りの意味しか持たないため、画面上では空白一つに置き換えられてしまい、画面出力では改行されない。 画面出力で改行を行うには、nl2br関数を使用する。nl2br関数は改行に相当する特殊文字（\n）の前にHTMLで…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fmunibus.hatenablog.com%2Fentry%2F2021%2F09%2F18%2F123119&quot; title=&quot;【PHP】printf関数使用時に改行を行う - Muni Bus&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>2021-09-18 12:31:19</published>
  <title>【PHP】printf関数使用時に改行を行う</title>
  <type>rich</type>
  <url>https://munibus.hatenablog.com/entry/2021/09/18/123119</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
