Jump to content

tags URL wrong forming


Recommended Posts

All my tags with special characters (german) are forming a wrong URL.

F.ex.

keyword: Ausströmer = /search.php?tag=Ausstr-and here strange characters instead of-ö mer
keyword: Kürbis = /search.php?tag=K-and here strange characters instead of-ü rbis

and so on. Also the canonical are forming with the strange characters like % C 3 % B 6 for ö.

I take a look into /classes/tag.php and also in modules/blocktag/blocktags.php on both files there is nothing specified with UTF-8, shall this the problem ? If yes, how to fix ?

Link to comment
Share on other sites

Yes, sorry. I checked it again and it ist used:

    {$tag.name|escape:html:'UTF-8'}     



Project is in coming, but has no public access now (is a clone from an existing domain with another e-commerce software, but with different IP's). To have access you must change your hosts file in windows to do not ping the online project. What do you need to evaluate ?

Link to comment
Share on other sites

I re-read again the original post. It seems that I misunderstood the question.
Just like "inveostore.com" pointed out, it is correct to covert special char to something %C. It is the work of urlencode().

If there is no problem with URL link (for example, broken link), then everything is normal, sorry for the confusion.

Link to comment
Share on other sites

  • 3 weeks later...

I had the same problem with Latvian charters - ā,ē,č.... . I solve it by deleting lines 64-66 in themes/(theme)/pagination.tlp

                        {if $requestKey != 'requestUrl'}
                           <input type="hidden" name="{$requestKey|escape:'htmlall':'UTF-8'}" value="{$requestValue|escape:'htmlall':'UTF-8'}" />
                       {/if}


what does this line do anyway? maybe someone can fix it without deleting it?

P.S I had this problem when I choose tags and then tried to change products per page.

Link to comment
Share on other sites

  • 3 weeks later...

Hi, cd2500!
I had problem with tags with specific letters(ā,ē,ī etc) and I had problem with the choosing producs per pagein those tag lists. I recomend you to edit pagination.tlp (in version 1.3.7) lines 48-73

{if $nb_products > 10}
       <form action="{if !is_array($requestNb)}{$requestNb}{else}{$requestNb.requestUrl}{/if}" method="get" class="pagination">



               {if isset($query) AND $query}<input type="hidden" name="search_query" value="{$query|escape:'htmlall':'UTF-8'}" />{/if}
               {if isset($tag) AND $tag AND !is_array($tag)}<input type="hidden" name="tag" value="{$tag|escape:'htmlall':'UTF-8'}" />
               {else is_array($requestNb)}
                   {foreach from=$requestNb item=requestValue key=requestKey}
                       {if $requestKey != 'requestUrl'}
                           <input type="hidden" name="{$requestKey|escape:'htmlall':'UTF-8'}" value="{$requestValue|escape:'htmlall':'UTF-8'}" />
                       {/if}
                   {/foreach}
               {/if}
               <input type="submit" class="button_mini" value="{l s='OK'}" />
{l s='items:'}

               {foreach from=$nArray item=nValue}
                   {if $nValue <= $nb_products}
{$nValue|escape:'htmlall':'UTF-8'}
                   {/if}
               {/foreach}



       </form>
   {/if}

Link to comment
Share on other sites

Hi Artizzz,
thxs for code. But no change... I'm still getting an wrong UTF-8 encoding like this:

D % C 3 % B C n g e w % C 3 % B C rfel instead the word Düngewürfel as URL

Hi, cd2500!

Did you find some solution? Now on 1.4.0.17 version I have this url problem in tag list when I choose different number of products per page it shows word - Grāmata like "Gr % 2 5 C 4 % 2 5 8 1 matas"(what I can't with method what posted before).
Link to comment
Share on other sites

No- no solution. According to a SEO proficient the SERP's also can read these UTF-encoding and translating into right characters. If you go with mousover on the link browsers translate them. The same do google & co.

I think we can let it, if on header the encoding is UTF-8 (presta standard)

Link to comment
Share on other sites

No- no solution. According to a SEO proficient the SERP's also can read these UTF-encoding and translating into right characters. If you go with mousover on the link browsers translate them. The same do google & co.

I think we can let it, if on header the encoding is UTF-8 (presta standard)

yea, but my problem isn't only url looking. Look at my test site list of tag(with specific charter) - http://artis.noooby.lv/en/search?tag=ārprātš and when you are in try to change products per page.
This is version 1.4.0.17 and there is something different because in version 1.3.7 I fix it with that code what I posted before.
Any ideas how to fix to make it working?
And strangest thing is that the page selecting from pagination works with words with specific charters.
Link to comment
Share on other sites

Yes it works because the strange characters are a readable UTF-encoding. No I don't know how to fix. As developer of module garanted to me, that google & co. also can read/translate the characters into readable one, I let it so...
For me the strange characters are only in source.code, but not when you go with your mouse over the link. It's only on source...

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...