Keyword

Category Page Meta Description and Keywords

  • Red Evolution
  • Red Evolution's Avatar Topic Author
  • Offline
  • Premium Member
More
14 years 10 months ago #75376 by Red Evolution
Category Page Meta Description and Keywords was created by Red Evolution
Hi,

Just getting to grips with K2 and evaluating it for use in a large site. I created a category and linked to it but can't seem to add meta data for this page. The category itself doesn't have meta data input boxes and the menu link parameters don't allow them to be created either.

Am I missing something?

cheers

d

Please Log in or Create an account to join the conversation.

More
14 years 10 months ago #75377 by vtiger
Replied by vtiger on topic Category Page Meta Description and Keywords
Hi, there is not that option with J! default or J! SEF. Unfortunately.
But this can be solved with sh404sef or

Is also possible add some code to the head of your category.php template which grab "category description" and put them to metatitle and Item title to metakeywords. Better than nothing ;)


// no direct access
defined('_JEXEC') or die('Restricted access');
/* Add AtLeast AutoMetadata - Hack */
$mainframe->prependMetaTag( "keywords", substr(strip_tags($this->category->name ), 0, 255) );
$mainframe->prependMetaTag( "description", substr(strip_tags($this->category->description ), 0, 255) );


Regards,
l

Please Log in or Create an account to join the conversation.

More
14 years 2 months ago #75378 by Andrew Holden
Replied by Andrew Holden on topic Category Page Meta Description and Keywords
Lukas said:Hi, there is not that option with J! default or J! SEF. Unfortunately. But this can be solved with sh404sef or
Is also possible add some code to the head of your category.php template which grab "category description" and put them to metatitle and Item title to metakeywords. Better than nothing ;)


// no direct access
defined('_JEXEC') or die('Restricted access');
/* Add AtLeast AutoMetadata - Hack */
$mainframe->prependMetaTag( "keywords", substr(strip_tags($this->category->name ), 0, 255) );
$mainframe->prependMetaTag( "description", substr(strip_tags($this->category->description ), 0, 255) );


Regards,
l


Thanks - that sounds like a great idea.

However, I'm not sure which category.php to modify. I've got an override for catgory.php in my normal HTML folder, but it doesn't seem to be accomplishing my goal - (since I've removed the default category description in the override).

Any suggestions on adding a meta description *without* using the string you mention above? I only have one blog-page on my site, so I could add the data directly, but I'm not sure how...

The strange thing is that Google et al. is only seeing the most recently indexed post as our meta - not sure why.

Please Log in or Create an account to join the conversation.

More
14 years 1 month ago #75379 by Krasimir Nikolov
Replied by Krasimir Nikolov on topic Category Page Meta Description and Keywords
great solution! thanx!

Lukas said:// no direct access
defined('_JEXEC') or die('Restricted access');
/* Add AtLeast AutoMetadata - Hack */
$mainframe->prependMetaTag( "keywords", substr(strip_tags($this->category->name ), 0, 255) );
$mainframe->prependMetaTag( "description", substr(strip_tags($this->category->description ), 0, 255) );


Regards,
l

Please Log in or Create an account to join the conversation.

More
14 years 2 weeks ago #75380 by John mcelborough
Replied by John mcelborough on topic Category Page Meta Description and Keywords
Krasimir Nikolov said:great solution! thanx!
Lukas said:// no direct access defined('_JEXEC') or die('Restricted access');
/* Add AtLeast AutoMetadata - Hack */
$mainframe->prependMetaTag( "keywords", substr(strip_tags($this->category->name ), 0, 255) );
$mainframe->prependMetaTag( "description", substr(strip_tags($this->category->description ), 0, 255) );


Regards,
l




I'd second this- exactly hat I was looking for thanks.

Please Log in or Create an account to join the conversation.

More
14 years 2 weeks ago #75381 by vtiger
Replied by vtiger on topic Category Page Meta Description and Keywords
Great, nice to hear that.
Thanks
l

Please Log in or Create an account to join the conversation.

More
13 years 7 months ago #75382 by emre
ı made manuel metas. I modifeid some page and db. And İt worked.----DB CHANGE/UPDATE
addALTER TABLE `jos_k2_categories` ADD `metadesc` text NOT NUL
>
ALTER TABLE `jos_k2_categories` ADD `metakey` text NOT NUL
>

Please Log in or Create an account to join the conversation.

More
13 years 7 months ago #75383 by vtiger
Replied by vtiger on topic Category Page Meta Description and Keywords
Sweet.

Hope that Lefteris is going implement this...

 

l

Please Log in or Create an account to join the conversation.

More
13 years 6 months ago #75384 by Ben Chesters
Replied by Ben Chesters on topic Category Page Meta Description and Keywords
Thank you very much for this, much appreciated.

emre said:
ı made manuel metas. I modifeid some page and db. And İt worked.----DB CHANGE/UPDATE
addALTER TABLE `jos_k2_categories` ADD `metadesc` text NOT NUL
>
ALTER TABLE `jos_k2_categories` ADD `metakey` text NOT NUL
>

Please Log in or Create an account to join the conversation.

More
13 years 5 months ago #75385 by rawling
Replied by rawling on topic Category Page Meta Description and Keywords
Please help... metadesc and metakey of category edit, present in database fnd shov in adminpanel, but not present in html of category

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum