Jump to content

Bug with load more activity button


Li3D

Recommended Posts

Hi,

As i'am french, the "load more activity" button is translated with "activité que j'ai créé".

Just to show the problem, I switched to english and added "J'AI" in the string :

Could contain: Page, Text, File

 

So far so good, but if I press the load more activity button :

Could contain: Electronics, Hardware, Text, Hook

all the apostrophe (') are replaced by the HTML code :

Could contain: Page, Text, File

 

It does this for all the elements in this menu that have "'a" in the string. It's OK with a space after the apostrophe but that's not the correct way to write it 🙂 

Link to comment
Share on other sites

12 minutes ago, Marc said:

I have been unable to replicate this unfortunately.

Indeed, it comes from the child theme I created from the default theme to apply some modifications... I'll look for which one could cause the problem but if you have a lead on the file that calls the button function I'm all ears.

Link to comment
Share on other sites

I "reverted" every modified files but they still appear "modified" :

Could contain: Page, Text, File

 

Anyway, if I search for "<!-- Li3D -->" which I use to find my modifications there are no more results.

I cleared the cache and applied the lastest patch without success.

Maybe a JS script from the parent theme not updated somewhere ?

 

Link to comment
Share on other sites

Posted (edited)

I created a new theme from the 4.7.X sources and I finally have the same problem. I also disabled all plugins and all applications and I still have the problem even after cleaning the cache 🤔

I suspect a problem with root_library.js or front_front_streams.js.

Edited by Li3D
Link to comment
Share on other sites

Could contain: Page, Text, File, Webpage

 

I tried in private browsing without cache and it's the same. Anyway, it's a "bug" reported by users, I'm not the only one to have it.

In the console I only see front_front_streams.js called when I hit the button.

 

It only happens with "J'AI", not "J' AI".

Link to comment
Share on other sites

If there is an issue on the server, your users will of course also see this. When I refer to caching, I mean caching on your server itself. Please check with your hosting company if you are unsure on this

Link to comment
Share on other sites

No caching on the hoster side 😞 

JS file loaded is the same I can open via FTP.

Can you confirm me that the script loaded when I press load more is front_front_streams.js ?

Link to comment
Share on other sites

3 minutes ago, Li3D said:

No caching on the hoster side 😞 

JS file loaded is the same I can open via FTP.

Can you confirm me that the script loaded when I press load more is front_front_streams.js ?

I have tagged our developers to see if someone can confirm that for you. Im not a developer myself on the platform

Link to comment
Share on other sites

 

I took a closer look at the script in question:

self._updateStreamUI = function(response) {
    // Updating stream UI...
    this.scope.find('[data-role="streamBlurb"]').text(response.blurb.replace(/&#039;/g, "'"));
    this.scope.find('[data-role="streamTitle"]').html(response.title);
    // More UI update logic...
}

I have a strong feeling that it comes from there 🤔

Link to comment
Share on other sites

I think there might be an issue with the XSS protection.

If I translate like that :

Could contain: Page, Text

 

The letter A HTML code "&#97;" is correctly rendered (A displayed).

As soon as I press the load more button, the A code is no more rendered and I can read the code in front :

Could contain: Page, Text

Link to comment
Share on other sites

Ah, have you tried translating them from the stream itself in System->Content Discovery->Streams? I believe thats what the difference is between what Im doing here, and what you are attempting on your end

Link to comment
Share on other sites

I see the difference there. Thank you Nathan, that helped

Thank you for bringing this issue to our attention! I can confirm this should be further reviewed and I have logged an internal bug report for our development team to investigate and address as necessary, in a future maintenance release.

 

Link to comment
Share on other sites

  • Recently Browsing   0 members

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