Posts: 19
Threads: 7
Joined: Feb 2013
I'm using a custom theme I made years ago. Seems GS no longer supports this
PHP Code:
<?php get_page_meta_keywords(); ?>
in the meta description. My pages have no meta description, despite having filled in a meta description from within Admin (page options).
I'm running version 3.3.10 but will upgrade to 3.3.13 shortly.
Posts: 3,491
Threads: 106
Joined: Mar 2010
That template tag is for meta keywords. For the meta description you should use:
Code:
<?php get_page_meta_desc(); ?>
Posts: 19
Threads: 7
Joined: Feb 2013
2017-12-02, 13:10:32
(This post was last modified: 2017-12-02, 13:10:53 by j*z.)
(2017-12-01, 22:01:12)Carlos Wrote: That template tag is for meta keywords. For the meta description you should use:
Code:
<?php get_page_meta_desc(); ?>
Thank you Carlos! That's working for me.
Posts: 109
Threads: 7
Joined: Nov 2012
(2017-12-01, 12:27:27)j*z Wrote: I'm using a custom theme I made years ago. Seems GS no longer supports this
PHP Code:
<?php get_page_meta_keywords(); ?>
in the meta description. My pages have no meta description, despite having filled in a meta description from within Admin (page options).
I'm running version 3.3.10 but will upgrade to 3.3.13 shortly.
If you need the meta description of ANY page (not only the current) you can use
PHP Code:
<?php getPageField('ANY_PAGE_SLUG','metad'); ?>
Alex
Posts: 19
Threads: 7
Joined: Feb 2013
2017-12-22, 03:19:55
(2017-12-06, 20:00:35)Alexander_ Wrote: (2017-12-01, 12:27:27)j*z Wrote: I'm using a custom theme I made years ago. Seems GS no longer supports this
PHP Code:
<?php get_page_meta_keywords(); ?>
in the meta description. My pages have no meta description, despite having filled in a meta description from within Admin (page options).
I'm running version 3.3.10 but will upgrade to 3.3.13 shortly.
If you need the meta description of ANY page (not only the current) you can use
PHP Code:
<?php getPageField('ANY_PAGE_SLUG','metad'); ?>
Alex