First time here? Check out the FAQ!
5

Make meta description relevant to current page.
 

I notice that the meta description for every page on my site – homepage, questions, profiles – is the same:

A community for expats to meet and share knowledge

Since sites like Facebook and Google use this information to display summaries for links to pages on my site, it would be much better for the meta description to be relevant to the current page:

  • Questions: Use the first n words of the question text.
  • Profiles: Use the first n words of the user's "about me" text (if applicable).
  • Meta Pages (/badges, /users, etc.): Each of these pages should have its own meta description that describes its unique purpose.

To enter a block of code:

  • enter empty line after your previous text
  • paste or type the code
  • select the code and press the button above
Preview: (hide)
todofixthis's avatar
1.3k
todofixthis
asked 12 years ago

Comments

1

This sounds reasonable, maybe make meta almost the same as page title with a site name prepended and maybe few most frequently used tags?

Evgeny's avatar Evgeny (12 years ago)
1

Agreed, although I would suggest appending the site name rather than prepending it (put the most relevant/specific information first).

todofixthis's avatar todofixthis (12 years ago)
1

Why first n words? Questions: Use the first n words of the question text.

I think its neat to include the whole question as title. Anyway Facebook cuts texts to fit the frames; so let's not worry. :)

pajju's avatar pajju (12 years ago)
see more comments

1 Answer

2

Hi, I see on question.html template, this line of code

{% block meta_description %}
        <meta name="description" content="{{question.summary|striptags|escape}}" />
{% endblock %}

but the real page meta description is still the default one "Open source question and answer forum written in Python and Django", probably taken from the default meta_description block definition inside html_head_meta.html

If you look at the meta description of this page you see the same bug!

This is only a relative little problem, but I see that block overrides don't work in the whole templating system. Can someone have a look at this?

To enter a block of code:

  • enter empty line after your previous text
  • paste or type the code
  • select the code and press the button above
Preview: (hide)
nr's avatar
21
nr
answered 12 years ago, updated 12 years ago
link

Comments

see more comments