e107inc / e107

e107 Bootstrap CMS (Content Management System) v2 with PHP, MySQL, HTML5, jQuery and Twitter Bootstrap. Issue Discussion Room: https://gitter.im/e107inc/e107
https://e107.org
GNU General Public License v3.0
321 stars 213 forks source link

Keywords breaks phrases into words #247

Closed STR82U closed 11 years ago

STR82U commented 11 years ago

Any phrases that are used in keywords gets broken into individual words (and OG:tags) when they should be left intact as phrases.

CaMer0n commented 11 years ago

Thanks for this. How are you testing? I just tested with news, here's the result in news.php?extend.x:

<meta property="keywords" content="heres my phrase, and something, else, here" />
<meta property="article:tag" content="heres my phrase" />
<meta property="article:tag" content=" and something" />
<meta property="article:tag" content=" else" />
<meta property="article:tag" content=" here" />
STR82U commented 11 years ago

Works fine with full install and Bootstrap, below is from an upgrade the same night we tested upgrading the forum for the last time for alpha release. Keywords, as written, are in the description:

`

`

I'm going to update the files of the upgrade to the current git master files but that's what was used to do the upgrade. I'll close this if it resolves itself.

STR82U commented 11 years ago

Are the meta tags being cached? With the content and system cache set "On", the metatags disappear on page refresh and reappear after flushing the cache then disappear on refresh.

This cache problem was an issue all the way back to 0.8 --> my fix isn't compatible with v2

STR82U commented 11 years ago

The keywords breaking worked itself out, don't know how. The last time I caught this before alpha it had to do with "eHelper::formatMetaKeys" - If this was removed from the news_class it would retain complete phrases.

Also, somewhere during all the testing, the metatags for one item were deleted from the database altogether.

ALSO: look at the added spaces, there should be no added space before the keyword/phrase but that's saving to the dbase that way.

STR82U commented 11 years ago

I see that application.php was updated recently so that must be the fix and the problem in the upgraded version; has a note about formatting keywords.

metatags still disappear on refresh.

myovchev commented 11 years ago

I suppose you are experiencing cache related issue. I fixed the empty space on every tag. I'll perform some more caching tests soon.

myovchev commented 11 years ago

Forgot to mention - the main issue is fixed before the alpha release (breaking phrases to keywords). Disappearing meta information is the one related (most probably) with the site cache.

STR82U commented 11 years ago

Your trim fix eliminates the space for OG tags but not meta property="keywords", it needs to remove the space before saving the keywords to the database. `

`

I suppose you are experiencing cache related issue. Yes, when the Content cache is "Enabled", most metatags will not be in the page after a refresh (title,copyright,author and additional metatags still appear)

Before F5:

<meta property="og:title" content="SEO and e107" />
<meta property="og:type" content="article" />
<meta property="description" content="Find out more about search engine friendly urls for e107 and using the SEO features built into e107 V2." />
<meta property="og:description" content="Find out more about search engine friendly urls for e107 and using the SEO features built into e107 V2." />
<meta property="og:image" content="http://example.co/e107_media/d087d9f833/images/2013-01/image-in-article.png" />
<meta property="og:url" content="http://str82u.co/news/seo-and-e107.html" />
<meta property="article:section" content="SEO and e107" />
<meta property="keywords" content="testword one, testword two, testword three" />
<meta property="article:tag" content="testword one" />
<meta property="article:tag" content="testword two" />
<meta property="article:tag" content="testword three" />
<meta property="copyright" content="Testing" />
<meta property="author" content="Tester" />
<meta property="og:image" content="http://example.co/e107_media/d087d9f833/images/2013-01/siteLogo.png" />

<title>SEO and e107 - STR82U V2 Demo</title>
..........
<meta name='robots' content='index,follow' />

After F5:

<meta property="copyright" content="Testing" />
<meta property="author" content="Tester" />
<meta property="og:image" content="http://str82u.co/media/d087f9d833/images/2013-01/siteLogo.png" />

<title>SEO and e107 - STR82U V2 Demo</title>
.......
<meta name='robots' content='index,follow' />
STR82U commented 11 years ago

Forgot to mention - the main issue is fixed before the alpha release Yes, I missed that updated file on the first version I tested yesterday, an upgraded site from the day you committed that file change.

STR82U commented 11 years ago

Looks like the main site Keywords and Description from /e107_admin/meta.php don't make it into pages either, before or after refresh, it doesn't matter on this one.

CaMer0n commented 11 years ago

@STR82U Can we close this?

STR82U commented 11 years ago

I didn't know he updated that, I'll have to check. If it's still an issue I'll reopen it.