Jump to content

Request on Data Hook for makeSeoTitle()


Sonya*

Recommended Posts

Over a year ago I have asked for overloading makeSeoTitle() function to suit languages with characters beyond English alphabet () A year later I have suggested a simple code Unfortunately it works as patch as I have not seen any possibility to hook into function. Now I have read in the documentation that one can submit a request for data hook http://www.invisionpower.com/support/guides/_/advanced-and-developers/hooks/data-hooks-r43

I am going to start some new projects in German and Russian next month and I use the SEO Title patch in all my projects. I am afraid that it would be difficult for me to handle this on more projects and to patch my projects with every new version again and again. :(

My question: is it possible to add Data Hook so that we can hook into makeSeoTitle() the way I have described here ?

Link to comment
Share on other sites

  • 2 months later...

All the new support does is allow you to swap out character x for character y. That's all you are trying to do anyways. What is lacking with the romanization ability?

Nothing is lacking in romanization ability :D I had ask for Data Hook on makeSeoTitle() to make so called "translit". What I am doing right now is patching as I have described it here And I know that a lot of cyrillic boards do the same. In IPS there no possibility to hook into makeSeoTitle(), neither library hook nor data hook. Also no possibility to make it through localization. Only patching :sad:

That's why I have asked if it is possible to add a Data Hook there to be able to add custom replacement table without patching.

Link to comment
Share on other sites

One more question: does this romanization.php really work without patching the core? I have found this fresh topic http://community.invisionpower.com/topic/383898-words-containing-diacritics-characters-in-furl/?p=2394486 where instructions of how the core should be modified to get romanization.php to work are given.

My intention was not to patch any more. Replacing one patch with another was not my aim :smile:

Update: Have figured it out. No. Romanization.php does not work for UTF-8 boards as it is called only

if ( IPS_DOC_CHAR_SET != 'UTF-8' )

Therefore my request or Data Hook remains. Please give the possibility to hook into makeSeoTitle() for UTF-8 boards as well. Thank you!

Link to comment
Share on other sites

Similar issue here. It's not as bad, as my board is in Portuguese, but romanization.php won't load because we are using UTF-8. When the URL is pasted in a text-only field like a Skype chat, it's full of encoded characters and unreadable.

And is it just my board or are the FURLs applied differently to tags? If they have spaces in them, they are not replaced by "-" and not "friendly" even in the address bar.

Link to comment
Share on other sites

I just wanted to draw your attention to "bugs" after security update.

http://community.invisionpower.com/resources/bugs.html/_/ip-board/new-securityupdate-bug-greek-language-r42147

http://community.invisionpower.com/resources/bugs.html/_/ip-board/new-security-upgrade-problem-r42146

Every time the core.php is updated the urls in non-English boards are broken as non-English boards have to patch core.php. There are 2 "bugs" in bug tracker. I can imagine that there were some tickets. There are certainly some boards that "do not notice" the issue after update, but they will come with the issue later. And some boards that merge the changes together without posting a bug or opening the ticket. Those issues could be solved once and for ever there if there were a legal possibility to adjust transliteration in URLs :unsure:

Link to comment
Share on other sites

And is it just my board or are the FURLs applied differently to tags?

They are different. The tags are not parsed through makeSeoTitle(), the reason why I personally do not use them. This is another request but sure it would be nice to have only latin characters in URL for everything in IPS. :smile:

Link to comment
Share on other sites

So I am clear...you are starting a new project (so you don't have to redirect old urls or anything), you are using UTF-8 (so you have full character-set support), and you want to transliterate the German/Russian characters into latin characters? Can you clarify why you want to do this exactly, as it seems like you are creating a lot more work for yourself than necessary?

Link to comment
Share on other sites

Our site is using ISO-8859-1 which is why copying UTF-8 links doesn't work here (and why we address them differently in the software when you're not using UTF-8).

If I copy the first link and post it locally, this is what posts

2013-05-07_1046.png

As you can see it doesn't look like spam and displays correctly.

There should be virtually no sites that can't support UTF-8 urls out there, so the concern about sharing the link to a third party site should be minimal. That said, it would be up to those sites to address the problem surely? What about wikipedia URLs, which are undoubtedly more common than the average link from a message board?

Link to comment
Share on other sites

@bfarber, if you go to one of Wikipedia links given above, copy the URL from the address bar and just paste it into MS Word or Skype or here (without saving), you will get the messy look. It does not deal with ISO at all. Modern browsers decode non-ASCII urls on copy to clipboard, at least major ones (latest Chrome, latest Firefox). After all it is a netiquette to use only ASCII characters in links in non-English internet.

As for the Wikipedia links, I do not own Wikipedia :smile: They can afford to have this messy spam looking links. They have trusted TLD. Me - not so trusted :D

At the end:

1. There is a simple solution how it can be solved. But I do not ask for it. Just for one single Data Hook to avoid patching.

2. There are non-English boards (your clients) that use hacks to get rid of special characters in URL and make it again and again (look through bug tracker to see how they suffer ;))

3. If it deals with ISO (I doubt) then you know that your site is not the single one that use ISO, so the problem is common.

4. The most major CMS out there support transliteration out of the box or offer hooks where one can implement it individually.

5. Plus the usability reasons I have listed in another topic.

6. Plus the netiquette in non-English internet.

I was not aware that requesting for one Data Hook can be so long discussed.

Please write "No, we will not do it" and close this topic. I am out of reasons right now :D

Link to comment
Share on other sites

I see. For me the only reason for this hook is to avoid pathing. I hate patches and this is the only one I have to do on all my projects :( When I accidentally overwrite it, it's awful especially for Russian projects, where all links are going to be messy.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...