<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>ngtn</author_name>
  <author_url>https://blog.hatena.ne.jp/ngtn/</author_url>
  <blog_title>Writing Some Code</blog_title>
  <blog_url>https://ngtn.hatenadiary.org/</blog_url>
  <categories>
    <anon>CakePHP</anon>
  </categories>
  <description>1.2系の多言語機能を使って、URLベースで言語の切り替えをするサンプルを書いてみた。サンプルでは日本語と英語に対応するアプリを作る場合を想定。app\config\routes.phpに以下の2行を追加。 Router::connect('/ja/:controller/:action/*', array()); Router::connect('/en/:controller/:action/*', array()); AppController(app\controllers\app_controller.php)のbeforeFilterにURLから言語を抜き出してConfigureに…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fngtn.hatenadiary.org%2Fentry%2F20080303%2F1204556191&quot; title=&quot;URLベースで言語の切り替え - Writing Some Code&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>2008-03-03 23:56:31</published>
  <title>URLベースで言語の切り替え</title>
  <type>rich</type>
  <url>https://ngtn.hatenadiary.org/entry/20080303/1204556191</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
