Maybe it would be usefull to let users add keywords with a .txt file. This would really be a time saver.
Best wishes,
Mark
-
MODX Staff
- 2,502 Posts
This would be easy to do with a snippet. Most search engines don’t look at keywords as an indicator of the page content.
Create a snippet with the following:
<?php
//Parameter (your file name with the path to it.)
$file = isset($file) ? $file : '';
//Gets the contents of the keywords file.
$keywords = file_get_contents($file);
//Outputs your keywords.
echo $keywords;
?>
Hope this is what you wanted to do.
All the best,
Jay
Author of zero books. Formerly of many strange things. Pairs well with meats. Conversations are magical experiences. He's dangerous around code but a markup
magician.
Blog ✦
Twitter ✦
LinkedIn ✦
GitHub
-
☆ A M B ☆
- 1,056 Posts
I’ve found the following to work great in most scenarios:
Create a textarea Template Variable (TV) where the DEFAULT VALUE is your chunk (Use @BINDING support for inheritance!)
keywords TV Default Value: @INHERIT{{keywords}}
Add to your Template:
<meta name="keywords" content="[*keywords*]" />
Then, on pages that you do not want to use the default keywords (as defined in your Chunk), simply override by customizing the document’s
keywords TV!
-
MODX Staff
- 2,502 Posts
Yet another example or of many ways of MODx. Personally, as a web marketer I don’t use meta keywords as they are a big waste of time. Some Search engines do use the meta description value and therefore I do use that.
Cheers,
Jay
Author of zero books. Formerly of many strange things. Pairs well with meats. Conversations are magical experiences. He's dangerous around code but a markup
magician.
Blog ✦
Twitter ✦
LinkedIn ✦
GitHub
I use a custom snippet that adds all the meta tags I want and has a list of default keywords to which it adds any that are set in the document (and shuffles them randomly from page to page just for the heck of it). But I agree with Jay that there’s practically no point to adding a keywords meta tag anymore, since every important search engine ignores them. I really only still add it because clients always ask about it eventually (often because someone has told them it’s essential and generously offered to charge them $1500 for it), and it’s easier to say "it’s no longer necessary, but we did it anyway" than "I know your friend told you it was really important, but your friend doesn’t know what s/he’s talking about".
The meta description tag is used by Google and other search engines, however, and is thus very important (make sure that you vary it from page to page).
I too use a chunk that contains all site-related keywords, and a TV for page specific keywords. I join them up in my snippet.
I use a slightly modified version of DynamicDescription and MetaTagsExtra to get all my Meta Data looking nice, without having to worry about it.
Check out the resources if you want more information on those 2 snippets
http://www.modxcms.com/resource-listing.html&tags=meta
They are both indispendible for any website I build.
I could well imagine that they do carry some weight (albeit small). If they weren’t why would Search engines penalise you for spamming the same word lots of times in your keywords? Either way, not only does it keep the client happy, but any plus no matter how small when it comes to gaining a better ranking, is IMO worth the 10 minutes time investment.
Taff
Adrian Lawley: www.adrianlawley.com
Thanks everyone for the wonderful responses. I’ll have a look into the provided options later today.
Best wishes,
Mark
PS: I’m the SEO manager of a SEO company in Belgium so I can tell you a thing or two about the value of keywords.