{"id":536,"date":"2022-05-14T18:23:50","date_gmt":"2022-05-14T13:53:50","guid":{"rendered":"https:\/\/wpdone.ir\/docs\/?post_type=help&#038;p=536"},"modified":"2022-05-15T00:07:03","modified_gmt":"2022-05-14T19:37:03","slug":"%d8%aa%d8%ba%db%8c%db%8c%d8%b1-%d8%a2%db%8c%da%a9%d9%88%d9%86-%d9%87%d8%a7","status":"publish","type":"help","link":"https:\/\/wpdone.ir\/docs\/help\/%d8%aa%d8%ba%db%8c%db%8c%d8%b1-%d8%a2%db%8c%da%a9%d9%88%d9%86-%d9%87%d8%a7\/","title":{"rendered":"\u062a\u063a\u06cc\u06cc\u0631 \u0622\u06cc\u06a9\u0648\u0646\u200c\u0647\u0627"},"content":{"rendered":"\n<p>\u062a\u0645\u0627\u0645 \u0622\u06cc\u06a9\u0648\u0646 \u0647\u0627\u06cc svg \u0627\u0633\u062a\u0641\u0627\u062f\u0647 \u0634\u062f\u0647 \u062f\u0631 \u0642\u0627\u0644\u0628 \u062a\u0648\u0633\u0637 \u0627\u06cc\u0646 \u0642\u0644\u0627\u0628 \u0642\u0627\u0628\u0644 \u0648\u06cc\u0631\u0627\u06cc\u0634 \u0647\u0633\u062a\u0646\u062f<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">amzshyar_icon<\/h2>\n\n\n\n<p>\u062a\u0645\u0627\u0645\u06cc \u0622\u06cc\u06a9\u0648\u0646\u200c\u0647\u0627 \u0628\u0627 \u06cc\u06a9 \u0646\u0627\u0645 \u06cc\u06a9\u062a\u0627 \u0627\u0632 \u0637\u0631\u06cc\u0642 \u0645\u062a\u063a\u06cc\u0631 <strong>name$<\/strong> \u0642\u0627\u0628\u0644 \u0634\u0646\u0627\u0633\u0627\u06cc\u06cc \u0647\u0633\u062a\u0646\u062f.<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; highlight: [3]; title: ; notranslate\" title=\"\">\nadd_filter( 'amzshyar_icon', function ( $icon, $name ) {\n\n    if( 'cart' == $name ) return '&lt;svg...';\n\n    return $icon;\n}, 10, 2 );\n<\/pre><\/div>\n\n\n<p>\u0627\u06af\u0631 \u0642\u0635\u062f \u062f\u0627\u0631\u06cc\u062f \u0686\u0646\u062f\u06cc\u0646 \u0622\u06cc\u06a9\u0648\u0646 \u0631\u0627 \u062a\u063a\u06cc\u06cc\u0631 \u062f\u0647\u06cc\u062f\u060c \u0628\u0647\u062a\u0631 \u0627\u0633\u062a \u062a\u0645\u0627\u0645\u06cc \u062a\u063a\u06cc\u06cc\u0631\u0647\u0627 \u062f\u0631 \u06cc\u06a9 \u0641\u06cc\u0644\u062a\u0631 \u0627\u0646\u062c\u0627\u0645 \u0634\u0648\u062f \u0628\u0647 \u0627\u06cc\u0646\u0635\u0648\u0631\u062a:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; highlight: [4,5,6]; title: ; notranslate\" title=\"\">\nadd_filter( 'amzshyar_icon', function ( $icon, $name ) {\n    switch ( $name )\n    {\n        case 'cart': return '&lt;svg...'; break;\n        case 'notifications': return '&lt;svg...'; break;\n        case 'search': return '&lt;svg...'; break;\n        \n        default:\n        return $icon;\n    }\n}, 10, 2 );\n<\/pre><\/div>\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">\u0686\u0637\u0648\u0631 \u0646\u0627\u0645 \u0622\u06cc\u06a9\u0648\u0646 \u0647\u0627 \u0631\u0627 \u067e\u06cc\u062f\u0627 \u06a9\u0646\u0645\u061f<\/h2>\n\n\n\n<p>\u0628\u0631\u0627\u06cc \u06cc\u0627\u0641\u062a\u0646 \u0646\u0627\u0645 \u0622\u06cc\u06a9\u0648\u0646\u200c\u0647\u0627 \u0628\u0627\u06cc\u062f \u0627\u0632 <strong>Inspect<\/strong> \u0645\u0631\u0648\u0631\u06af\u0631 \u0627\u0633\u062a\u0641\u0627\u062f\u0647 \u06a9\u0646\u06cc\u062f. \u0628\u0647 \u0627\u06cc\u0646\u0635\u0648\u0631\u062a \u06a9\u0647 \u0631\u0648\u06cc \u0622\u06cc\u06a9\u0648\u0646 \u0645\u0648\u0631\u062f \u0646\u0638\u0631 <strong>\u0631\u0627\u0633\u062a \u06a9\u0644\u06cc\u06a9<\/strong> \u06a9\u0646\u06cc\u062f \u0633\u067e\u0633 \u06af\u0632\u06cc\u0646\u0647 <strong>Inspect<\/strong> \u0631\u0627 \u0628\u0632\u0646\u06cc\u062f. \u062f\u0631 \u0627\u06cc\u0646 \u0645\u0631\u062d\u0644\u0647 \u0645\u0631\u0648\u0631\u06af\u0631 \u0628\u0635\u0648\u0631\u062a \u062e\u0648\u062f\u06a9\u0627\u0631 element \u0622\u06cc\u06a9\u0648\u0646 \u0631\u0627 \u0627\u0646\u062a\u062e\u0627\u0628 \u0645\u06cc\u06a9\u0646\u062f.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"920\" height=\"89\" src=\"https:\/\/wpdone.ir\/docs\/wp-content\/uploads\/2022\/05\/image-51.png\" alt=\"\" class=\"wp-image-538\" srcset=\"https:\/\/wpdone.ir\/docs\/wp-content\/uploads\/2022\/05\/image-51.png 920w, https:\/\/wpdone.ir\/docs\/wp-content\/uploads\/2022\/05\/image-51-300x29.png 300w, https:\/\/wpdone.ir\/docs\/wp-content\/uploads\/2022\/05\/image-51-768x74.png 768w, https:\/\/wpdone.ir\/docs\/wp-content\/uploads\/2022\/05\/image-51-600x58.png 600w\" sizes=\"auto, (max-width: 920px) 100vw, 920px\" \/><\/figure><\/div>\n\n\n\n<p>\u0646\u0627\u0645 \u0647\u0631 \u0622\u06cc\u06a9\u0648\u0646 \u062f\u0631\u0648\u0646 \u0645\u0642\u062f\u0627\u0631 \u0648\u06cc\u0698\u06af\u06cc <strong>data-name<\/strong> \u0642\u0631\u0627\u0631 \u062f\u0627\u0631\u062f. \u062a\u0645\u0627\u0645 \u0622\u06cc\u06a9\u0648\u0646\u200c\u0647\u0627\u06cc svg \u0627\u06cc\u0646 attribute \u0631\u0627 \u062f\u0627\u0631\u0627 \u0647\u0633\u062a\u0646\u062f. \u0628\u0627 \u067e\u06cc\u062f\u0627 \u06a9\u0631\u062f\u0646 \u0627\u06cc\u0646 \u0646\u0627\u0645 \u0648 \u0627\u0633\u062a\u0641\u0627\u062f\u0647 \u0622\u0646 \u062f\u0631 \u0641\u06cc\u0644\u062a\u0631 \u0645\u06cc\u062a\u0648\u0627\u0646\u06cc\u062f return \u0627\u062e\u062a\u0635\u0627\u0635\u06cc \u062e\u0648\u062f \u0631\u0627 \u062f\u0627\u0634\u062a\u0647 \u0628\u0627\u0634\u06cc\u062f.<\/p>\n\n\n\n<p><strong>\u0646\u06a9\u062a\u0647:<\/strong> \u0627\u06af\u0631 \u0642\u0635\u062f \u062f\u0627\u0631\u06cc\u062f \u0628\u062c\u0627\u06cc \u0627\u0633\u062a\u0641\u0627\u062f\u0647 \u0627\u0632 svg \u0627\u0632 \u062a\u06af img \u0627\u0633\u062a\u0641\u0627\u062f\u0647 \u06a9\u0646\u06cc\u062f \u062d\u062a\u0645\u0627 \u062a\u0648\u062c\u0647 \u062f\u0627\u0634\u062a\u0647 \u0628\u0627\u0634\u06cc\u062f \u06a9\u0647 \u0645\u0645\u06a9\u0646 \u0627\u0633\u062a \u062f\u0631 \u0628\u0631\u062e\u06cc \u0627\u0632 \u0642\u0633\u0645\u062a\u200c\u0647\u0627\u06cc \u0642\u0627\u0644\u0628 \u0627\u0633\u062a\u0627\u06cc\u0644 \u0645\u0646\u0627\u0633\u0628\u06cc \u0646\u062f\u0627\u0634\u062a\u0647 \u0628\u0627\u0634\u062f. \u067e\u0633 \u0644\u0627\u0632\u0645 \u0627\u0633\u062a \u062d\u062a\u0645\u0627 \u0627\u0633\u062a\u0627\u06cc\u0644 \u0622\u0646 \u0631\u0627 \u0628\u0635\u0648\u0631\u062a \u0627\u062e\u062a\u0635\u0627\u0635\u06cc \u0627\u0636\u0627\u0641\u0647 \u06a9\u0646\u06cc\u062f.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u062a\u0645\u0627\u0645 \u0622\u06cc\u06a9\u0648\u0646 \u0647\u0627\u06cc svg \u0627\u0633\u062a\u0641\u0627\u062f\u0647 \u0634\u062f\u0647 \u062f\u0631 \u0642\u0627\u0644\u0628 \u062a\u0648\u0633\u0637 \u0627\u06cc\u0646 \u0642\u0644\u0627\u0628 \u0642\u0627\u0628\u0644 \u0648\u06cc\u0631\u0627\u06cc\u0634 \u0647\u0633\u062a\u0646\u062f<\/p>\n","protected":false},"template":"","help-category":[26],"class_list":["post-536","help","type-help","status-publish","hentry","help-category-hooks"],"_links":{"self":[{"href":"https:\/\/wpdone.ir\/docs\/wp-json\/wp\/v2\/help\/536","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpdone.ir\/docs\/wp-json\/wp\/v2\/help"}],"about":[{"href":"https:\/\/wpdone.ir\/docs\/wp-json\/wp\/v2\/types\/help"}],"wp:attachment":[{"href":"https:\/\/wpdone.ir\/docs\/wp-json\/wp\/v2\/media?parent=536"}],"wp:term":[{"taxonomy":"help-category","embeddable":true,"href":"https:\/\/wpdone.ir\/docs\/wp-json\/wp\/v2\/help-category?post=536"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}