{"id":9389,"date":"2025-10-08T13:36:04","date_gmt":"2025-10-08T04:36:04","guid":{"rendered":"https:\/\/code-plus.jp\/gp\/?p=9389"},"modified":"2026-10-28T20:14:19","modified_gmt":"2026-10-28T11:14:19","slug":"custom-menu-9389","status":"publish","type":"post","link":"https:\/\/code-plus.jp\/gp\/custom-menu-9389\/","title":{"rendered":"WordPress\u306e\u30ab\u30b9\u30bf\u30e0\u30e1\u30cb\u30e5\u30fc\u6a5f\u80fd\u3068\u30ab\u30b9\u30bf\u30de\u30a4\u30ba"},"content":{"rendered":"<h2 class=\"fz-xl\">\u30ab\u30b9\u30bf\u30e0\u30e1\u30cb\u30e5\u30fc\u6a5f\u80fd\u3068\u306f?<\/h2>\n<p>\nWordPress\u30b5\u30a4\u30c8\u3092\u904b\u55b6\u3057\u3066\u3044\u3066\u300c\u30e1\u30cb\u30e5\u30fc\u3092\u3082\u3063\u3068\u81ea\u7531\u306b\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3057\u305f\u3044\u300d\u3068\u601d\u3046\u3053\u3068\u306f\u3042\u308a\u307e\u305b\u3093\u304b\uff1f<br \/>\nWordPress\u306e\u30ab\u30b9\u30bf\u30e0\u30e1\u30cb\u30e5\u30fc\u6a5f\u80fd\u306f\u3001\u30b5\u30a4\u30c8\u306e\u30ca\u30d3\u30b2\u30fc\u30b7\u30e7\u30f3\u30e1\u30cb\u30e5\u30fc\u3092\u81ea\u7531\u306b\u4f5c\u6210\u30fb\u914d\u7f6e\u3067\u304d\u308b\u4ed5\u7d44\u307f\u3067\u3059\u3002\u3053\u306e\u8a18\u4e8b\u3067\u306f\u3001WordPress\u306e\u30ab\u30b9\u30bf\u30e0\u30e1\u30cb\u30e5\u30fc\u6a5f\u80fd\u3068\u305d\u306e\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u65b9\u6cd5\u306b\u3064\u3044\u3066\u3001\u521d\u5fc3\u8005\u306e\u65b9\u306b\u3082\u308f\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3057\u307e\u3059\u3002\n<\/p>\n\n <!-- \u2605\u76ee\u6b21\u30ea\u30b9\u30c8 -->\n<ul class=\"tocList mt-1.5r\" data-toc-id=\"js-tocBWGD\"><\/ul>\n<ins class=\"tocBtn is-fixed\" data-toc-id=\"js-tocBWGD\"><\/ins>\n\n\n\n\n\n\n\n<h3 class=\"fz-ml\">\u57fa\u672c\u7684\u306a\u6a5f\u80fd<\/h3>\n<ul style=\"list-style-type:bullet;\">\n  <li>\u7ba1\u7406\u753b\u9762\u306e\u300c\u5916\u89b3\u300d\u2192\u300c\u30e1\u30cb\u30e5\u30fc\u300d\u304b\u3089\u7c21\u5358\u306b\u64cd\u4f5c\u3067\u304d\u308b<\/li>\n  <li>\u30da\u30fc\u30b8\u3001\u6295\u7a3f\u3001\u30ab\u30c6\u30b4\u30ea\u30fc\u3001\u30ab\u30b9\u30bf\u30e0\u30ea\u30f3\u30af\u306a\u3069\u3092\u81ea\u7531\u306b\u7d44\u307f\u5408\u308f\u305b\u3089\u308c\u308b<\/li>\n  <li>\u30c9\u30e9\u30c3\u30b0&amp;\u30c9\u30ed\u30c3\u30d7\u3067\u4e26\u3073\u66ff\u3048\u3084\u968e\u5c64\u69cb\u9020\u306e\u4f5c\u6210\u304c\u53ef\u80fd<\/li>\n  <li>\u8907\u6570\u306e\u30e1\u30cb\u30e5\u30fc\u3092\u4f5c\u6210\u3057\u3066\u3001\u5834\u6240\u3054\u3068\u306b\u4f7f\u3044\u5206\u3051\u3089\u308c\u308b<\/li>\n<\/ul>\n\n<h3 class=\"fz-ml\">\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u5236\u9650<\/h3>\n<p>\u6a19\u6e96\u6a5f\u80fd\u3060\u3051\u3067\u306f\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u5236\u9650\u304c\u3042\u308a\u307e\u3059:<\/p>\n<ul style=\"list-style-type:bullet;\">\n  <li>\u30e1\u30cb\u30e5\u30fc\u9805\u76ee\u306b\u8aac\u660e\u6587\u3092\u8ffd\u52a0\u3057\u3066\u3082\u8868\u793a\u3055\u308c\u306a\u3044<\/li>\n  <li>HTML\u306e\u69cb\u9020\u304c\u56fa\u5b9a\u3055\u308c\u3066\u3044\u3066\u30c7\u30b6\u30a4\u30f3\u306e\u81ea\u7531\u5ea6\u304c\u4f4e\u3044<\/li>\n  <li>\u30b7\u30e7\u30fc\u30c8\u30b3\u30fc\u30c9\u3067\u597d\u304d\u306a\u5834\u6240\u306b\u8868\u793a\u3067\u304d\u306a\u3044<\/li>\n  <li>CSS\u30af\u30e9\u30b9\u3092\u7d30\u304b\u304f\u6307\u5b9a\u3067\u304d\u306a\u3044<\/li>\n<\/ul>\n<p>\u3053\u308c\u3089\u306e\u5236\u9650\u3092\u89e3\u6d88\u3059\u308b\u306e\u304c\u3001\u4eca\u56de\u7d39\u4ecb\u3059\u308b\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3067\u3059\u3002<\/p>\n\n\n<h2 class=\"fz-xl\">\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u306e\u6e96\u5099<\/h2>\n<p>\u307e\u305a\u3001\u30c6\u30fc\u30de\u306efunctions.php\u30d5\u30a1\u30a4\u30eb\u306b\u4ee5\u4e0b\u306e\u30b3\u30fc\u30c9\u3092\u8ffd\u52a0\u3057\u3066\u3001\u30ab\u30b9\u30bf\u30e0\u30e1\u30cb\u30e5\u30fc\u6a5f\u80fd\u3092\u6709\u52b9\u5316\u3057\u307e\u3059\u3002<\/p>\n<pre><code class=\"language-php\">\/* \u30ab\u30b9\u30bf\u30e0\u30e1\u30cb\u30e5\u30fc\u6a5f\u80fd\u306b\u5bfe\u5fdc\u3055\u305b\u308b *\/\nfunction mymenus_setup() {\n  add_theme_support(&#39;menus&#39;);\n}\nadd_action(&#39;after_setup_theme&#39;, &#39;mymenus_setup&#39;);\n<\/code><\/pre>\n<p>\u3053\u306e\u30b3\u30fc\u30c9\u306b\u3088\u308a\u3001\u7ba1\u7406\u753b\u9762\u306b\u300c\u30e1\u30cb\u30e5\u30fc\u300d\u306e\u8a2d\u5b9a\u9805\u76ee\u304c\u8868\u793a\u3055\u308c\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n\n\n<h2 class=\"fz-xl\">\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u4f8b\u3068\u30b3\u30fc\u30c9\u89e3\u8aac<\/h2>\n\n<h3 class=\"fz-ml\">1. \u30e1\u30cb\u30e5\u30fc\u5185\u3067\u30b7\u30e7\u30fc\u30c8\u30b3\u30fc\u30c9\u3092\u4f7f\u3048\u308b\u3088\u3046\u306b\u3059\u308b<\/h3>\n<pre><code class=\"language-php\">\/* \u30e1\u30cb\u30e5\u30fc\u30fb\u30c6\u30ad\u30b9\u30c8\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u5185\u3067\u30b7\u30e7\u30fc\u30c8\u30b3\u30fc\u30c9\u3092\u4f7f\u3048\u308b\u3088\u3046\u306b\u3059\u308b *\/\nadd_filter(&#39;wp_nav_menu&#39;, &#39;do_shortcode&#39;);\nadd_filter(&#39;widget_text&#39;, &#39;do_shortcode&#39;);\n<\/code><\/pre>\n<p><b class=\"fw-600\">\u3067\u304d\u308b\u3088\u3046\u306b\u306a\u308b\u3053\u3068:<\/b><\/p>\n<ul style=\"list-style-type:bullet;\">\n  <li>\u30e1\u30cb\u30e5\u30fc\u306e\u30bf\u30a4\u30c8\u30eb\u3084\u30ea\u30f3\u30af\u30c6\u30ad\u30b9\u30c8\u306b\u30b7\u30e7\u30fc\u30c8\u30b3\u30fc\u30c9\u3092\u8a18\u8ff0\u3067\u304d\u308b<\/li>\n  <li>\u52d5\u7684\u306a\u30b3\u30f3\u30c6\u30f3\u30c4\u3092\u30e1\u30cb\u30e5\u30fc\u306b\u8868\u793a\u3067\u304d\u308b<\/li>\n<\/ul>\n\n<h3 class=\"fz-ml\">2. \u30ab\u30b9\u30bf\u30e0Walker\u30af\u30e9\u30b9\u3067\u8868\u793a\u3092\u30ab\u30b9\u30bf\u30de\u30a4\u30ba<\/h3>\n<p>Walker\u30af\u30e9\u30b9\u306f\u3001\u30e1\u30cb\u30e5\u30fc\u306eHTML\u51fa\u529b\u3092\u5236\u5fa1\u3059\u308b\u91cd\u8981\u306a\u4ed5\u7d44\u307f\u3067\u3059\u3002<\/p>\n<pre><code class=\"language-php\">class Custom_Walker_Nav_Menu extends Walker_Nav_Menu {\n  function start_el(&amp;$output, $item, $depth = 0, $args = array(), $id = 0) {\n    \/\/ $args\u3092\u914d\u5217\u304b\u3089\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306b\u5909\u63db\uff08PHP8\u5bfe\u5fdc\uff09\n    if (is_array($args)) {\n      $args = (object) $args;\n    }\n\n    \/\/ \u72ec\u81ea\u306eCSS\u30af\u30e9\u30b9\u3092\u8ffd\u52a0\n    $classes = empty($item-&gt;classes) ? array() : (array) $item-&gt;classes;\n    $classes&lsqb;&rsqb; = &#39;menu-item-&#39; . $item-&gt;ID;\n\n    if (isset($args-&gt;item_class)) {\n      $classes&lsqb;&rsqb; = $args-&gt;item_class;\n    }\n\n    \/\/ \u30af\u30e9\u30b9\u540d\u3092\u751f\u6210\n    $class_names = join(&#39; &#39;, apply_filters(&#39;nav_menu_css_class&#39;, array_filter($classes), $item, $args));\n    !empty($class_names) and $class_names = &#39; class=&quot;&#39; . esc_attr($class_names) . &#39;&quot;&#39;;\n\n    \/\/ \u30ea\u30b9\u30c8\u9805\u76ee\u3092\u51fa\u529b\n    $output .= &quot;&lt;li id=&#39;menu-item-$item-&gt;ID&#39; $class_names&gt;&quot;;\n\n    \/\/ \u30ea\u30f3\u30af\u306e\u5c5e\u6027\u3092\u8a2d\u5b9a\n    $attributes = !empty($item-&gt;attr_title) ? &#39; title=&quot;&#39; . esc_attr($item-&gt;attr_title) . &#39;&quot;&#39; : &#39;&#39;;\n    $attributes .= !empty($item-&gt;target) ? &#39; target=&quot;&#39; . esc_attr($item-&gt;target) . &#39;&quot;&#39; : &#39;&#39;;\n    $attributes .= !empty($item-&gt;xfn) ? &#39; rel=&quot;&#39; . esc_attr($item-&gt;xfn) . &#39;&quot;&#39; : &#39;&#39;;\n    $attributes .= !empty($item-&gt;url) ? &#39; href=&quot;&#39; . esc_attr($item-&gt;url) . &#39;&quot;&#39; : &#39;&#39;;\n    $attributes .= isset($args-&gt;link_class) ? &#39; class=&quot;&#39; . esc_attr($args-&gt;link_class) . &#39;&quot;&#39; : &#39;&#39;;\n\n    \/\/ \u2605\u91cd\u8981: \u8aac\u660e\u6587\u3092\u8868\u793a\u3059\u308b\n    $description = !empty($item-&gt;description) ? &#39;&lt;span class=&quot;menu-description&quot;&gt;&#39; . esc_attr($item-&gt;description) . &#39;&lt;\/span&gt;&#39; : &#39;&#39;;\n\n    \/\/ \u6700\u7d42\u7684\u306aHTML\u3092\u7d44\u307f\u7acb\u3066\n    $item_output = $args-&gt;before . &quot;&lt;a $attributes&gt;&quot;\n      . $args-&gt;link_before . apply_filters(&#39;the_title&#39;, $item-&gt;title, $item-&gt;ID) . $description\n      . $args-&gt;link_after . &#39;&lt;\/a&gt; &#39;\n      . $args-&gt;after;\n\n    $output .= apply_filters(&#39;walker_nav_menu_start_el&#39;, $item_output, $item, $depth, $args);\n  }\n}\n<\/code><\/pre>\n<p><b class=\"fw-600\">\u3053\u306e\u30b3\u30fc\u30c9\u306e\u91cd\u8981\u30dd\u30a4\u30f3\u30c8:<\/b><\/p>\n<ol style=\"list-style-type:decimal;\">\n  <li><b class=\"fw-600\">PHP8\u5bfe\u5fdc<\/b>: <code>$args<\/code>\u3092\u914d\u5217\u304b\u3089\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306b\u5909\u63db\u3059\u308b\u3053\u3068\u3067\u3001\u6700\u65b0\u306ePHP\u3067\u3082\u30a8\u30e9\u30fc\u304c\u51fa\u306a\u3044\u3088\u3046\u306b\u3057\u3066\u3044\u307e\u3059<\/li>\n  <li><b class=\"fw-600\">\u30ab\u30b9\u30bf\u30e0\u30af\u30e9\u30b9\u306e\u8ffd\u52a0<\/b>: <code>item_class<\/code>\u3084<code>link_class<\/code>\u3092\u6307\u5b9a\u3067\u304d\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059<\/li>\n  <li><b class=\"fw-600\">\u8aac\u660e\u6587\u306e\u8868\u793a<\/b>: \u30e1\u30cb\u30e5\u30fc\u9805\u76ee\u306e\u300c\u8aac\u660e\u300d\u30d5\u30a3\u30fc\u30eb\u30c9\u306b\u5165\u529b\u3057\u305f\u5185\u5bb9\u304c\u8868\u793a\u3055\u308c\u307e\u3059<\/li>\n<\/ol>\n\n<h3 class=\"fz-ml\">3. \u30b7\u30e7\u30fc\u30c8\u30b3\u30fc\u30c9\u3067\u30e1\u30cb\u30e5\u30fc\u3092\u547c\u3073\u51fa\u305b\u308b\u3088\u3046\u306b\u3059\u308b<\/h3>\n<p>\u901a\u5e38\u3001\u30e1\u30cb\u30e5\u30fc\u306f\u30c6\u30fc\u30de\u30d5\u30a1\u30a4\u30eb\u5185\u306e\u6c7a\u307e\u3063\u305f\u5834\u6240\u306b\u3057\u304b\u8868\u793a\u3067\u304d\u307e\u305b\u3093\u304c\u3001\u30b7\u30e7\u30fc\u30c8\u30b3\u30fc\u30c9\u3092\u4f7f\u3048\u3070\u6295\u7a3f\u3084\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u306a\u3069\u3001\u3069\u3053\u306b\u3067\u3082\u914d\u7f6e\u3067\u304d\u307e\u3059\u3002<\/p>\n<h4 class=\"fz-md\">\u30d1\u30bf\u30fc\u30f31: nav\u30bf\u30b0\u3067\u56f2\u3093\u3060\u30e1\u30cb\u30e5\u30fc\uff08cmenu\uff09<\/h4>\n<pre><code class=\"language-php\">function custom_menu_nav($atts, $content = null) {\n  extract(shortcode_atts(\n    array(\n      &#39;menu&#39; =&gt; &#39;&#39;,\n      &#39;container&#39; =&gt; &#39;nav&#39;,\n      &#39;container_class&#39; =&gt; &#39;&#39;,\n      &#39;menu_class&#39; =&gt; &#39;menu&#39;,\n      &#39;item_class&#39; =&gt; &#39;&#39;,\n      &#39;link_class&#39; =&gt; &#39;&#39;,\n      &#39;walker&#39; =&gt; new Custom_Walker_Nav_Menu(),\n      \/\/ \u305d\u306e\u4ed6\u306e\u30aa\u30d7\u30b7\u30e7\u30f3...\n    ),\n    $atts\n  ));\n  return wp_nav_menu(array(\/* \u8a2d\u5b9a *\/));\n}\nadd_shortcode(&quot;cmenu&quot;, &quot;custom_menu_nav&quot;);\n<\/code><\/pre>\n<p><b class=\"fw-600\">\u4f7f\u7528\u4f8b:<\/b><\/p>\n<pre><code class=\"language-\">&lsqb;cmenu menu=&quot;\u30e1\u30a4\u30f3\u30e1\u30cb\u30e5\u30fc&quot; container_class=&quot;header-nav&quot; menu_class=&quot;main-menu&quot; link_class=&quot;nav-link&quot;&rsqb;\n<\/code><\/pre>\n<h4 class=\"fz-md\">\u30d1\u30bf\u30fc\u30f32: ul\u30bf\u30b0\u306e\u307f\u306e\u30e1\u30cb\u30e5\u30fc\uff08ulmenu\uff09<\/h4>\n<p>container\u3092<code>false<\/code>\u306b\u3059\u308b\u3053\u3068\u3067\u3001\u4f59\u8a08\u306a\u30e9\u30c3\u30d1\u30fc\u306a\u3057\u3067ul\u30bf\u30b0\u3060\u3051\u3092\u51fa\u529b\u3057\u307e\u3059\u3002<\/p>\n<p><b class=\"fw-600\">\u4f7f\u7528\u4f8b:<\/b><\/p>\n<pre><code class=\"language-\">&lsqb;ulmenu menu=&quot;\u30b5\u30a4\u30c9\u30d0\u30fc\u30e1\u30cb\u30e5\u30fc&quot; menu_class=&quot;sidebar-menu&quot; item_class=&quot;sidebar-item&quot;&rsqb;\n<\/code><\/pre>\n<h4 class=\"fz-md\">\u30d1\u30bf\u30fc\u30f33: li\u30bf\u30b0\u306e\u307f\u306e\u30e1\u30cb\u30e5\u30fc\uff08limenu\uff09<\/h4>\n<p>container\u3082ul\u30bf\u30b0\u3082\u51fa\u529b\u305b\u305a\u3001li\u30bf\u30b0\u3060\u3051\u3092\u8868\u793a\u3057\u307e\u3059\u3002<\/p>\n<p><b class=\"fw-600\">\u4f7f\u7528\u4f8b:<\/b><\/p>\n<pre><code class=\"language-\">&lsqb;limenu menu=&quot;\u30d5\u30c3\u30bf\u30fc\u30e1\u30cb\u30e5\u30fc&quot; link_class=&quot;footer-link&quot;&rsqb;\n<\/code><\/pre>\n\n\n<h2 class=\"fz-xl\">\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3067\u5b9f\u73fe\u3067\u304d\u308b\u3053\u3068<\/h2>\n\n<h3 class=\"fz-ml\">1. \u30c7\u30b6\u30a4\u30f3\u306e\u81ea\u7531\u5ea6\u304c\u5927\u5e45\u306b\u30a2\u30c3\u30d7<\/h3>\n<ul style=\"list-style-type:bullet;\">\n  <li>\u5404\u30e1\u30cb\u30e5\u30fc\u9805\u76ee\u306b\u72ec\u81ea\u306eCSS\u30af\u30e9\u30b9\u3092\u8ffd\u52a0\u3067\u304d\u308b<\/li>\n  <li>\u30ea\u30f3\u30af\u30bf\u30b0\u306b\u76f4\u63a5\u30af\u30e9\u30b9\u3092\u6307\u5b9a\u3067\u304d\u308b<\/li>\n  <li>\u8aac\u660e\u6587\u3092\u4f7f\u3063\u3066\u30b5\u30d6\u30bf\u30a4\u30c8\u30eb\u3084\u30a2\u30a4\u30b3\u30f3\u3092\u8868\u793a\u3067\u304d\u308b<\/li>\n<\/ul>\n<p><b class=\"fw-600\">CSS\u306e\u4f8b:<\/b><\/p>\n<pre><code class=\"language-css\">.menu-description {\n  display: block;\n  font-size: 0.8em;\n  color: #666;\n  margin-top: 3px;\n}\n\n.nav-link {\n  padding: 10px 15px;\n  transition: all 0.3s;\n}\n\n.nav-link:hover {\n  background-color: #f0f0f0;\n}\n<\/code><\/pre>\n\n<h3 class=\"fz-ml\">2. \u67d4\u8edf\u306a\u30ec\u30a4\u30a2\u30a6\u30c8\u914d\u7f6e<\/h3>\n<p>\u30b7\u30e7\u30fc\u30c8\u30b3\u30fc\u30c9\u3092\u4f7f\u3046\u3053\u3068\u3067:<\/p>\n<ul style=\"list-style-type:bullet;\">\n  <li>\u6295\u7a3f\u672c\u6587\u306e\u9014\u4e2d\u306b\u30e1\u30cb\u30e5\u30fc\u3092\u633f\u5165<\/li>\n  <li>\u30a6\u30a3\u30b8\u30a7\u30c3\u30c8\u30a8\u30ea\u30a2\u306b\u30e1\u30cb\u30e5\u30fc\u3092\u914d\u7f6e<\/li>\n  <li>\u30da\u30fc\u30b8\u30d3\u30eb\u30c0\u30fc\u306e\u30d6\u30ed\u30c3\u30af\u5185\u306b\u30e1\u30cb\u30e5\u30fc\u3092\u8a2d\u7f6e<\/li>\n  <li>\u8907\u6570\u306e\u30e1\u30cb\u30e5\u30fc\u3092\u540c\u3058\u30da\u30fc\u30b8\u306b\u8868\u793a<\/li>\n<\/ul>\n\n<h3 class=\"fz-ml\">3. \u30e1\u30f3\u30c6\u30ca\u30f3\u30b9\u6027\u306e\u5411\u4e0a<\/h3>\n<ul style=\"list-style-type:bullet;\">\n  <li>\u30e1\u30cb\u30e5\u30fc\u306e\u5185\u5bb9\u306f\u7ba1\u7406\u753b\u9762\u304b\u3089\u5909\u66f4\u3067\u304d\u308b<\/li>\n  <li>\u30b3\u30fc\u30c9\u3092\u89e6\u3089\u305a\u306b\u30ca\u30d3\u30b2\u30fc\u30b7\u30e7\u30f3\u3092\u66f4\u65b0\u53ef\u80fd<\/li>\n  <li>\u8907\u6570\u306e\u30e1\u30cb\u30e5\u30fc\u3092\u7528\u9014\u5225\u306b\u7ba1\u7406\u3067\u304d\u308b<\/li>\n<\/ul>\n\n<h3 class=\"fz-ml\">4. \u5b9f\u7528\u7684\u306a\u4f7f\u7528\u4f8b<\/h3>\n<p><b class=\"fw-600\">\u4f8b1: \u30e1\u30ac\u30e1\u30cb\u30e5\u30fc\u306e\u5b9f\u88c5<\/b><\/p>\n<pre><code class=\"language-\">&lsqb;cmenu menu=&quot;\u30e1\u30ac\u30e1\u30cb\u30e5\u30fc&quot; container_class=&quot;mega-menu-wrapper&quot; item_class=&quot;mega-item&quot; link_class=&quot;mega-link&quot;&rsqb;\n<\/code><\/pre>\n<p>\u8aac\u660e\u6587\u306b\u30ab\u30c6\u30b4\u30ea\u30fc\u4e00\u89a7\u3084\u30b5\u30e0\u30cd\u30a4\u30eb\u753b\u50cf\u306eHTML\u3092\u5165\u308c\u308b\u3053\u3068\u3067\u3001\u30ea\u30c3\u30c1\u306a\u30e1\u30ac\u30e1\u30cb\u30e5\u30fc\u3092\u5b9f\u73fe\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><b class=\"fw-600\">\u4f8b2: \u30a2\u30a4\u30b3\u30f3\u4ed8\u304d\u30e1\u30cb\u30e5\u30fc<\/b><\/p>\n<p>\u30e1\u30cb\u30e5\u30fc\u9805\u76ee\u306e\u300c\u8aac\u660e\u300d\u30d5\u30a3\u30fc\u30eb\u30c9\u306bFont Awesome\u306e\u30af\u30e9\u30b9\u3092\u8a18\u8ff0:<\/p>\n<pre><code class=\"language-html\">&lt;i class=&quot;fas fa-home&quot;&gt;&lt;\/i&gt;\n<\/code><\/pre>\n<p>\u3053\u308c\u304c\u30e1\u30cb\u30e5\u30fc\u9805\u76ee\u3068\u4e00\u7dd2\u306b\u8868\u793a\u3055\u308c\u307e\u3059\u3002<\/p>\n<p><b class=\"fw-600\">\u4f8b3: \u30e9\u30f3\u30c7\u30a3\u30f3\u30b0\u30da\u30fc\u30b8\u5185\u30ca\u30d3\u30b2\u30fc\u30b7\u30e7\u30f3<\/b><\/p>\n<p>1\u30da\u30fc\u30b8\u5b8c\u7d50\u578b\u306eLP\u3067\u3001\u30bb\u30af\u30b7\u30e7\u30f3\u3054\u3068\u306e\u30a2\u30f3\u30ab\u30fc\u30ea\u30f3\u30af\u30e1\u30cb\u30e5\u30fc\u3092\u4f5c\u6210:<\/p>\n<pre><code class=\"language-\">&lsqb;ulmenu menu=&quot;LP\u7528\u30ca\u30d3&quot; menu_class=&quot;lp-nav&quot; link_class=&quot;smooth-scroll&quot;&rsqb;\n<\/code><\/pre>\n\n\n<h2 class=\"fz-xl\">\u307e\u3068\u3081<\/h2>\n<p>WordPress\u306e\u30ab\u30b9\u30bf\u30e0\u30e1\u30cb\u30e5\u30fc\u6a5f\u80fd\u3092\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3059\u308b\u3053\u3068\u3067\u3001\u4ee5\u4e0b\u304c\u5b9f\u73fe\u3067\u304d\u307e\u3059:<\/p>\n<ul style=\"list-style-type:bullet;\">\n  <li><b class=\"fw-600\">\u30c7\u30b6\u30a4\u30f3\u306e\u81ea\u7531\u5ea6\u5411\u4e0a<\/b>: CSS\u30af\u30e9\u30b9\u306e\u7d30\u304b\u3044\u5236\u5fa1\u3001\u8aac\u660e\u6587\u306e\u8868\u793a<\/li>\n  <li><b class=\"fw-600\">\u914d\u7f6e\u306e\u67d4\u8edf\u6027<\/b>: \u30b7\u30e7\u30fc\u30c8\u30b3\u30fc\u30c9\u3067\u3069\u3053\u306b\u3067\u3082\u8a2d\u7f6e\u53ef\u80fd<\/li>\n  <li><b class=\"fw-600\">\u30e1\u30f3\u30c6\u30ca\u30f3\u30b9\u6027<\/b>: \u7ba1\u7406\u753b\u9762\u304b\u3089\u7c21\u5358\u306b\u66f4\u65b0<\/li>\n  <li><b class=\"fw-600\">\u62e1\u5f35\u6027<\/b>: \u30e1\u30ac\u30e1\u30cb\u30e5\u30fc\u3084\u30a2\u30a4\u30b3\u30f3\u4ed8\u304d\u30e1\u30cb\u30e5\u30fc\u306a\u3069\u9ad8\u5ea6\u306a\u8868\u73fe<\/li>\n<\/ul>\n<p>\u4eca\u56de\u7d39\u4ecb\u3057\u305f\u30b3\u30fc\u30c9\u3092functions.php\u306b\u8ffd\u52a0\u3059\u308b\u3060\u3051\u3067\u3001\u3053\u308c\u3089\u306e\u6a5f\u80fd\u304c\u3059\u3079\u3066\u4f7f\u3048\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002\u305c\u3072\u3042\u306a\u305f\u306e\u30b5\u30a4\u30c8\u3067\u3082\u8a66\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044!<\/p>\n<hr class=\"separator mx-auto mt-3r\" \/>\n<p><b class=\"fw-600\">\u6ce8\u610f\u4e8b\u9805:<\/b><\/p>\n<ul style=\"list-style-type:bullet;\">\n  <li>functions.php\u3092\u7de8\u96c6\u3059\u308b\u524d\u306b\u3001\u5fc5\u305a\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3092\u53d6\u308a\u307e\u3057\u3087\u3046<\/li>\n  <li>\u5b50\u30c6\u30fc\u30de\u3092\u4f7f\u7528\u3057\u3066\u3044\u308b\u5834\u5408\u306f\u3001\u5b50\u30c6\u30fc\u30de\u306efunctions.php\u306b\u8a18\u8ff0\u3057\u3066\u304f\u3060\u3055\u3044<\/li>\n  <li>\u30b3\u30fc\u30c9\u3092\u30b3\u30d4\u30fc&amp;\u30da\u30fc\u30b9\u30c8\u3059\u308b\u969b\u306f\u3001\u5168\u89d2\u30b9\u30da\u30fc\u30b9\u304c\u6df7\u5165\u3057\u306a\u3044\u3088\u3046\u6ce8\u610f\u3057\u3066\u304f\u3060\u3055\u3044<\/li>\n<\/ul>","protected":false},"excerpt":{"rendered":"\u30ab\u30b9\u30bf\u30e0\u30e1\u30cb\u30e5\u30fc\u6a5f\u80fd\u3068\u306f? WordPress\u30b5\u30a4\u30c8\u3092\u904b\u55b6\u3057\u3066\u3044\u3066\u300c\u30e1\u30cb\u30e5\u30fc\u3092\u3082\u3063\u3068\u81ea\u7531\u306b\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3057\u305f\u3044\u300d\u3068\u601d\u3046\u3053\u3068\u306f\u3042\u308a\u307e\u305b\u3093\u304b\uff1f WordPress\u306e\u30ab\u30b9\u30bf\u30e0\u30e1\u30cb\u30e5\u30fc\u6a5f\u80fd\u306f\u3001\u30b5\u30a4\u30c8\u306e\u30ca\u30d3\u30b2\u30fc\u30b7\u30e7\u30f3\u30e1\u30cb\u30e5\u30fc\u3092\u81ea\u7531\u306b[...]","protected":false},"author":1,"featured_media":9391,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[9],"tags":[],"group":[],"pg":[],"class_list":["post-9389","post","type-post","status-publish","format-standard","has-post-thumbnail","category-php-wordpress"],"acf":[],"_links":{"self":[{"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/posts\/9389","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/comments?post=9389"}],"version-history":[{"count":1,"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/posts\/9389\/revisions"}],"predecessor-version":[{"id":15826,"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/posts\/9389\/revisions\/15826"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/media\/9391"}],"wp:attachment":[{"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/media?parent=9389"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/categories?post=9389"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/tags?post=9389"},{"taxonomy":"group","embeddable":true,"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/group?post=9389"},{"taxonomy":"pg","embeddable":true,"href":"https:\/\/code-plus.jp\/gp\/wp-json\/wp\/v2\/pg?post=9389"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}