web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

{Portal} How to display static html content in web form steps

(0) ShareShare
ReportReport
Posted on by 55,410 Moderator

I have configured a web form with multiple steps. After certain steps, I need to display some text (general guidelines) along with the field data captured in the previous steps. Basically a summary page along with some additional instruction and external  links.

As we do not have access to web templates for web form steps, what would be the best way to achieve this?

*This post is locked for comments

I have the same question (0)
  • RaviKashyap Profile Picture
    55,410 Moderator on at

    *bump*

  • Niels Hoppenbrouwers Profile Picture
    90 on at

    Not sure if this is the answer but, you could look into the event handlers on the fields of the form when specific fields change you could execute some code or script. You could create the static html as a web resource and load/run it when u need it.  Personally haven't worked with forms with multiple steps yet so i can't say if it would work.

  • Verified answer
    Rizwan Aarif Profile Picture
    480 on at

    Hi Ravi,

    You could add a custom web resource and add it to a Tab/Section in CRM Entity form. It'll render in portals in that particular web form step (as per your choice). You can also use conditionaly on/off.. show/hide using Jquery then.

    Let me know if this helps.

  • Aric Levin - MVP Profile Picture
    30,190 Moderator on at

    Hi Ravi,

    What we have usually done in this kind of scenarios is display the fields from the previous steps as hidden (using jquery), and then use jquery to manipulate the data and display the text on the form as needed.

    We add placeholders for text inside the Web Template, so that it is easily accessible.

    Hope this helps.

  • RaviKashyap Profile Picture
    55,410 Moderator on at

    Hi Aric,

    Which template you use for manipulating the steps? Could you please share some more details?

  • Suggested answer
    sandeepstw Profile Picture
    4,601 on at

    Hi Ravi,

    You can create sections in form for multiple steps and add HTML web resource in form session where ever you need.

  • Suggested answer
    Aric Levin - MVP Profile Picture
    30,190 Moderator on at

    Hi Ravi,

    I am not sure that the way we implemented this is the best way, but it is working for us.

    On the last page of the web form, you actually add the controls that you need to gather information from, and using jquery on the jquery.

    Inside the Web Template that we created that is being used by our process we added the following logic (example)

                    {% assign stepId = request.params['stepid'] %}
                    {% if stepId %}
                    {% assign webFormStep = entities.adx_webformstep.[stepId] %}
                        <h2 class="section-title mar-b20">{{ webFormStep.adx_name }}</h2>
                        <p class="mar-b30">{{ webFormStep.adx_instructions.value }}</p>
                    {% else %}
                        <h2 class="section-title mar-b20">Default section header</h2>
                        <p class="mar-b30">Default section title</p>
                    {% endif %} 

    Hope this helps.

  • RaviKashyap Profile Picture
    55,410 Moderator on at

    Thanks Aric. So you used custom web template and not the out of box "web form" page template? IOut of box "Web Form" template is using redirect page to "~/Pages/WebForm.aspx"

  • Verified answer
    Aric Levin - MVP Profile Picture
    30,190 Moderator on at

    HI Ravi,

    We have a Web Page, which contains a Web Form.

    The Web Page references a Page Template and that references a custom developed Web Template.

    The Web Template contains the liquid code that validates the step id.

    If the step Id is not empty, it displays one thing (as previously shown in liquid code). If it is, it will display another thing.

    You can add further code to actually check the step id value so that it shows only on the particular page that you want.

    I hope this clarifies it.

  • RaviKashyap Profile Picture
    55,410 Moderator on at

    Thanks Aric.

    I was looking for this only (custom web template for web form). I will give it a try.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans