{"id":5062,"date":"2026-08-30T04:50:34","date_gmt":"2026-08-29T19:50:34","guid":{"rendered":"https:\/\/donguri3.net\/server-tech\/wp-admin-multi-mind-map-plugin-2\/"},"modified":"2026-08-30T04:50:35","modified_gmt":"2026-08-29T19:50:35","slug":"wp-admin-multi-mind-map-plugin","status":"publish","type":"post","link":"https:\/\/donguri3.net\/en\/server-tech\/wordpress-blog-seo\/wp-admin-multi-mind-map-plugin\/","title":{"rendered":"Mind Elixir \u00d7 Custom WordPress Plugin: Added Features for Saving, Switching, and Deleting Multiple Mind Maps"},"content":{"rendered":"<p>Previously, I built a custom WordPress plugin that allows users to create, switch, and delete multiple mind maps directly within the WordPress dashboard (<a href=\"https:\/\/donguri3.net\/diy-repair\/wp-admin-mind-map-plugin\/\">I tried making a plugin to jot down post ideas using mind maps in the WordPress admin screen<\/a>). This time, I&#8217;ve added a multiple map management feature. It&#8217;s now a fully-featured version where you can load topics via a dropdown, save JSON data to <code>wp_options<\/code> with a prefix, and even include a delete button, a confirmation dialog, and a &#8220;New Map&#8221; button.<\/p>\n<h2 class=\"\">Final Specifications<\/h2>\n<ol>\n<li class=\"\">\n<p class=\"\"><strong>Display mind map topics in the dropdown<\/strong><\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\"><strong>Save to <code>wp_options<\/code> with the prefix <code>mind_elixir_map_data_<\/code><\/strong><\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\"><strong>Add a delete button<\/strong><\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\"><strong>Show a confirmation popup when the delete button is clicked<\/strong><\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\"><strong>Add a button to create new maps<\/strong><\/p>\n<\/li>\n<\/ol>\n<p><a href=\"https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97.png\"><img decoding=\"async\" class=\"aligncenter size-thumb710 wp-image-1522\" src=\"https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97-710x349.png\" alt=\"Mind map editor multiple mind map management\" width=\"710\" height=\"349\" srcset=\"https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97-710x349.png 710w, https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97-300x147.png 300w, https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97-1024x503.png 1024w, https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97-768x377.png 768w, https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97-530x260.png 530w, https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97-565x278.png 565w, https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97-725x356.png 725w, https:\/\/donguri3.net\/wp-content\/uploads\/2025\/05\/e06ecb7484e6b3b0265ffa769e963e97.png 1191w\" sizes=\"(max-width: 710px) 100vw, 710px\" \/><\/a><\/p>\n<hr class=\"\" \/>\n<h2 class=\"\">Implementation Highlights<\/h2>\n<h3 class=\"\">Managing Topics via Dropdown<\/h3>\n<ul>\n<li class=\"\">\n<p class=\"\">Run <code>SELECT option_name, option_value \u2026 WHERE option_name LIKE 'mind_elixir_map_data_%'<\/code> on the server side and decode the JSON<\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\">Extract the root node&#8217;s <code>nodeData.topic<\/code> and set it as the display text for <code>&lt;option&gt;<\/code><\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\">Fetch the list via AJAX on the JavaScript side and dynamically re-render using <code>$('#mea-map-selector').empty().append(...)<\/code><\/p>\n<\/li>\n<\/ul>\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary\"><\/div>\n<h3 class=\"\">Registering Options with a Prefix Upon Saving<\/h3>\n<ul>\n<li class=\"\">\n<p class=\"\">When the save button is clicked, stringify the JSON obtained from <code>mind.getData()<\/code><\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\">Generate <code>option_name<\/code> using the prefix plus the current date and time (<code>YmdHis<\/code>), and persist it via <code>update_option()<\/code><\/p>\n<\/li>\n<\/ul>\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary\"><\/div>\n<h3 class=\"\">Delete Button and Confirmation Dialog<\/h3>\n<ul>\n<li class=\"\">\n<p class=\"\">Trigger a confirmation popup using <code>window.confirm()<\/code> when the button is pressed<\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\">If OK, execute <code>delete_option()<\/code> via AJAX and re-render the list upon success<\/p>\n<\/li>\n<\/ul>\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary\"><\/div>\n<h3 class=\"\">New Map Addition Button<\/h3>\n<ul>\n<li class=\"\">\n<p class=\"\">Generate data from <code>MindElixir.new()<\/code> with a fixed topic of &#8220;New Mind Map&#8221;<\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\">Add a new option to the dropdown, making it immediately ready for loading and saving<\/p>\n<\/li>\n<\/ul>\n<div class=\"contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary\">\n<div class=\"overflow-y-auto p-4\" dir=\"ltr\"><\/div>\n<\/div>\n<hr class=\"\" \/>\n<h2 class=\"\">Conclusion<\/h2>\n<p class=\"\">With this plugin, I implemented an administrative interface that makes it easy to save, switch, and delete mind maps using WordPress&#8217;s <code>wp_options<\/code> table.<\/p>\n<ul>\n<li class=\"\">\n<p class=\"\"><strong>Dropdown<\/strong>: List items by topic<\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\"><strong>Save<\/strong>: Automatically generate option names using prefix + timestamp<\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\"><strong>Delete<\/strong>: Safely remove items with a confirmation dialog<\/p>\n<\/li>\n<li class=\"\">\n<p class=\"\"><strong>New Addition<\/strong>: Generate a blank map with a single button<\/p>\n<\/li>\n<\/ul>\n<p class=\"\">The GitHub repository is also publicly available, so please give it a try!<\/p>\n<blockquote>\n<p class=\"\"><a class=\"\" href=\"https:\/\/github.com\/bomura\/wp-mind-elixir-admin\" target=\"_new\" rel=\"noopener\">https:\/\/github.com\/bomura\/wp-mind-elixir-admin<\/a><\/p>\n<\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>Previously, I built a custom WordPress plugin that allows users to create, switch, and delete multiple mind ma [&hellip;]<\/p>\n","protected":false},"author":4,"featured_media":1522,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_locale":"en_US","_original_post":"https:\/\/donguri3.net\/?p=1521","footnotes":""},"categories":[1166],"tags":[51,52,61,150,10,179,531],"class_list":["post-5062","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-wordpress-blog-seo","tag-git","tag-https","tag-wordpress","tag-server","tag-179","tag-531","en-US"],"_links":{"self":[{"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/posts\/5062","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/comments?post=5062"}],"version-history":[{"count":1,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/posts\/5062\/revisions"}],"predecessor-version":[{"id":5065,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/posts\/5062\/revisions\/5065"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/media\/1522"}],"wp:attachment":[{"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/media?parent=5062"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/categories?post=5062"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/donguri3.net\/wp-json\/wp\/v2\/tags?post=5062"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}