Announcement

Collapse
No announcement yet.

Working with SEO, texts and URLs in KVS themes

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Working with SEO, texts and URLs in KVS themes

    All KVS themes use the same approach of configuring texts and SEO. In admin panel you can change any text in Website UI -> Texts section. You can simply search by the text you want to change and KVS will show you all texts where this fragment is used:

    Click image for larger version  Name:	test_search.png Views:	1 Size:	33.0 KB ID:	644

    SEO

    In Website UI -> Texts section filter by SEO group. You will see a lot of texts, which can then further be filtered by Page, for example select Index page:

    Click image for larger version  Name:	index_seo.png Views:	1 Size:	39.3 KB ID:	645

    For each page you will normally see 3-5 texts like this:

    Code:
    html.index_title - for HTML title of this page
    html.index_description - for HTML description of this page
    html.index_keywords - for HTML keywords of this page
    html.index_seo_title - for SEO title displayed on this page
    html.index_seo_text - for SEO text displayed on this page
    SEO title and SEO text are not available for every page, normally they are available on Index and on main lists (videos by category, by tag, by model, by search and etc). The other 3 texts are available for all pages.

    Some pages that render different lists may have many different versions of these texts. For example Common Videos List / Common Albums List pages render videos by category, videos by tag, latest videos, top rated videos and etc. For each of these variants you will see a set of these texts:

    Click image for larger version  Name:	common_videos_seo.png Views:	1 Size:	92.0 KB ID:	646

    On Index page you would normally write some static text there, describing your site or whatever you think may be useful for your SEO. When a list page is displayed by category or tag or search, you should normally show different texts for different categories or tags or search requests to have better SEO coverage. You can do that with using tokens, that will be replaced by some data from category, tag and etc.

    For example search for texts by this external ID: html.videos_by_category. You will see the following 4 texts:

    Code:
    html.videos_by_category_title = %title% Videos
    html.videos_by_category_description = %description%
    html.videos_by_category_keywords = %synonyms%
    html.videos_by_category_seo_text = Sample SEO text for showing on %title% category page...
    Click image for larger version  Name:	categories_seo.png Views:	1 Size:	45.7 KB ID:	647

    These texts are used on page that renders videos list from a specific category. You can see that these texts use some tokens inside them, the tokens will be replaced with some data from category that is currently displayed. So "%title% Videos" will be replaced with "Music Videos" on Music category and "Funny Videos" on Funny category, "%description%" will be replaced with category description and "%synonyms%" will be replaced with category synonyms. You can play with these tokens to get some unique texts for your site. All supported tokens will be listed below.

    And there is also advanced opportunity to randomize texts for different objects, which is especially useful in tags and search results, where there can be a big variety of different texts.

    Consider the following example for tag page title:
    Code:
    html.videos_by_tag_title = [rand]Free || Cool || Best || HQ || HD || High quality[/rand] %tag% videos
    There is a [rand]...[/rand] block inside this text. This block will force KVS to take one of the listed fragments randomly for every tag page. So here are different displays for different tags:

    Free music videos
    Best funny videos
    High quality mobile videos
    ...

    The key thing here is that random fragment will remain constant for the same tag, unless you update this text notation - updating it will result in another randomization seed. So there will always be "Free" selected for "music" tag and there will always be "Best" selected for "funny" tag. Again, this will remain constant for the time when you don't touch this text anymore. Once you change it (e.g. change the order of words, or anything else in this text), there may be another random fragments selection.

    You can use [rand]...[/rand] block everywhere in SEO texts (title, desc, keywords, SEO text and title). But title and SEO text / SEO title are the best places for this. Usually it makes sense to use this with tags and search queries due to their big volume.

    Here are tokens supported for different pages (token meaning should be clear from token name):

    - Videos / albums by category:
    Code:
    %title%, %description%, %synonyms%, %total_videos%, %total_albums%, %total_photos%, %today_videos%, %today_albums%, %custom1% - %custom10%, %first_object_title%, %first_object_description%
    - Videos / albums by tag:
    Code:
    %tag%, %synonyms%, %total_videos%, %total_albums%, %total_photos%, %today_videos%, %today_albums%, %first_object_title%, %first_object_description%
    - Videos / albums by model:
    Code:
    %title%, %description%, %alias%, %country%, %city%, %height%, %weight%, %birth_date%, %age%, %total_videos%, %total_albums%, %total_photos%, %today_videos%, %today_albums%, %custom1% - %custom10%, %first_object_title%, %first_object_description%
    - Videos / albums by content source:
    Code:
    %title%, %description%, %total_videos%, %total_albums%, %total_photos%, %today_videos%, %today_albums%, %categories_as_string%, %group_as_string%, %custom1% - %custom10%, %first_object_title%, %first_object_description%
    - Videos by channel:
    Code:
    %title%, %description%, %total_videos%, %today_videos%, %categories_as_string%, %custom1% - %custom10%, %first_object_title%, %first_object_description%
    - Videos / albums by search:
    Code:
    %search_keyword%, %first_object_title%, %first_object_description%
    - Video view page:
    Code:
    %title%, %description%, %duration%, %rating%, %rating_amount%, %video_viewed%, %username%, %release_year%, %custom1% - %custom3%, %tags_as_string%, %categories_as_string%, %models_as_string%, %content_source_as_string%, %dvd_as_string%
    - Album view page:
    Code:
    %title%, %description%, %photos_amount%, %rating%, %rating_amount%, %album_viewed%, %username%, %custom1% - %custom3%, %tags_as_string%, %categories_as_string%, %models_as_string%, %content_source_as_string%

    URLs

    There are 2 places where you can configure URL patterns:

    1) In Settings -> Website Settings you can configure system patterns to the main object pages. These patterns are used in admin panel and other system functionality, so they are managed here in this special place:

    Click image for larger version  Name:	system_url_patterns.png Views:	1 Size:	46.4 KB ID:	648

    2) In Website UI -> Texts section you can configure all other URL patterns used by your theme. You can filter them by URL patterns group filter:

    Click image for larger version  Name:	theme_url_patterns.png Views:	1 Size:	32.3 KB ID:	649

    Some URL patterns also include a token, where dynamic URLs are built (category page, tag page and etc - %DIR% on the above screenshot). If you change such patterns, you should also make sure to keep the same token there, otherwise URL patterns will be broken.

    Changing URL patterns is not recommended for basic users. In order for new URL patterns to work you will need to add changes to /.htaccess file and modify RewriteRules there. KVS uses mod_rewrite to manage URL mapping, which is difficult to use, but the most flexible way and provides unlimited customization capabilities.

    Here is small example. If you want for example to change this pattern:
    Code:
    urls.albums = /albums/
    To:
    Code:
    urls.albums = /photos/
    you also need to locate the corresponding rule(s) in /.htaccess file. Please be aware that each list page RewriteRule also has a sister rule for pagination, e.g. to make these pages work:

    /albums/2/
    /albums/3/
    /albums/4/
    ...

    Usually these 2 sister rules are grouped together:
    Code:
    RewriteRule ^albums/([0-9]+)/$ /albums_list.php?from=$1 [L,QSA]
    RewriteRule ^albums/$ /albums_list.php [L,QSA]
    You should change pattern in both of them to photos:
    Code:
    RewriteRule ^photos/([0-9]+)/$ /albums_list.php?from=$1 [L,QSA]
    RewriteRule ^photos/$ /albums_list.php [L,QSA]
    Please note that end of the rule remains the same as before, you only change the first part of rewrite rule (e.g. this part /albums_list.php [L,QSA]).

    Again, we do not recommend to change this for basic users, URL patterns are not something that much affects anything.
Working...
X