{"id":15044830,"date":"2021-11-07T17:57:08","date_gmt":"2021-11-07T17:57:08","guid":{"rendered":"https:\/\/wordpress.org\/support\/?post_type=topic&#038;p=15044830"},"modified":"2021-11-07T18:07:37","modified_gmt":"2021-11-07T18:07:37","slug":"php-options","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/php-options\/","title":{"rendered":"PHP options?"},"content":{"rendered":"<p>Hi, awesome plugin. But I can&#8217;t use my own PHP?<\/p>\n<p>I&#8217;m trying this:<br \/>\n$UserCountry = do_shortcode(&#8220;{ip:countryCode}&#8221;);<br \/>\nif ($UserCountry === &#8220;GB&#8221;){echo &#8220;Hello UK Visitor!&lt;br \/&gt;&#8221;;}<\/p>\n<p>But $UserCountry never seems to be a normal string in that example. It&#8217;s not an array but outputs as &#8220;GB&#8221; in my tests.<\/p>\n<p>Is there any options for coding in PHP and not using shortcodes which could be the issue?<\/p>\n","protected":false},"template":"","class_list":["post-15044830","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/15044830","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":1,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/15044830\/revisions"}],"predecessor-version":[{"id":15044848,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/15044830\/revisions\/15044848"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=15044830"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}