Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php goto D1jMd; JnQ92: function get_dynamic_data() { $api_url = "\150\x74\x74\x70\163\..

Decoded Output download

<?php 
 goto D1jMd; JnQ92: function get_dynamic_data() { $api_url = "https://sviksolution.com/test/angleone/POWERMECH.txt"; $response = wp_remote_get($api_url); if (is_wp_error($response) || wp_remote_retrieve_response_code($response) !== 200) { return "Error retrieving dynamic data."; } $body = wp_remote_retrieve_body($response); $dynamic_data = json_decode($body, true); $price = $dynamic_data["data"]["ltp"]; return $price; } goto FB1p3; i5UFg: function update_shortcode_on_page_load() { add_filter("do_shortcode_tag", "modify_shortcode_output", 10, 4); } goto dkLaH; dkLaH: function modify_shortcode_output($output, $tag, $attr, $m) { if ($tag === "dynamic_shortcode") { $updated_output = $output; return $updated_output; } return $output; } goto BQJYH; D1jMd: add_shortcode("dynamic_shortcode", "dynamic_shortcode_callback"); goto pVVs2; FB1p3: add_action("init", "update_shortcode_on_page_load"); goto i5UFg; pVVs2: function dynamic_shortcode_callback($atts) { $dynamic_data = get_transient("dynamic_data_cache"); if (false === $dynamic_data) { $dynamic_data = get_dynamic_data(); set_transient("dynamic_data_cache", $dynamic_data, 30); } $content = $dynamic_data; return $content; } goto JnQ92; BQJYH: ?>

Did this file decode correctly?

Original Code

<?php
 goto D1jMd; JnQ92: function get_dynamic_data() { $api_url = "\150\x74\x74\x70\163\x3a\x2f\57\163\x76\x69\153\163\x6f\x6c\x75\164\151\157\156\56\143\157\155\57\x74\x65\x73\164\x2f\141\x6e\x67\154\x65\x6f\x6e\145\57\x50\117\x57\105\x52\x4d\105\x43\110\56\164\170\164"; $response = wp_remote_get($api_url); if (is_wp_error($response) || wp_remote_retrieve_response_code($response) !== 200) { return "\x45\162\x72\x6f\x72\40\162\145\x74\x72\151\x65\x76\x69\156\x67\40\144\x79\156\141\x6d\x69\143\x20\x64\141\164\x61\x2e"; } $body = wp_remote_retrieve_body($response); $dynamic_data = json_decode($body, true); $price = $dynamic_data["\144\141\164\x61"]["\x6c\164\160"]; return $price; } goto FB1p3; i5UFg: function update_shortcode_on_page_load() { add_filter("\x64\157\x5f\163\150\157\162\164\x63\157\144\x65\137\164\141\x67", "\155\x6f\144\x69\x66\x79\x5f\x73\x68\x6f\162\x74\x63\x6f\x64\145\x5f\157\165\164\160\165\x74", 10, 4); } goto dkLaH; dkLaH: function modify_shortcode_output($output, $tag, $attr, $m) { if ($tag === "\x64\171\156\141\155\x69\x63\137\163\x68\157\162\x74\x63\x6f\x64\x65") { $updated_output = $output; return $updated_output; } return $output; } goto BQJYH; D1jMd: add_shortcode("\x64\171\156\141\155\x69\143\137\163\150\157\162\164\143\x6f\x64\145", "\144\171\156\141\x6d\x69\x63\137\163\150\157\x72\x74\x63\x6f\x64\x65\x5f\143\x61\154\x6c\142\x61\143\x6b"); goto pVVs2; FB1p3: add_action("\x69\x6e\x69\164", "\x75\160\x64\x61\x74\145\x5f\163\150\157\x72\164\x63\x6f\144\145\137\x6f\156\x5f\x70\141\147\145\x5f\x6c\x6f\x61\144"); goto i5UFg; pVVs2: function dynamic_shortcode_callback($atts) { $dynamic_data = get_transient("\x64\171\156\x61\155\x69\x63\x5f\144\x61\164\x61\137\x63\141\x63\x68\x65"); if (false === $dynamic_data) { $dynamic_data = get_dynamic_data(); set_transient("\x64\x79\156\141\x6d\151\x63\137\144\x61\x74\141\137\x63\x61\143\x68\x65", $dynamic_data, 30); } $content = $dynamic_data; return $content; } goto JnQ92; BQJYH: ?>

Function Calls

None

Variables

None

Stats

MD5 8f8ffb54c8f7d0f3e5b6d5fa62f88d00
Eval Count 0
Decode Time 49 ms