Title: Attribute data-shortcode returnig empty
Last modified: April 29, 2021

---

# Attribute data-shortcode returnig empty

 *  Resolved [Junior Miranda](https://wordpress.org/support/users/jmjunior/)
 * (@jmjunior)
 * [5 years, 1 month ago](https://wordpress.org/support/topic/attribute-data-shortcode-returnig-empty/)
 * Hello folks.
 * For some reason, the data-shortcode attribute is returning empty on Instagram
   embed codes on my transformed pages.
 * Somebody know what could be causing this issue?
 * Thanks in advance.
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fattribute-data-shortcode-returnig-empty%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Plugin Support [Milind More](https://wordpress.org/support/users/milindmore22/)
 * (@milindmore22)
 * [5 years, 1 month ago](https://wordpress.org/support/topic/attribute-data-shortcode-returnig-empty/#post-14380406)
 * Hello [@jmjunior](https://wordpress.org/support/users/jmjunior/)
 * Can you please let us know, how you are adding embeds? also please send us your
   site health information using [this](https://docs.google.com/forms/d/1JTQmphDlk9YgHpDoFRbHXpkDqv8-QmzTT7MDR4AstyQ/viewform)
   form.
 * Additionally, can you please check by disabling HTML modification/optimizations?
 *  Thread Starter [Junior Miranda](https://wordpress.org/support/users/jmjunior/)
 * (@jmjunior)
 * [5 years, 1 month ago](https://wordpress.org/support/topic/attribute-data-shortcode-returnig-empty/#post-14381736)
 * Hello [@milindmore22](https://wordpress.org/support/users/milindmore22/)
 * Thank you for your reply.
 * I’m having trouble to reply trought the indicated form because it says that my
   answer is too big, due to my PHP error log and Site Health Info.
 * The embeds are being added in the common way, pasting the Instagram post url 
   direct in the post editor with help of the Embed Plus plugin.
 * After a few test, I found that the problem is related to the function **create_amp_instagram_and_replace_node**
   that is returning the **node_args** array **data-shortcode** value empty.
 * Do you suspect what could be causing this issue?
    -  This reply was modified 5 years, 1 month ago by [Junior Miranda](https://wordpress.org/support/users/jmjunior/).
    -  This reply was modified 5 years, 1 month ago by [Junior Miranda](https://wordpress.org/support/users/jmjunior/).
    -  This reply was modified 5 years, 1 month ago by [Junior Miranda](https://wordpress.org/support/users/jmjunior/).
    -  This reply was modified 5 years, 1 month ago by [Junior Miranda](https://wordpress.org/support/users/jmjunior/).
 *  Plugin Support [Milind More](https://wordpress.org/support/users/milindmore22/)
 * (@milindmore22)
 * [5 years, 1 month ago](https://wordpress.org/support/topic/attribute-data-shortcode-returnig-empty/#post-14384288)
 * Hello [@jmjunior](https://wordpress.org/support/users/jmjunior/)
 * I am not able to reproduce the issues at my end, can you please send us site 
   health info and PHP error log just the `create_amp_instagram_and_replace_node`
   error stack ( not full error log) using [this](https://docs.google.com/forms/d/1JTQmphDlk9YgHpDoFRbHXpkDqv8-QmzTT7MDR4AstyQ/viewform)
   form.
 * Also, can you include HTML markup of Instagram embed in additional information
   field ([screenshot](https://prnt.sc/12b2mpo))
 *  Thread Starter [Junior Miranda](https://wordpress.org/support/users/jmjunior/)
 * (@jmjunior)
 * [5 years, 1 month ago](https://wordpress.org/support/topic/attribute-data-shortcode-returnig-empty/#post-14385643)
 * Hello [@milindmore22](https://wordpress.org/support/users/milindmore22/)
 * Thank you for reply.
 * I sent the info trought the indicated form.
 * My `WP_DEBUG` and `WP_DEBUG_LOG` is both setted true, so there is no registry
   in the log relacted to `create_amp_instagram_and_replace_node` function.
 * I believe that problem could be with the `get_instagram_id_from_url` function–
   that is not populating the `%url` variable in my case.
 *  Thread Starter [Junior Miranda](https://wordpress.org/support/users/jmjunior/)
 * (@jmjunior)
 * [5 years, 1 month ago](https://wordpress.org/support/topic/attribute-data-shortcode-returnig-empty/#post-14388498)
 * I gonna close this topic because I got a better approach of the problem. So I
   will create other topic most concise to the issue.
 *  Plugin Author [Weston Ruter](https://wordpress.org/support/users/westonruter/)
 * (@westonruter)
 * [5 years, 1 month ago](https://wordpress.org/support/topic/attribute-data-shortcode-returnig-empty/#post-14388654)
 * Follow up: [https://github.com/ampproject/amp-wp/issues/6169](https://github.com/ampproject/amp-wp/issues/6169)

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Attribute data-shortcode returnig empty’ is closed to new replies.

 * ![](https://ps.w.org/amp/assets/icon.svg?rev=2527602)
 * [AMP](https://wordpress.org/plugins/amp/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/amp/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/amp/)
 * [Active Topics](https://wordpress.org/support/plugin/amp/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/amp/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/amp/reviews/)

 * 6 replies
 * 3 participants
 * Last reply from: [Weston Ruter](https://wordpress.org/support/users/westonruter/)
 * Last activity: [5 years, 1 month ago](https://wordpress.org/support/topic/attribute-data-shortcode-returnig-empty/#post-14388654)
 * Status: resolved