How do I get the product updated timestamp? Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern) Announcing the arrival of Valued Associate #679: Cesar Manara Unicorn Meta Zoo #1: Why another podcast?How do I get all of the attribute name of a specific product using the product id or sku?How do I get just the product additional information in the view.phtml template?get the product instance from catalog_product_attribute_update_after eventMagento 2: How can I get all product attributes and get the value (Yes/No)Most Viewed Product not updatedHow to get product QTY on product view page?Get the item updated in cartMagento 2 Add new field to Magento_User admin formSet custom creation timestamp or modify creation timestamp for productHow to get the db updated at timestamp value form custom table in magento 2?

Can gravitational waves pass through a black hole?

Putting Ant-Man on house arrest

Why are two-digit numbers in Jonathan Swift's "Gulliver's Travels" (1726) written in "German style"?

Unix AIX passing variable and arguments to expect and spawn

Is it OK if I do not take the receipt in Germany?

Can a Wizard take the Magic Initiate feat and select spells from the Wizard list?

Married in secret, can marital status in passport be changed at a later date?

Has a Nobel Peace laureate ever been accused of war crimes?

Marquee sign letters

Are there any AGPL-style licences that require source code modifications to be public?

Does using the Inspiration rules for character defects encourage My Guy Syndrome?

When does Bran Stark remember Jamie pushing him?

What documents does someone with a long-term visa need to travel to another Schengen country?

Where is Bhagavad Gita referred to as Hari Gita?

How to create a command for the "strange m" symbol in latex?

Is Vivien of the Wilds + Wilderness Reclamation a competitive combo?

Determine the generator of an ideal of ring of integers

Converting a text document with special format to Pandas DataFrame

Why did Israel vote against lifting the American embargo on Cuba?

Lights are flickering on and off after accidentally bumping into light switch

How to charge percentage of transaction cost?

What could prevent concentrated local exploration?

Why not use the yoke to control yaw, as well as pitch and roll?

Can the van der Waals coefficients be negative in the van der Waals equation for real gases?



How do I get the product updated timestamp?



Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern)
Announcing the arrival of Valued Associate #679: Cesar Manara
Unicorn Meta Zoo #1: Why another podcast?How do I get all of the attribute name of a specific product using the product id or sku?How do I get just the product additional information in the view.phtml template?get the product instance from catalog_product_attribute_update_after eventMagento 2: How can I get all product attributes and get the value (Yes/No)Most Viewed Product not updatedHow to get product QTY on product view page?Get the item updated in cartMagento 2 Add new field to Magento_User admin formSet custom creation timestamp or modify creation timestamp for productHow to get the db updated at timestamp value form custom table in magento 2?



.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








0















I am trying to display the data and time for the last time the product was updated.



<?php

$product = $block->getProduct();

?>

<h1><?php echo $product->getData('spec_sheet');
?></h1>

<span><?php echo $product->getUpdated_At();?></span>


I am not getting any errors, but it also isn't displaying anything.



Edit:
Moved it to a different template



<?php
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/

// @codingStandardsIgnoreFile

/**
* Product additional attributes template
*
* @var $block MagentoCatalogBlockProductViewAttributes
*/
?>
<?php
$_helper = $this->helper('MagentoCatalogHelperOutput');
$_product = $block->getProduct();
?>
<?php if ($_additional = $block->getAdditionalData()): ?>
<div class="additional-attributes-wrapper table-wrapper">
<table class="data table additional-attributes" id="product-
attribute-specs-table">
<caption class="table-caption"><?= /* @escapeNotVerified */ __('More Information') ?></caption>
<tbody>
<?php foreach ($_additional as $_data): ?>
<tr>
<th class="col label" scope="row"><?= $block-
>escapeHtml(__($_data['label'])) ?></th>
<td class="col data" data-th="<?= $block-
>escapeHtml(__($_data['label'])) ?>"><?= /* @escapeNotVerified */
$_helper->productAttribute($_product, $_data['value'], $_data['code']) ?></td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<?php endif;?>
<div class="spectab"><?php echo $_product-
>getData('specification_tab'); ?></div>
<div><?php echo $product->getUpdated_At(); ?></div>


Now I get-
Notice: Undefined variable: product



I changed the last line to



<div><?php echo $_product->getUpdated_At(); ?></div>


And the error clears but nothing displays.










share|improve this question






























    0















    I am trying to display the data and time for the last time the product was updated.



    <?php

    $product = $block->getProduct();

    ?>

    <h1><?php echo $product->getData('spec_sheet');
    ?></h1>

    <span><?php echo $product->getUpdated_At();?></span>


    I am not getting any errors, but it also isn't displaying anything.



    Edit:
    Moved it to a different template



    <?php
    /**
    * Copyright © Magento, Inc. All rights reserved.
    * See COPYING.txt for license details.
    */

    // @codingStandardsIgnoreFile

    /**
    * Product additional attributes template
    *
    * @var $block MagentoCatalogBlockProductViewAttributes
    */
    ?>
    <?php
    $_helper = $this->helper('MagentoCatalogHelperOutput');
    $_product = $block->getProduct();
    ?>
    <?php if ($_additional = $block->getAdditionalData()): ?>
    <div class="additional-attributes-wrapper table-wrapper">
    <table class="data table additional-attributes" id="product-
    attribute-specs-table">
    <caption class="table-caption"><?= /* @escapeNotVerified */ __('More Information') ?></caption>
    <tbody>
    <?php foreach ($_additional as $_data): ?>
    <tr>
    <th class="col label" scope="row"><?= $block-
    >escapeHtml(__($_data['label'])) ?></th>
    <td class="col data" data-th="<?= $block-
    >escapeHtml(__($_data['label'])) ?>"><?= /* @escapeNotVerified */
    $_helper->productAttribute($_product, $_data['value'], $_data['code']) ?></td>
    </tr>
    <?php endforeach; ?>
    </tbody>
    </table>
    </div>
    <?php endif;?>
    <div class="spectab"><?php echo $_product-
    >getData('specification_tab'); ?></div>
    <div><?php echo $product->getUpdated_At(); ?></div>


    Now I get-
    Notice: Undefined variable: product



    I changed the last line to



    <div><?php echo $_product->getUpdated_At(); ?></div>


    And the error clears but nothing displays.










    share|improve this question


























      0












      0








      0








      I am trying to display the data and time for the last time the product was updated.



      <?php

      $product = $block->getProduct();

      ?>

      <h1><?php echo $product->getData('spec_sheet');
      ?></h1>

      <span><?php echo $product->getUpdated_At();?></span>


      I am not getting any errors, but it also isn't displaying anything.



      Edit:
      Moved it to a different template



      <?php
      /**
      * Copyright © Magento, Inc. All rights reserved.
      * See COPYING.txt for license details.
      */

      // @codingStandardsIgnoreFile

      /**
      * Product additional attributes template
      *
      * @var $block MagentoCatalogBlockProductViewAttributes
      */
      ?>
      <?php
      $_helper = $this->helper('MagentoCatalogHelperOutput');
      $_product = $block->getProduct();
      ?>
      <?php if ($_additional = $block->getAdditionalData()): ?>
      <div class="additional-attributes-wrapper table-wrapper">
      <table class="data table additional-attributes" id="product-
      attribute-specs-table">
      <caption class="table-caption"><?= /* @escapeNotVerified */ __('More Information') ?></caption>
      <tbody>
      <?php foreach ($_additional as $_data): ?>
      <tr>
      <th class="col label" scope="row"><?= $block-
      >escapeHtml(__($_data['label'])) ?></th>
      <td class="col data" data-th="<?= $block-
      >escapeHtml(__($_data['label'])) ?>"><?= /* @escapeNotVerified */
      $_helper->productAttribute($_product, $_data['value'], $_data['code']) ?></td>
      </tr>
      <?php endforeach; ?>
      </tbody>
      </table>
      </div>
      <?php endif;?>
      <div class="spectab"><?php echo $_product-
      >getData('specification_tab'); ?></div>
      <div><?php echo $product->getUpdated_At(); ?></div>


      Now I get-
      Notice: Undefined variable: product



      I changed the last line to



      <div><?php echo $_product->getUpdated_At(); ?></div>


      And the error clears but nothing displays.










      share|improve this question
















      I am trying to display the data and time for the last time the product was updated.



      <?php

      $product = $block->getProduct();

      ?>

      <h1><?php echo $product->getData('spec_sheet');
      ?></h1>

      <span><?php echo $product->getUpdated_At();?></span>


      I am not getting any errors, but it also isn't displaying anything.



      Edit:
      Moved it to a different template



      <?php
      /**
      * Copyright © Magento, Inc. All rights reserved.
      * See COPYING.txt for license details.
      */

      // @codingStandardsIgnoreFile

      /**
      * Product additional attributes template
      *
      * @var $block MagentoCatalogBlockProductViewAttributes
      */
      ?>
      <?php
      $_helper = $this->helper('MagentoCatalogHelperOutput');
      $_product = $block->getProduct();
      ?>
      <?php if ($_additional = $block->getAdditionalData()): ?>
      <div class="additional-attributes-wrapper table-wrapper">
      <table class="data table additional-attributes" id="product-
      attribute-specs-table">
      <caption class="table-caption"><?= /* @escapeNotVerified */ __('More Information') ?></caption>
      <tbody>
      <?php foreach ($_additional as $_data): ?>
      <tr>
      <th class="col label" scope="row"><?= $block-
      >escapeHtml(__($_data['label'])) ?></th>
      <td class="col data" data-th="<?= $block-
      >escapeHtml(__($_data['label'])) ?>"><?= /* @escapeNotVerified */
      $_helper->productAttribute($_product, $_data['value'], $_data['code']) ?></td>
      </tr>
      <?php endforeach; ?>
      </tbody>
      </table>
      </div>
      <?php endif;?>
      <div class="spectab"><?php echo $_product-
      >getData('specification_tab'); ?></div>
      <div><?php echo $product->getUpdated_At(); ?></div>


      Now I get-
      Notice: Undefined variable: product



      I changed the last line to



      <div><?php echo $_product->getUpdated_At(); ?></div>


      And the error clears but nothing displays.







      magento2 product product-attribute






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited 2 hours ago









      magefms

      2,8152528




      2,8152528










      asked 3 hours ago









      Tyler JensenTyler Jensen

      86111




      86111




















          2 Answers
          2






          active

          oldest

          votes


















          0














          Try <?php echo $product->getUpdatedAt(); ?>






          share|improve this answer























          • Same issue. That is the way I tried it first. Just to make sure I tried it that way again and still getting nothing. I did flush cache after each change.

            – Tyler Jensen
            3 hours ago


















          0














          At the end of the last template I used this instead-



          <div><?php echo $_product->getData('updated_at'); ?></div> 


          And it works!






          share|improve this answer

























            Your Answer








            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "479"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: false,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            imageUploader:
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            ,
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













            draft saved

            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f271000%2fhow-do-i-get-the-product-updated-timestamp%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            Try <?php echo $product->getUpdatedAt(); ?>






            share|improve this answer























            • Same issue. That is the way I tried it first. Just to make sure I tried it that way again and still getting nothing. I did flush cache after each change.

              – Tyler Jensen
              3 hours ago















            0














            Try <?php echo $product->getUpdatedAt(); ?>






            share|improve this answer























            • Same issue. That is the way I tried it first. Just to make sure I tried it that way again and still getting nothing. I did flush cache after each change.

              – Tyler Jensen
              3 hours ago













            0












            0








            0







            Try <?php echo $product->getUpdatedAt(); ?>






            share|improve this answer













            Try <?php echo $product->getUpdatedAt(); ?>







            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered 3 hours ago









            ne0nlightne0nlight

            41219




            41219












            • Same issue. That is the way I tried it first. Just to make sure I tried it that way again and still getting nothing. I did flush cache after each change.

              – Tyler Jensen
              3 hours ago

















            • Same issue. That is the way I tried it first. Just to make sure I tried it that way again and still getting nothing. I did flush cache after each change.

              – Tyler Jensen
              3 hours ago
















            Same issue. That is the way I tried it first. Just to make sure I tried it that way again and still getting nothing. I did flush cache after each change.

            – Tyler Jensen
            3 hours ago





            Same issue. That is the way I tried it first. Just to make sure I tried it that way again and still getting nothing. I did flush cache after each change.

            – Tyler Jensen
            3 hours ago













            0














            At the end of the last template I used this instead-



            <div><?php echo $_product->getData('updated_at'); ?></div> 


            And it works!






            share|improve this answer





























              0














              At the end of the last template I used this instead-



              <div><?php echo $_product->getData('updated_at'); ?></div> 


              And it works!






              share|improve this answer



























                0












                0








                0







                At the end of the last template I used this instead-



                <div><?php echo $_product->getData('updated_at'); ?></div> 


                And it works!






                share|improve this answer















                At the end of the last template I used this instead-



                <div><?php echo $_product->getData('updated_at'); ?></div> 


                And it works!







                share|improve this answer














                share|improve this answer



                share|improve this answer








                edited 2 hours ago









                magefms

                2,8152528




                2,8152528










                answered 3 hours ago









                Tyler JensenTyler Jensen

                86111




                86111



























                    draft saved

                    draft discarded
















































                    Thanks for contributing an answer to Magento Stack Exchange!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid


                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.

                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f271000%2fhow-do-i-get-the-product-updated-timestamp%23new-answer', 'question_page');

                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Magento 2 - Add success message with knockout Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern) Announcing the arrival of Valued Associate #679: Cesar Manara Unicorn Meta Zoo #1: Why another podcast?Success / Error message on ajax request$.widget is not a function when loading a homepage after add custom jQuery on custom themeHow can bind jQuery to current document in Magento 2 When template load by ajaxRedirect page using plugin in Magento 2Magento 2 - Update quantity and totals of cart page without page reload?Magento 2: Quote data not loaded on knockout checkoutMagento 2 : I need to change add to cart success message after adding product into cart through pluginMagento 2.2.5 How to add additional products to cart from new checkout step?Magento 2 Add error/success message with knockoutCan't validate Post Code on checkout page

                    Fil:Tokke komm.svg

                    Where did Arya get these scars? Unicorn Meta Zoo #1: Why another podcast? Announcing the arrival of Valued Associate #679: Cesar Manara Favourite questions and answers from the 1st quarter of 2019Why did Arya refuse to end it?Has the pronunciation of Arya Stark's name changed?Has Arya forgiven people?Why did Arya Stark lose her vision?Why can Arya still use the faces?Has the Narrow Sea become narrower?Does Arya Stark know how to make poisons outside of the House of Black and White?Why did Nymeria leave Arya?Why did Arya not kill the Lannister soldiers she encountered in the Riverlands?What is the current canonical age of Sansa, Bran and Arya Stark?