cancel
Showing results for 
Search instead for 
Did you mean: 

Get Page Title In PHTML? CE 2.4

Re: Get Page Title In PHTML? CE 2.4

when it comes to calculating the LIC pension plan, all we require is the LIC pension plan calculator that will show and review about the plans, benefits and
the entire detail of the pension plan within minutes.

Re: Get Page Title In PHTML? CE 2.4

I have same problem please any one solve this problem here are the screenshot of problem sarkari yojana

Re: Get Page Title In PHTML? CE 2.4

 

firstly remove the Magento rendering title and in the second XML, created a custom block and assign the template to that custom block. From the new code of block, you just added a template rendering class that will not get any dynamic data. 

 

<block class="Magento\Framework\View\Element\Template" name="page_title" template="Magento_Theme::page_title.phtml"/>
In this case, you can just add a static title, not a dynamic title, by creating a custom block and pass the class of that block to your XML then it will bind with the template and you can easily print the title by writing a function into that block file and in phtml file, you just call that function of block and in return title will be print over that specific div.

If you want to use the same code of title then you should pass the same class in your new block class section which was used in default XML.