{"id":12802,"date":"2020-10-22T10:35:55","date_gmt":"2020-10-22T10:35:55","guid":{"rendered":"https:\/\/www.mageworx.com\/blog\/?p=12802"},"modified":"2023-03-17T12:51:50","modified_gmt":"2023-03-17T12:51:50","slug":"how-to-change-titles-of-options-and-option-values","status":"publish","type":"post","link":"https:\/\/www.mageworx.com\/blog\/how-to-change-titles-of-options-and-option-values","title":{"rendered":"How to Remove + Sign from Customizable Option Titles in Magento 2 Programmatically?"},"content":{"rendered":"\n<!-- SEO Ultimate (http:\/\/www.seodesignsolutions.com\/wordpress-seo\/) - Code Inserter module -->\n<!-- Google Tag Manager (noscript) -->\r\n<noscript><iframe src=\"https:\/\/www.googletagmanager.com\/ns.html?id=GTM-5DTCW7B8\"\r\nheight=\"0\" width=\"0\" style=\"display:none;visibility:hidden\"><\/iframe><\/noscript>\r\n<!-- End Google Tag Manager (noscript) -->\n<!-- \/SEO Ultimate -->\n\n<span class=\"span-reading-time rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\"> 5<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span>\n<p>Product options customization is vital to meet business needs.<br><\/p>\n\n\n\n<p>In this article, we will focus on how to change the titles of the selected options and consider two examples.<br><\/p>\n\n\n\n<p>In the first example,<br><\/p>\n\n\n\n<p>We will focus on how to change titles of the selected option values of the \u201cselectable\u201d type with the help of the Mageworx <a href=\"https:\/\/www.mageworx.com\/magento-2-advanced-product-options-suite.html\">Advanced Product Options<\/a> extension and \u201cjs\u201d.<br><\/p>\n\n\n\n<p>In the second example,<br><\/p>\n\n\n\n<p>We will focus on how to change the titles of \u201cnon-selectable\u201d options with the help of \u201cphp\u201d.<br><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">New Module Creation<\/h2>\n\n\n\n<p>New module creation was described in detail in <a href=\"https:\/\/www.mageworx.com\/blog\/advanced-product-options-customization\" data-type=\"URL\" data-id=\"https:\/\/www.mageworx.com\/blog\/advanced-product-options-customization\">this blog post<\/a>.<br><\/p>\n\n\n\n<p>Thus, let\u2019s not focus on it today and move straight to the code. Here\u2019s the code we&#8217;ll need:<br><\/p>\n\n\n\n<p><strong>1.composer.json<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n    \"name\": \"mageworx\/module-optionremoveplus\",\n    \"description\": \"N\/A\",\n    \"require\": {\n        \"magento\/framework\"     :     \"&gt;=100.1.0 &lt;101\",\n        \"magento\/module-catalog\":     \"&gt;=101.0.0 &lt;104\"\n    },\n    \"type\": \"magento2-module\",\n    \"version\": \"1.0.0\",\n    \"license\": &#91;\n        \"OSL-3.0\",\n        \"AFL-3.0\"\n    ],\n    \"autoload\": {\n        \"files\": &#91;\n            \"registration.php\"\n        ],\n        \"psr-4\": {\n            \"VendorName\\\\OptionRemovePlus\\\\\": \"\"\n        }\n    }\n}\n<\/code><\/pre>\n\n\n\n<p><strong>2.etc\/module.xml<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;?xml version=\"1.0\"?&gt;\n\n&lt;config xmlns:xsi=\"http:\/\/www.w3.org\/2001\/XMLSchema-instance\" xsi:noNamespaceSchemaLocation=\"urn:magento:framework:Module\/etc\/module.xsd\"&gt;\n    &lt;module name=\"VendorName_OptionRemovePlus\" setup_version=\"1.0.0\"&gt;\n        &lt;sequence&gt;\n            &lt;module name=\"Magento_Catalog\"\/&gt;\n            &lt;module name=\"MageWorx_OptionBase\"\/&gt;\n        &lt;\/sequence&gt;\n    &lt;\/module&gt;\n&lt;\/config&gt;\n<\/code><\/pre>\n\n\n\n<p><strong>3. registration.php<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;?php\n\\Magento\\Framework\\Component\\ComponentRegistrar::register(\n    \\Magento\\Framework\\Component\\ComponentRegistrar::MODULE,\n    'VendorName_OptionRemovePlus',\n    __DIR__\n);<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Example #1. Changing Titles of Other Option Types<\/h2>\n\n\n\n<p>Here, we will cover such input types as <strong>drop-down, radio button, checkbox,<\/strong> and <strong>multiple select<\/strong>.<br><\/p>\n\n\n\n<p>Let\u2019s delete the <strong>+ <\/strong>sign from the titles of selected option values. We will achieve this with the help of our Advanced Product Options extension.&nbsp;<br><\/p>\n\n\n\n<p>Out of the box, Advanced Product Options has the functionality to handle titles of the selected option values on the front-end of product pages. It gets achieved with the help of \u201cjs\u201d in<\/p>\n\n\n\n<p> <code>app\/code\/MageWorx\/OptionBase\/view\/base\/web\/js\/catalog\/product\/base.js<\/code>.<br><\/p>\n\n\n\n<p>Before we begin, create a test product that has all the types of selectable options. It is done to see how these option values look on the front-end by default.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/lh5.googleusercontent.com\/EhplZn2XeHd2yl6D7h681ETzDlWDMx1sIDM1YvMrkd2EE2KD08iScPzDDQQFW-b4fLu1U1agPUaJ0XdVDbCm-AaEoII_bflWjmEATzKwrLRHvin7KLUNpyeFOM58eUQYTXASstFe\" alt=\"Product Options Customization in Magento 2 | Mageworx Magento Blog\"\/><\/figure><\/div>\n\n\n\n<p>How about changing these titles?<\/p>\n\n\n\n<p>To do that, we will need to rewrite a couple of functions from <code>app\/code\/MageWorx\/OptionBase\/view\/base\/web\/js\/catalog\/product\/base.js<\/code>.<\/p>\n\n\n\n<p>Let\u2019s use the known <strong>JavaScript mixins <\/strong>mechanism to achieve that.&nbsp;<\/p>\n\n\n\n<p>Create the following file and define our mixin there:<\/p>\n\n\n\n<p><code>app\/code\/VendorName\/OptionRemovePlus\/view\/base\/requirejs-config.js<\/code><br><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>var config = {\n    config: {\n        mixins: {\n            'MageWorx_OptionBase\/js\/catalog\/product\/base': {\n                'VendorName_OptionRemovePlus\/js\/catalog\/product\/base-mixin' : true\n            }\n        }\n    }\n};\n<\/code><\/pre>\n\n\n\n<p>Now, create the following file with the redefined functions that we need:<\/p>\n\n\n\n<p><code>app\/code\/VendorName\/OptionRemovePlus\/view\/base\/web\/js\/catalog\/product\/base-mixin.js<\/code><br><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>define(&#91;\n   'jquery',\n   'Magento_Catalog\/js\/price-utils',\n   'uiRegistry',\n   'underscore',\n   'mage\/template',\n   'jquery\/ui'\n], function ($, utils, registry, _, mageTemplate) {\n   'use strict';\n\n   return function (widget) {\n       $.widget('mageworx.optionBase', widget, {\n\n           \/**\n            * Make changes to select options\n            * @param options\n            * @param opConfig\n            *\/\n           _updateSelectOptions: function(options, opConfig)\n           {\n               var self = this;\n               options.each(function (index, element) {\n                   var $element = $(element);\n\n                   if ($element.hasClass('datetime-picker') ||\n                       $element.hasClass('text-input') ||\n                       $element.hasClass('input-text') ||\n                       $element.attr('type') == 'file'\n                   ) {\n                       return true;\n                   }\n\n                   var optionId = utils.findOptionId($element),\n                       optionConfig = opConfig&#91;optionId];\n\n                   $element.find('option').each(function (idx, option) {\n                       var $option = $(option),\n                           optionValue = $option.val();\n\n                       if (!optionValue &amp;&amp; optionValue !== 0) {\n                           return;\n                       }\n\n                       var title = optionConfig&#91;optionValue] &amp;&amp; optionConfig&#91;optionValue].name,\n                           valuePrice = utils.formatPrice(optionConfig&#91;optionValue].prices.finalPrice.amount),\n                           stockMessage = '',\n                           specialPriceDisplayNode = '';\n\n                       if (optionConfig&#91;optionValue]) {\n                           if (!_.isEmpty(optionConfig&#91;optionValue].special_price_display_node)) {\n                               specialPriceDisplayNode = optionConfig&#91;optionValue].special_price_display_node;\n                           }\n                           if (!_.isEmpty(optionConfig&#91;optionValue].stockMessage)) {\n                               stockMessage = optionConfig&#91;optionValue].stockMessage;\n                           }\n                           if (!_.isEmpty(optionConfig&#91;optionValue].title)) {\n                               title = optionConfig&#91;optionValue].title;\n                           }\n                           if (!_.isEmpty(optionConfig&#91;optionValue].valuePrice)) {\n                               valuePrice = optionConfig&#91;optionValue].valuePrice;\n                           }\n                       }\n                       if (specialPriceDisplayNode) {\n                           $option.text(title + ' ' + specialPriceDisplayNode + ' ' + stockMessage);\n                       } else if (stockMessage) {\n                           if (parseFloat(optionConfig&#91;optionValue].prices.finalPrice.amount) &gt; 0) {\n                               $option.text(title + ' +' + valuePrice + ' ' + stockMessage);\n                           } else {\n                               $option.text(title + stockMessage);\n                           }\n                       }\n\n                       $option.text(title + ' ' + valuePrice + ' ' + stockMessage);\n                   });\n               });\n           },\n\n           \/**\n            * Make changes to select options\n            * @param options\n            * @param opConfig\n            *\/\n           _updateInputOptions: function(options, opConfig)\n           {\n               var self = this;\n               options.each(function (index, element) {\n                   var $element = $(element);\n\n                   if ($element.hasClass('datetime-picker') ||\n                       $element.hasClass('text-input') ||\n                       $element.hasClass('input-text') ||\n                       $element.attr('type') == 'file'\n                   ) {\n                       return true;\n                   }\n\n                   var optionId = utils.findOptionId($element),\n                       optionValue = $element.val();\n\n                   if (!optionValue &amp;&amp; optionValue !== 0) {\n                       return;\n                   }\n\n                   var optionConfig = opConfig&#91;optionId],\n                       title = optionConfig&#91;optionValue] &amp;&amp; optionConfig&#91;optionValue].name,\n                       valuePrice = utils.formatPrice(optionConfig&#91;optionValue].prices.finalPrice.amount),\n                       stockMessage = '',\n                       specialPriceDisplayNode = '';\n\n                   if (optionConfig&#91;optionValue]) {\n                       if (!_.isEmpty(optionConfig&#91;optionValue].special_price_display_node)) {\n                           specialPriceDisplayNode = optionConfig&#91;optionValue].special_price_display_node;\n                       }\n                       if (!_.isEmpty(optionConfig&#91;optionValue].stockMessage)) {\n                           stockMessage = optionConfig&#91;optionValue].stockMessage;\n                       }\n                       if (!_.isEmpty(optionConfig&#91;optionValue].title)) {\n                           title = optionConfig&#91;optionValue].title;\n                       }\n                       if (!_.isEmpty(optionConfig&#91;optionValue].valuePrice)) {\n                           valuePrice = optionConfig&#91;optionValue].valuePrice;\n                       }\n                   }\n                   if (specialPriceDisplayNode) {\n                       $element.next('label').text(title + ' ' + specialPriceDisplayNode + ' ' + stockMessage);\n                   } else if (stockMessage) {\n                       if (parseFloat(optionConfig&#91;optionValue].prices.finalPrice.amount) &gt; 0) {\n                           $element.next('label').text(title + ' +' + valuePrice + ' ' + stockMessage);\n                       } else {\n                           $element.next('label').text(title + stockMessage);\n                       }\n                   }\n\n                   $element.next('label').text(title + ' ' + valuePrice + ' ' + stockMessage);\n               });\n           },\n\n       });\n       return $.mageworx.optionBase;\n   };\n\n});<\/code><\/pre>\n\n\n\n<p>Here\u2019s the result:<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/lh4.googleusercontent.com\/vQPkdTWln7Q12CMiQ5vngZhAkLRgHo0w6gDe1jPzgLcDXNT1xG7LDEEwnvqkzqAbLBT12_7_OJCslU-2kccdogBZAuYms9WMlIp6szYvEPGLZEaHn5Bj8XnAcKg9_hO6wMBjzSoO\" alt=\"Product Options Customization in Magento 2 | Mageworx Magento Blog\"\/><\/figure><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Example #2. Changing Titles of Selected Option Values&nbsp;<\/h2>\n\n\n\n<p>Here, we will cover such input types as <strong>field, area, file, date, time,<\/strong> and <strong>date &amp; time<\/strong>.<br><\/p>\n\n\n\n<p>Let\u2019s delete the <strong>+ <\/strong>sign from the titles of selected option values. We will achieve this with the help of PHP, rewrite the classes that implement this method of the needed option type.<br><\/p>\n\n\n\n<p>Before we begin, create a test product that has all the types of selectable options. It is done to see how these option values look on the front-end by default.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/lh4.googleusercontent.com\/Wi8XF-1JjGaMiTmX2zi1e8vFHx53LV8gDzrwnmA_eKBli-iAqqsq1ubI1zvkV6IQgod1yzBkO3xWXxGJhdNb4TyPaU2k1XO8iCzRiuSizFQFq7e63bRkqFiE0NQXzhRTP3oy5UOZ\" alt=\"Product Options Customization in Magento 2 | Mageworx Magento Blog\"\/><\/figure><\/div>\n\n\n\n<p>Now, create the following file:<br><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;?xml version=\"1.0\"?&gt;\n&lt;config xmlns:xsi=\"http:\/\/www.w3.org\/2001\/XMLSchema-instance\" xsi:noNamespaceSchemaLocation=\"urn:magento:framework:ObjectManager\/etc\/config.xsd\"&gt;\n    &lt;preference for=\"Magento\\Catalog\\Block\\Product\\View\\Options\\Type\\Text\"\n                type=\"VendorName\\OptionRemovePlus\\Block\\Product\\View\\Options\\Type\\Text\" \/&gt;\n    &lt;preference for=\"Magento\\Catalog\\Block\\Product\\View\\Options\\Type\\Date\"\n                type=\"VendorName\\OptionRemovePlus\\Block\\Product\\View\\Options\\Type\\Date\" \/&gt;\n    &lt;preference for=\"Magento\\Catalog\\Block\\Product\\View\\Options\\Type\\File\"\n                type=\"VendorName\\OptionRemovePlus\\Block\\Product\\View\\Options\\Type\\File\" \/&gt;\n&lt;\/config&gt;<\/code><\/pre>\n\n\n\n<p>It\u2019s time to create our classes and to rewrite the method:<\/p>\n\n\n\n<p><code>app\/code\/VendorName\/OptionRemovePlus\/Block\/Product\/View\/Options\/Type\/Date.php<\/code><br><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;?php\nnamespace VendorName\\OptionRemovePlus\\Block\\Product\\View\\Options\\Type;\n\nuse Magento\\Catalog\\Pricing\\Price\\CustomOptionPriceInterface;\n\n\/**\n * Product options text type block\n *\n * @api\n * @since 100.0.2\n *\/\nclass Date extends \\Magento\\Catalog\\Block\\Product\\View\\Options\\Type\\Date\n{\n    \/**\n     * Return formatted price\n     *\n     * @param array $value\n     * @param bool $flag\n     * @return string\n     *\/\n    protected function _formatPrice($value, $flag = true)\n    {\n        if ($value&#91;'pricing_value'] == 0) {\n            return '';\n        }\n\n        $sign = ' ';\n        if ($value&#91;'pricing_value'] &lt; 0) {\n            $sign = '-';\n            $value&#91;'pricing_value'] = 0 - $value&#91;'pricing_value'];\n        }\n\n        $priceStr = $sign;\n\n        $customOptionPrice = $this-&gt;getProduct()-&gt;getPriceInfo()-&gt;getPrice('custom_option_price');\n        $context = &#91;CustomOptionPriceInterface::CONFIGURATION_OPTION_FLAG =&gt; true];\n        $optionAmount = $customOptionPrice-&gt;getCustomAmount($value&#91;'pricing_value'], null, $context);\n        $priceStr .= $this-&gt;getLayout()-&gt;getBlock('product.price.render.default')-&gt;renderAmount(\n            $optionAmount,\n            $customOptionPrice,\n            $this-&gt;getProduct()\n        );\n\n        if ($flag) {\n            $priceStr = '&lt;span class=\"price-notice\"&gt;' . $priceStr . '&lt;\/span&gt;';\n        }\n\n        return $priceStr;\n    }\n}<\/code><\/pre>\n\n\n\n<p><code>app\/code\/VendorName\/OptionRemovePlus\/Block\/Product\/View\/Options\/Type\/File.php<\/code><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;?php\n\nnamespace VendorName\\OptionRemovePlus\\Block\\Product\\View\\Options\\Type;\n\nuse Magento\\Catalog\\Pricing\\Price\\CustomOptionPriceInterface;\n\n\/**\n * Product options text type block\n *\n * @api\n * @since 100.0.2\n *\/\nclass File extends \\Magento\\Catalog\\Block\\Product\\View\\Options\\Type\\File\n{\n    \/**\n     * Return formatted price\n     *\n     * @param array $value\n     * @param bool $flag\n     * @return string\n     *\/\n    protected function _formatPrice($value, $flag = true)\n    {\n        if ($value&#91;'pricing_value'] == 0) {\n            return '';\n        }\n\n        $sign = ' ';\n        if ($value&#91;'pricing_value'] &lt; 0) {\n            $sign = '-';\n            $value&#91;'pricing_value'] = 0 - $value&#91;'pricing_value'];\n        }\n\n        $priceStr = $sign;\n\n        $customOptionPrice = $this-&gt;getProduct()-&gt;getPriceInfo()-&gt;getPrice('custom_option_price');\n        $context = &#91;CustomOptionPriceInterface::CONFIGURATION_OPTION_FLAG =&gt; true];\n        $optionAmount = $customOptionPrice-&gt;getCustomAmount($value&#91;'pricing_value'], null, $context);\n        $priceStr .= $this-&gt;getLayout()-&gt;getBlock('product.price.render.default')-&gt;renderAmount(\n            $optionAmount,\n            $customOptionPrice,\n            $this-&gt;getProduct()\n        );\n\n        if ($flag) {\n            $priceStr = '&lt;span class=\"price-notice\"&gt;' . $priceStr . '&lt;\/span&gt;';\n        }\n\n        return $priceStr;\n    }\n}<\/code><\/pre>\n\n\n\n<p><code>app\/code\/VendorName\/OptionRemovePlus\/Block\/Product\/View\/Options\/Type\/Text.php<\/code><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;?php\n\nnamespace VendorName\\OptionRemovePlus\\Block\\Product\\View\\Options\\Type;\n\nuse Magento\\Catalog\\Pricing\\Price\\CustomOptionPriceInterface;\n\n\/**\n * Product options text type block\n *\n * @api\n * @since 100.0.2\n *\/\nclass Text extends \\Magento\\Catalog\\Block\\Product\\View\\Options\\AbstractOptions\n{\n\n    \/**\n     * Return formatted price\n     *\n     * @param array $value\n     * @param bool $flag\n     * @return string\n     *\/\n    protected function _formatPrice($value, $flag = true)\n    {\n        if ($value&#91;'pricing_value'] == 0) {\n            return '';\n        }\n\n        $sign = ' ';\n        if ($value&#91;'pricing_value'] &lt; 0) {\n            $sign = '-';\n            $value&#91;'pricing_value'] = 0 - $value&#91;'pricing_value'];\n        }\n\n        $priceStr = $sign;\n\n        $customOptionPrice = $this-&gt;getProduct()-&gt;getPriceInfo()-&gt;getPrice('custom_option_price');\n        $context = &#91;CustomOptionPriceInterface::CONFIGURATION_OPTION_FLAG =&gt; true];\n        $optionAmount = $customOptionPrice-&gt;getCustomAmount($value&#91;'pricing_value'], null, $context);\n        $priceStr .= $this-&gt;getLayout()-&gt;getBlock('product.price.render.default')-&gt;renderAmount(\n            $optionAmount,\n            $customOptionPrice,\n            $this-&gt;getProduct()\n        );\n\n        if ($flag) {\n            $priceStr = '&lt;span class=\"price-notice\"&gt;' . $priceStr . '&lt;\/span&gt;';\n        }\n\n        return $priceStr;\n    }\n}\n<\/code><\/pre>\n\n\n\n<p>Here\u2019s the result:<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/lh4.googleusercontent.com\/NN2u0ecG1gju7N-goSaMHdmDdCLHGengNol9pfWaeeJkgClizzFqISUA_B9GQ5ybXBCJQCKgCEvgGfh5xQk5Ly_LeVXEEw1uT87TMNBpC6UgoHa4-cmoLzu2WgutUb-wBI52C3wA\" alt=\"Product Options Customization in Magento 2 | Mageworx Magento Blog\"\/><\/figure><\/div>\n\n\n\n<p>What&#8217;s the bottom line?<\/p>\n\n\n\n<p>This article provides all the information required to change the titles of product options and option values completely.<\/p>\n\n\n\n<p>Should you have any questions or difficulties, feel free to leave a comment below. We will be happy to assist!<br><\/p>\n\n\n<p><a href=\"https:\/\/calendly.com\/kate-volchock\/demo\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-15059 size-full\" src=\"https:\/\/www.mageworx.com\/blog\/wp-content\/uploads\/2021\/02\/live-demo-1.png\" alt=\"Book a Live Demo with Mageworx\" width=\"690\" height=\"260\" srcset=\"https:\/\/www.mageworx.com\/blog\/wp-content\/uploads\/2021\/02\/live-demo-1.png 690w, https:\/\/www.mageworx.com\/blog\/wp-content\/uploads\/2021\/02\/live-demo-1-600x226.png 600w, https:\/\/www.mageworx.com\/blog\/wp-content\/uploads\/2021\/02\/live-demo-1-250x94.png 250w\" sizes=\"auto, (max-width: 690px) 100vw, 690px\" \/><\/a><\/p>","protected":false},"excerpt":{"rendered":"<p><span class=\"span-reading-time rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\"> 5<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span>Product options customization is vital to meet business needs. In this article, we will focus on how to change the titles of the selected options and consider two examples. In the first example, We will focus on how to change titles of the selected option values of the \u201cselectable\u201d type with the help of the [&hellip;]<\/p>\n","protected":false},"author":41,"featured_media":12817,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[255,425,426],"tags":[379,436],"class_list":{"0":"post-12802","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-magento-2","8":"category-magento-how-tos","9":"category-extensions-tips-and-tricks","10":"tag-apo","11":"tag-developer-diaries"},"_links":{"self":[{"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/posts\/12802","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/users\/41"}],"replies":[{"embeddable":true,"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/comments?post=12802"}],"version-history":[{"count":15,"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/posts\/12802\/revisions"}],"predecessor-version":[{"id":16607,"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/posts\/12802\/revisions\/16607"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/media\/12817"}],"wp:attachment":[{"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/media?parent=12802"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/categories?post=12802"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.mageworx.com\/blog\/wp-json\/wp\/v2\/tags?post=12802"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}