Token not being replaced

Created on 28 June 2023, 12 months ago
Updated 11 September 2023, 10 months ago

Token not being replaced in DXPR Builder Text Editor.

πŸ’¬ Support request
Status

Closed: works as designed

Version

2.2

Component

User interface

Created by

πŸ‡³πŸ‡¬Nigeria mombi

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @mombi
  • Status changed to Postponed: needs info 12 months ago
  • πŸ‡³πŸ‡±Netherlands JurriaanRoelofs

    Hi mombi,

    Thank you for reporting the issue regarding the token not being replaced in the DXPR Builder Text Editor. To help us further investigate and address the problem, could you please provide us with more information? Here are a few details we would find helpful:

    1. Steps to reproduce the bug: Please provide a detailed list of the steps you followed that led to the token not being replaced in the Text Editor. This will allow us to recreate the issue on our end and understand the problem better.
    2. Expected behavior: What is the expected outcome when the token is used in the Text Editor? Please describe how the token should be replaced or any specific behavior you were anticipating.
    3. Actual behavior: Could you explain what happens when you use the token in the Text Editor? Does it display an error message, show the token itself without replacement, or behave in some other unexpected way?
    4. Platform and version: It would be helpful to know the platform or software you are using, along with its version number. Additionally, if you have any relevant browser information or operating system details, please provide those as well.
    5. Any additional context: If there are any other details or context you can provide related to the bug, such as recent changes made, specific configurations, or any other relevant information, please share them with us.

    By providing these details, we will have a better understanding of the issue you're facing and can assist you more effectively in resolving it. Looking forward to your response and working towards a solution together!

  • πŸ‡³πŸ‡¬Nigeria mombi

    I installed DXPR Builder on pre-existing content types, I set DXPR Builder as format on the text field in Manage Display form.
    I create a content item that will be used as the home page of the site. I add text element through the DXPR builder.

    I have added [site:name] token, but the value is not replaced when viewing the node.

    For example if I write :

    Welcome to [site:name].

    the value should replaced with:

    Welcome to Online College,

    but the value is not replaced when viewing the node.

    But when I set the text field in Manage Display form to Default, the Token value is replaced. Is that clear enough?

    I'm using:
    10.1.0
    DXPR builder 2.2.7
    Token Filter 2.0.0

  • Status changed to Active 12 months ago
  • πŸ‡³πŸ‡±Netherlands JurriaanRoelofs

    Thank you for providing more details. I recommend following these steps to address the problem:

    1. Please go to /admin/dxpr_studio/dxpr_builder/settings and enable the setting Text Format Filters > Process Text Format Filters on Frontend Builder content.
    2. When enabling this setting, make sure that any text format filters which have the potential to remove or alter DXPR Builder's generated HTML are configured not to interfere destructively with the HTML. Specifically, pay attention to any HTML filtering that might occur.
    3. After making these changes, please test the issue again and let me know if it resolves the problem.
  • πŸ‡³πŸ‡¬Nigeria mombi

    Thank you.

    I enable the setting Text Format Filters. and I created a page, when viewing the node (Home page), it generated raw HTML sample code shown below:

    etc

    I did not install any text format filters which have the potential to remove or alter DXPR Builder's generated HTML.

  • πŸ‡³πŸ‡¬Nigeria mombi

    I have followed the above instruction, but still not working, instead, it generated raw HTML when viewibg the node.

  • πŸ‡³πŸ‡¬Nigeria mombi

    I will not subscribe to any of DXPR Builder's subscription on your website if you can not address this problem. DXPR Text Format does not work with Drupal Token Filters.

  • πŸ‡³πŸ‡±Netherlands JurriaanRoelofs

    Hello mombi,

    The the moment, when enabling the Text Format Filters option, the token will be processed for non-editor users. This means you can use the token, and when viewing the page as anonymous user they will see the replacement of the token.
    As editor however, you are still looking at the token, because if the token were replaced, and you are editing the text, then you would save the actual replacement into the database and lose the token.

    Regards,
    Jurriaan

  • Status changed to Closed: works as designed 10 months ago
  • πŸ‡³πŸ‡±Netherlands JurriaanRoelofs

    I will close this issue as it currently "Works as designed" however we are researching whether we can run formatting filters for editor users as well, but this would be considered a new feature.

Production build 0.69.0 2024