0

I have a modal component which is basically a popup with some content in it. I have to ask if it is possible to link that component from another component.

For example I have anchor link in another component and by clicking the link, it will call the modal component and popup will be shown on that page.

Or i have a Richtext editor with an anchor link?

Is it possible to call modal component when a link in the Richtext editor is clicked? Lets say there is a See more link inside the Richtext editor. On clicking the link, it will call the Modal component.

I was thinking if it is possible via ajax like calling the Modal Actionresult via ajax which will return the HTML and that HTML will append on the current page to show the popup

Is it possible or has someone done anything similar to this?

Any help or suggestion would be appreciated.

Thanks in advance

8
  • It is not clear to me what you are asking. you can make it in different ways, where do you get stuck? May 23, 2019 at 7:06
  • @JanBluemink I have a modal component which is a popup. in order to make it work, i need to attach a modal rendering to the item and set the datasource. Thats a normal process. But suppose i have another item with few renderings and one of the rendering is a content rendering which has anchor link. So I need to call Modal component from that anchor link. Lets say the content component has Read More anchor link on clicking the link, it will call the modal rendering and modal popup will appear on the page.
    – user2980
    May 23, 2019 at 8:20
  • similarly I can have a link inside a rich text editor . Suppose it is a See more link inside the richtext editor and clicking the link will call the Modal component and a popup will appear on the page.
    – user2980
    May 23, 2019 at 8:23
  • Is it the front end code, javascript you need help with? May 23, 2019 at 8:24
  • well i was thinking to use Javascript but not sure how it will work. May be a ajax call to the Modal Actionresult which will return the HTML and that HTML will be called on the current page. I dont know if this will work
    – user2980
    May 23, 2019 at 8:27

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.