In this post I am going to explain how to get CMS page details by id in PrestaShop 1.7.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | // Your CMS Page Id $id_cms = 4; // Language id $id_lang = (int) Configuration::get('PS_LANG_DEFAULT'); // Load CMS Page object $cms = new CMS($id_cms, $id_lang); // Validate CMS Page object if (Validate::isLoadedObject($cms)) { // Get CMS Page Meta Title echo $cms->meta_title; // Get CMS Page Content echo $cms->content; // Get CMS Page Link Rewrite echo $cms->link_rewrite; // Print CMS Page Object echo "<pre>"; print_r($cms); echo "</pre>"; } |
Write an article about ecommerce that help people to grow their ecommerce business. You’ll find best ecommerce guide, news, tips & more!
Leave a Reply