Replacing title in listing with keywords
This topic contains 6 replies, has 3 voices, and was last updated by purpleedge 10 years, 3 months ago.
We have moved to a support ticketing system and our forums are now closed.
Open Support Ticket-
AuthorPosts
-
September 9, 2014 at 8:20 am #14734
Hi Paolo,
I’ve always been told that the page “title” is the most important SEO property and was interested by your post to replace the default title…
In your child theme functions.php You could remove the default title action create the new function as needed and add a new action using the modified function.
Example:
remove_action( 'geodir_listings_page_title', geodir_action_listings_title',10); function my_geodir_action_listings_title(){ //new function code here } add_action( 'geodir_listings_page_title', my_geodir_action_listings_title',10);
Let me know if this is enough to put you in the right direction.
Thx
If I create a custom field “listing_keywords” for a custom post type, e.g. gd_place, how do I refer to that value in the above code to place it in the title field?
Thanks.
September 9, 2014 at 11:47 am #14783In many cases, the best or at least a very strong title is already in place by default.
The Yoast SEO Plugin and some minor code from one of the other SEO threads does a great job of pulling in the location information.
So detail listing page title pulls in the business name, great…and using the above can pull in the city, excellent.
On the Category/subcategory “grid” pages, the title uses the cat/subcat name, great…and using the above can pull in the location detail if segmented by location, or just the cat/subcat name if viewing “everywhere.”
Similar can be done on the keyword tag pages, though whether those pages have value to the search engines or not will vary by site…they may seem mostly redundant and lead to massive site bloat.
One of the great benefits to Yoast’s plugin is that it has a cascading effect and can be written programmatically. With the cascading effect, you can always craft title tags on specific pages, or at a specific category or subcategory level that will override the broader pattern.
I’d be cautious pulling in the keywords as they may appear less polished in the SERPs and may yield a rather disjointed, random signal.
The other important aspect is content on-page. So beyond the titles, adding some unique, content-rich text for the location (GD > MultiLocations) and for the category (CPT settings > CPT Categories > Top Category Description) are critical.
This part of GD is perhaps still a bit weak. As you can see, the places to edit this are scattered a bit about, and you can’t really pull in placeholder parameters.
From an SEO point of view, key elements:
– title tag (~65 characters); every page should have its own, unique title tag
– rich content on the pages that reinforces the title tag with related keyword usage, hopefully 200-300 words (or more), but really varies
– rich keyword usage in h1, h2, and h3 headings
– good interlinking between pages of the site
– clean, relatively short, hyphen-separated, parameter-less keyword URLs (fortunately, WordPress mostly takes care of this for us)Not so key:
– meta descriptions – these are however important as they are often used in the snippet in the search results, so crafting a nice call to action here is good, and Yoast’s plugin again provides for a nice programmatic approach here.
– meta keywords – zero value…none, zilch, nada. Note that what I’m talking about here are the keywords pulled into the head section of the HTML. Generally these are being pulled in from the keyword tags users add which also appear under the photo carousel. On-page they may have value to search engines, it depends, but more to the point, they may be useful to site visitors. In this example, the relatively pointless usage is the actual addition of the meta keywords into the HTML head section.cheers
September 9, 2014 at 1:50 pm #14791Thanks Brian,
I would still like an answer to my question, so that I have a front end means for users to add to the title tag.
September 9, 2014 at 7:00 pm #14817Hi Purpleedge,
I think there is a little confusion. With that code you remove and modify the listing title from the front end template, not the meta title which is in the header of the theme. Is that what you want to do?
Example: if you do that, with this listing you would modify “Crown Fountain” in the front end on top of the picture gallery only.
Depending on the theme used, to modify the meta title, you have to apply a filter to wp_title in your functions.php, or edit the code producing the title directly on your theme’s header.php.
Here there are some good exmaples : http://www.webdevdoor.com/wordpress/custom-wordpress-meta-titles/
Let me know if I this is what you were looking for.
Thx
September 9, 2014 at 11:39 pm #14866Yeah sorry Paolo, I saw “SEO” in the other thread and automatically assumed we were talking about the “title” meta data.
The question still applies, how do I refer, in code, to a custom field value entered from the GD front end add_listing page?
Similar to what this plugin allows from the backend…
https://wordpress.org/plugins/pagemeta/
Maybe I can do that with Yoast Brian, I haven’t used Yoast on a GD install yet because I read there were bugs earlier on?
September 9, 2014 at 11:56 pm #14871To echo any custom field, you would use the regular wordpress way to echo a custom field:
<?php echo get_post_meta($post->ID, 'key', true); ?>
Where key is the custom field name.
Let me know if this is what you are looking for.
Thx
September 10, 2014 at 1:25 am #14875Thanks Paolo, That is what I needed. 🙂
-
AuthorPosts
We have moved to a support ticketing system and our forums are now closed.
Open Support Ticket