{"id":2775,"date":"2013-04-26T15:29:21","date_gmt":"2013-04-26T06:29:21","guid":{"rendered":"http:\/\/www.lancard.com\/blog\/?p=2775"},"modified":"2025-03-12T11:29:02","modified_gmt":"2025-03-12T02:29:02","slug":"roundcube%e3%81%ae%e3%83%9c%e3%82%bf%e3%83%b3%e3%81%ae%e4%bd%bf%e3%81%84%e6%96%b9","status":"publish","type":"post","link":"https:\/\/www.lancard.com\/blog\/2013\/04\/26\/roundcube%e3%81%ae%e3%83%9c%e3%82%bf%e3%83%b3%e3%81%ae%e4%bd%bf%e3%81%84%e6%96%b9\/","title":{"rendered":"Roundcube\u306e\u30dc\u30bf\u30f3\u306e\u4f7f\u3044\u65b9"},"content":{"rendered":"<p>Roundcube\u306e\u30dc\u30bf\u30f3\u306e\u4f7f\u3044\u65b9\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002<\/p>\n<p>\u2460\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3078\u306e\u8a2d\u7f6e\u65b9\u6cd5\u306f\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre line=\"1\" lang=\"php\">\r\n<roundcube:button command=\"get_data\" type=\"input\" class=\"button mainaction\" label=\"sample.get_data\" \/>\r\n<\/pre>\n<p>\u3053\u306e\u3088\u3046\u306b\u66f8\u3044\u3066\u304a\u304f\u3068\u3001\u6b21\u306e\u3088\u3046\u306b\u51fa\u529b\u3055\u308c\u307e\u3059\u3002<\/p>\n<pre line=\"1\" lang=\"html\">\r\n<input type=\"button\" class=\"button mainaction\" id=\"rcmbtn107\" onclick=\"return rcmail.command('get_data','',this)\" value=\"\u30c7\u30fc\u30bf\u53d6\u5f97\" disabled=\"disabled\">\r\n<\/pre>\n<p>\u2461\u30a4\u30d9\u30f3\u30c8\u3092\u3069\u3046\u51e6\u7406\u3059\u308b\u304b\uff1f<\/p>\n<p>\u3053\u306e\u3088\u3046\u306b\u66f8\u304d\u307e\u3059\u3002<\/p>\n<pre line=\"1\" lang=\"javascript\">\r\nif (window.rcmail) {\r\nrcmail.addEventListener('init', function() {\r\nrcmail.enable_command('get_data', true);\r\n});\r\n}\r\n\r\nrcube_webmail.prototype.get_data = function()\r\n{\r\nconsole.log('get_data');\r\n}\r\n<\/pre>\n<p>\u2462rcmail.enable_command(&#8216;get_data&#8217;, true);\u306e<br \/>\n\u3000\u6700\u5f8c\u306e\u5f15\u6570\u3067\u305d\u306e\u30dc\u30bf\u30f3\u3092\u6709\u52b9\u306b\u3059\u308b\u304b\u7121\u52b9\u306b\u3059\u308b\u304b\u6307\u5b9a\u3057\u307e\u3059\u3002<br \/>\n\u3000\u3000\u8a66\u3057\u306b\uff12\u3064\u306e\u30dc\u30bf\u30f3\u3092\u8a2d\u7f6e\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n<pre line=\"1\" lang=\"php\">\r\n<roundcube:button command=\"btn1\" type=\"input\" class=\"button mainaction\" label=\"sample.btn1\" \/>\r\n<roundcube:button command=\"btn2\" type=\"input\" class=\"button mainaction\" label=\"sample.btn2\" \/>\r\n<\/pre>\n<p>\u30c7\u30d5\u30a9\u30eb\u30c8\u3067\u306f\u3069\u3061\u3089\u3082\u7121\u52b9\u306b\u306a\u308a\u307e\u3059\u3002<br \/>\n<a href=\"http:\/\/www.lancard.com\/blog\/wp-content\/uploads\/2013\/04\/img11.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.lancard.com\/blog\/wp-content\/uploads\/2013\/04\/img11.png\" alt=\"\" title=\"img1\" width=\"342\" height=\"135\" class=\"aligncenter size-full wp-image-2782\" \/><\/a><\/p>\n<p>\u6b21\u306e\u3088\u3046\u306bjavascript\u3092\u8a18\u8ff0\u3057\u307e\u3059\u3002<\/p>\n<pre line=\"1\" lang=\"javascript\">\r\nif (window.rcmail) {\r\nrcmail.addEventListener('init', function() {\r\nrcmail.enable_command('btn1', true);\r\nrcmail.enable_command('btn2', false);\r\n});\r\n}\r\nrcube_webmail.prototype.btn1 = function()\r\n{\r\nconsole.log('btn1');\r\n}\r\nrcube_webmail.prototype.btn2 = function()\r\n{\r\nconsole.log('btn2');\r\n}\r\n<\/pre>\n<p><a href=\"http:\/\/www.lancard.com\/blog\/wp-content\/uploads\/2013\/04\/img21.png\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.lancard.com\/blog\/wp-content\/uploads\/2013\/04\/img21.png\" alt=\"\" title=\"img2\" width=\"209\" height=\"115\" class=\"aligncenter size-full wp-image-2787\" \/><\/a><\/p>\n<p>\u30dc\u30bf\u30f3\u306f\uff12\u3064\u3068\u3082\u898b\u304b\u3051\u4e0a\u6709\u52b9\u306b\u306a\u308a\u307e\u3059\u3002<br \/>\n\u3057\u304b\u3057\u3001\u30dc\u30bf\u30f3\uff11\u3092\u30af\u30ea\u30c3\u30af\u3059\u308b\u3068\u30b3\u30f3\u30bd\u30fc\u30eb\u306b&#8217;btn1&#8217;\u304c\u8868\u793a\u3055\u308c\u307e\u3059\u304c\u3001\u30dc\u30bf\u30f3\uff12\u3092\u30af\u30ea\u30c3\u30af\u3057\u3066\u3082\u4f55\u3082\u8d77\u3053\u308a\u307e\u305b\u3093\u3002<\/p>\n<p>\u2463\u5f15\u6570\u3092\u6e21\u3059\u306b\u306f\u3069\u3046\u3059\u308b\u304b\u3002<\/p>\n<p>prop\u5c5e\u6027\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<br \/>\n\u3053\u306e\u3088\u3046\u306b\u66f8\u304f\u3068<\/p>\n<pre line=\"1\" lang=\"html\">\r\n<roundcube:button command=\"btn1\" type=\"input\" class=\"button mainaction\" label=\"ajax_sample.btn1\" prop=\"test\" \/>\r\n<\/pre>\n<p>\u6b21\u306e\u3088\u3046\u306b\u51fa\u529b\u3057\u3066\u304f\u308c\u307e\u3059\u3002<\/p>\n<pre line=\"1\" lang=\"html\">\r\n<input type=\"button\" class=\"button mainaction\" id=\"rcmbtn107\" onclick=\"return rcmail.command('btn1','test',this)\" value=\"\u30dc\u30bf\u30f3\uff11\" disabled=\"disabled\">\r\n<\/pre>\n<p>\u3000\u3000rcmail.command(&#8216;btn1&#8242;,&#8217;test&#8217;,this)\u3053\u306e\u90e8\u5206\u306e\u7b2c\u4e8c\u5f15\u6570\u306bprop\u3067\u6307\u5b9a\u3057\u305f\u5024\u304c\u5165\u3063\u3066\u304d\u307e\u3059\u3002<\/p>\n<p>\u3000\u3000javascript\u5074\u3067\u306f\u7b2c\u4e00\u5f15\u6570\u3067\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<pre line=\"1\" lang=\"javascript\">\r\nrcube_webmail.prototype.btn1 = function(value)\r\n{\r\nconsole.log(value);\r\n}\r\n<\/pre>\n<p>\u4e0a\u8a18\u306e\u3088\u3046\u306b\u8a18\u8ff0\u3059\u308b\u3068\u30b3\u30f3\u30bd\u30fc\u30eb\u306b&#8217;test&#8217;\u3068\u8868\u793a\u3055\u308c\u307e\u3059\u3002<\/p>\n<p>\u2464\u8907\u6570\u306e\u5f15\u6570\u3092\u6307\u5b9a\u51fa\u6765\u308b\u304b\u3002<\/p>\n<p>\u30dc\u30bf\u30f3\u306eclick\u51e6\u7406\u3092\u51fa\u529b\u3059\u308b\u306e\u306f<br \/>\n\/roundcuberoot\/program\/include\/rcube_template.php\u306e978\u884c\u76ee\u306e\u4ee5\u4e0b\u306e\u30b3\u30fc\u30c9\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre line=\"1\" lang=\"php\">\r\n$attrib['onclick'] = sprintf(\r\n\"return %s.command('%s','%s',this)\",\r\nJS_OBJECT_NAME,\r\n$command,\r\n$attrib['prop']\r\n);\r\n<\/pre>\n<p>\u4e0a\u8a18\u306e\u30b3\u30fc\u30c9\u306e\u901a\u308a\u3001\u8907\u6570\u306e\u5f15\u6570\u3092\u6307\u5b9a\u3059\u308b\u3053\u3068\u306f\u7121\u7406\u305d\u3046\u3067\u3059\u306d\u30fb\u30fb\u3002<\/p>\n<a class=\"synved-social-button synved-social-button-share synved-social-size-24 synved-social-resolution-single synved-social-provider-facebook nolightbox\" data-provider=\"facebook\" target=\"_blank\" rel=\"nofollow\" title=\"Share on Facebook\" href=\"https:\/\/www.facebook.com\/sharer.php?u=https%3A%2F%2Fwww.lancard.com%2Fblog%2Fwp-json%2Fwp%2Fv2%2Fposts%2F2775&#038;t=Roundcube%E3%81%AE%E3%83%9C%E3%82%BF%E3%83%B3%E3%81%AE%E4%BD%BF%E3%81%84%E6%96%B9&#038;s=100&#038;p&#091;url&#093;=https%3A%2F%2Fwww.lancard.com%2Fblog%2Fwp-json%2Fwp%2Fv2%2Fposts%2F2775&#038;p&#091;images&#093;&#091;0&#093;=http%3A%2F%2Fwww.lancard.com%2Fblog%2Fwp-content%2Fuploads%2F2013%2F04%2Fimg11.png&#038;p&#091;title&#093;=Roundcube%E3%81%AE%E3%83%9C%E3%82%BF%E3%83%B3%E3%81%AE%E4%BD%BF%E3%81%84%E6%96%B9\" style=\"font-size: 0px;width:24px;height:24px;margin:0;margin-bottom:5px;margin-right:5px\"><img loading=\"lazy\" decoding=\"async\" alt=\"Facebook\" title=\"Share on Facebook\" class=\"synved-share-image synved-social-image synved-social-image-share\" width=\"24\" height=\"24\" style=\"display: inline;width:24px;height:24px;margin: 0;padding: 0;border: none;box-shadow: none\" src=\"https:\/\/www.lancard.com\/blog\/wp-content\/plugins\/social-media-feather\/synved-social\/image\/social\/regular\/48x48\/facebook.png\" \/><\/a><a class=\"synved-social-button synved-social-button-share synved-social-size-24 synved-social-resolution-single synved-social-provider-twitter nolightbox\" data-provider=\"twitter\" target=\"_blank\" rel=\"nofollow\" title=\"Share on Twitter\" href=\"http:\/\/twitter.com\/share?url=https%3A%2F%2Fwww.lancard.com%2Fblog%2Fwp-json%2Fwp%2Fv2%2Fposts%2F2775&#038;text=Roundcube%E3%81%AE%E3%83%9C%E3%82%BF%E3%83%B3%E3%81%AE%E4%BD%BF%E3%81%84%E6%96%B9\" style=\"font-size: 0px;width:24px;height:24px;margin:0;margin-bottom:5px;margin-right:5px\"><img loading=\"lazy\" decoding=\"async\" alt=\"twitter\" title=\"Share on Twitter\" class=\"synved-share-image synved-social-image synved-social-image-share\" width=\"24\" height=\"24\" style=\"display: inline;width:24px;height:24px;margin: 0;padding: 0;border: none;box-shadow: none\" src=\"https:\/\/www.lancard.com\/blog\/wp-content\/plugins\/social-media-feather\/synved-social\/image\/social\/regular\/48x48\/twitter.png\" \/><\/a><a class=\"synved-social-button synved-social-button-share synved-social-size-24 synved-social-resolution-single synved-social-provider-linkedin nolightbox\" data-provider=\"linkedin\" target=\"_blank\" rel=\"nofollow\" title=\"Share on Linkedin\" href=\"https:\/\/www.linkedin.com\/shareArticle?mini=true&#038;url=https%3A%2F%2Fwww.lancard.com%2Fblog%2Fwp-json%2Fwp%2Fv2%2Fposts%2F2775&#038;title=Roundcube%E3%81%AE%E3%83%9C%E3%82%BF%E3%83%B3%E3%81%AE%E4%BD%BF%E3%81%84%E6%96%B9\" style=\"font-size: 0px;width:24px;height:24px;margin:0;margin-bottom:5px;margin-right:5px\"><img loading=\"lazy\" decoding=\"async\" alt=\"linkedin\" title=\"Share on Linkedin\" class=\"synved-share-image synved-social-image synved-social-image-share\" width=\"24\" height=\"24\" style=\"display: inline;width:24px;height:24px;margin: 0;padding: 0;border: none;box-shadow: none\" src=\"https:\/\/www.lancard.com\/blog\/wp-content\/plugins\/social-media-feather\/synved-social\/image\/social\/regular\/48x48\/linkedin.png\" \/><\/a><a class=\"synved-social-button synved-social-button-share synved-social-size-24 synved-social-resolution-single synved-social-provider-tumblr nolightbox\" data-provider=\"tumblr\" target=\"_blank\" rel=\"nofollow\" title=\"Share on tumblr\" href=\"https:\/\/tumblr.com\/share?s=&#038;v=3&#038;t=Roundcube%E3%81%AE%E3%83%9C%E3%82%BF%E3%83%B3%E3%81%AE%E4%BD%BF%E3%81%84%E6%96%B9&#038;u=https%3A%2F%2Fwww.lancard.com%2Fblog%2Fwp-json%2Fwp%2Fv2%2Fposts%2F2775\" style=\"font-size: 0px;width:24px;height:24px;margin:0;margin-bottom:5px;margin-right:5px\"><img loading=\"lazy\" decoding=\"async\" alt=\"tumblr\" title=\"Share on tumblr\" class=\"synved-share-image synved-social-image synved-social-image-share\" width=\"24\" height=\"24\" style=\"display: inline;width:24px;height:24px;margin: 0;padding: 0;border: none;box-shadow: none\" src=\"https:\/\/www.lancard.com\/blog\/wp-content\/plugins\/social-media-feather\/synved-social\/image\/social\/regular\/48x48\/tumblr.png\" \/><\/a><a class=\"synved-social-button synved-social-button-share synved-social-size-24 synved-social-resolution-single synved-social-provider-mail nolightbox\" data-provider=\"mail\" rel=\"nofollow\" title=\"Share by email\" href=\"mailto:?subject=Roundcube%E3%81%AE%E3%83%9C%E3%82%BF%E3%83%B3%E3%81%AE%E4%BD%BF%E3%81%84%E6%96%B9&#038;body=%E3%82%B7%E3%82%A7%E3%82%A2%E3%81%99%E3%82%8B%EF%BC%9A:%20https%3A%2F%2Fwww.lancard.com%2Fblog%2Fwp-json%2Fwp%2Fv2%2Fposts%2F2775\" style=\"font-size: 0px;width:24px;height:24px;margin:0;margin-bottom:5px\"><img loading=\"lazy\" decoding=\"async\" alt=\"mail\" title=\"Share by email\" class=\"synved-share-image synved-social-image synved-social-image-share\" width=\"24\" height=\"24\" style=\"display: inline;width:24px;height:24px;margin: 0;padding: 0;border: none;box-shadow: none\" src=\"https:\/\/www.lancard.com\/blog\/wp-content\/plugins\/social-media-feather\/synved-social\/image\/social\/regular\/48x48\/mail.png\" \/><\/a>","protected":false},"excerpt":{"rendered":"<p>Roundcube\u306e\u30dc\u30bf\u30f3\u306e\u4f7f\u3044\u65b9\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002 \u2460\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3078\u306e\u8a2d\u7f6e\u65b9\u6cd5\u306f\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002 \u3053\u306e\u3088\u3046\u306b\u66f8\u3044\u3066\u304a\u304f\u3068\u3001\u6b21\u306e\u3088\u3046\u306b\u51fa\u529b\u3055\u308c\u307e\u3059\u3002 \u2461\u30a4\u30d9\u30f3\u30c8\u3092\u3069\u3046\u51e6\u7406\u3059\u308b\u304b\uff1f \u3053\u306e\u3088\u3046\u306b\u66f8\u304d\u307e\u3059\u3002 if (wind [&hellip;]<\/p>\n","protected":false},"author":21,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[99],"tags":[],"class_list":["post-2775","post","type-post","status-publish","format-standard","hentry","category-roundcube"],"_links":{"self":[{"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/posts\/2775","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/users\/21"}],"replies":[{"embeddable":true,"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/comments?post=2775"}],"version-history":[{"count":16,"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/posts\/2775\/revisions"}],"predecessor-version":[{"id":2793,"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/posts\/2775\/revisions\/2793"}],"wp:attachment":[{"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/media?parent=2775"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/categories?post=2775"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.lancard.com\/blog\/wp-json\/wp\/v2\/tags?post=2775"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}