DNN Forums

Ask questions about your website to get help learning DNN and help resolve issues.

url link direct to a module on a page.

Sort:
You are not authorized to post a reply.





Growing Member





    Hi

    Have three modules on a page, want to give an external url link that takes a user direct to a specififed module in the page. Prefer not to split modules accross three pages. DNN version 9x 

    Found a solution using hashtags # on the old community but doesn't seem to work.

    Any suggestions?

    thanks

     






    Veteran Member





      Ken,

      This link does exacty that for this page to go to your post:

      https://dnncommunity.org/forums/aft/1253#1253

      Just inspect the source code and find something like

      <_a name="1253"_><_/a_>
      
      

      at the begin of the module.

      Happy DNNing!
      Michael

      Michael Tobisch
      DNN★MVP

      dnnWerk Austria
      DNN Connect





      Growing Member





        Hi Michael
        Looking at the HTML in browser's developer panel, and on the page the closest I can find is this:

        </script>
        <!-- Start_Module_432 -->


            

                

        Lorem ipsum dolor sit amet, consectetuer adi............

        searching doesnt find it either so I am missing something I think.

        Ken






        Growing Member





          You can always add your own tag with an ID to the module header. It has the advantage that your URLs would be much more recognizable.

          In the module header add this

           

          [div id="MyContentName"][/div]

          *substitute < for each [ and > for each ]

          Then you can add #MyContentName to the end of the URL.

           






          Growing Member





            Thanks Mark

            The advantage of this is I can use my own naming for the tag, yes will look better on the url.

            My problem now is I dont do code, so both solutions are risky for me. 

            I had a look using the module's developer tab but my going-in is dangerous for the portal's well being. 

            Could you give me a 'learner driver' step by step for adding this to a module header?

            Ken

             






            Growing Member





              Ken, a video would be better, right? Have a look at this video: https://www.youtube.com/watch?v=32fVEDRkFmw
              Start at 1:06 minutes in and watch until 2:40 minutes. That shows you how to add an anchor tag with a name to the module header. I know I suggested a div tag with an id, but you can use either method equally well with the same results.





              Growing Member





                Thank you both, the thing I like about DNN compared with others is you can be lateral about problem solving (as a non coder I add).

                I was confusing the file/code level header with the modeul level Header settings panel.

                So, add HTML to a module settings panel Header panel and it works, so far anyway, with three modules on a page.



                https://portal4members.az...ture-Workplace#needs

                The video was good as it gave me the clue, tho version 9x editor does not show the anchor and there is no navigation in my theme.

                thank you for the help, appreciated.

                Ken






                Veteran Member





                  Ken,

                  this is quite easy, and as long as the bookmarks are unique, there is no risk at all. Just go int the module settings and add the following HTML tags into the field "Header" (on the first tab, under "Advanced Settings"):

                  [div][a name="MyBookmark"][/a][div]
                  
                  

                  (Replace square brackets by the appropriate angle brackets, I have to write it this way because otherwise the forum editor would swallow the stuff)

                  Then you get an Url like www.myserver.com/PageName#MyBookmark. As said before, give the bookmarks unique names.

                  Note: When there is something in the Header field of the module, there will be a warning in the Security Advisor. You can just ignore this in these cases.

                  Happy DNNing!
                  Michael

                  Michael Tobisch
                  DNN★MVP

                  dnnWerk Austria
                  DNN Connect





                  Growing Member





                    Hi

                    thanks both for your help, the video was useful though not version 9x editor!

                    With some experimentation by adding this HTML to the module settings Header panel, it worked.

                    [ul]
                    [a name="employment"][/a]
                    [li]< [href="#employment" ] [ /a ] li]     [ul]

                    < and ] swapped e

                    so the url       https://portal4members.az...orkplace#needs     works going straight to the moduel anchor.

                    I was looking at the code level header and didnt realise you can add HTML at the module header level.

                    Ken

                     

                     

                    You are not authorized to post a reply.

                    These Forums are dedicated to the discussion of DNN Platform.

                    For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

                    1. If you have (suspected) security issues, please DO NOT post them in the forums but instead follow the official DNN security policy
                    2. No Advertising. This includes the promotion of commercial and non-commercial products or services which are not directly related to DNN.
                    3. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
                    4. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
                    5. No Flaming or Trolling.
                    6. No Profanity, Racism, or Prejudice.
                    7. Site Moderators have the final word on approving / removing a thread or post or comment.
                    8. English language posting only, please.

                    Would you like to help us?

                    Awesome! Simply post in the forums using the link below and we'll get you started.

                    Get Involved