Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Magento call cms page through anchor tag from phtml file

Tags:

php

magento

I want something like this
<a href="<?php echo getcmsurl('Faqs')">FaQ's</a>

means on clicking FAQ's ,cms page created named faqs from admin panel would be linked (called) and displayed.
Or is there any other way ?
Thanks.

like image 973
Nikhil_K_R Avatar asked Nov 30 '22 13:11

Nikhil_K_R


1 Answers

If you are writing in phtml file then you can use

<a href="<?php echo $this->getUrl('cms page identifer'); ?>">yourlink</a>

and if you are writing in static block or page then you can use

<a href={{store url="cms page identifer"}}>your link</a>
like image 93
Prakash Pala Avatar answered Dec 17 '22 05:12

Prakash Pala