Skip to main content
October 16, 2011
Question

'Mail to' link with topic URL in Subject line?

  • October 16, 2011
  • 2 replies
  • 1847 views

On Peter Grainge's site, snippet 38 gives the code for e-mailing a link to a topic.

Before I go off in the wrong direction, is there any reason why I wouldn't be able to modify the code to capture the topic URL in the Subject line rather than in the body?

My intention is to create a "Feedback" button on the skin toolbar that would generate an e-mail to the Help content authors. In the body of the e-mail I would have the text "Please type your feedback here."

    This topic has been closed for replies.

    2 replies

    October 17, 2011

    So far I have not been able to make this work. Using the skin editor, I am trying to paste the Mailto code into the "On click" property for a button. I've got it working when the topic URL is to be displayed in the body, but not when the same code is inserted into the Subject.

    Has anyone seen a worked example I could steal learn from?

    Here's the working version of the "On click" action with the topic URL captured in the body --

    How would this be modified to capture the topic URL in the Subject line?

    Willam van Weelden
    Inspiring
    October 17, 2011

    Hi,

    See my Toolbar scripts: http://www.wvanweelden.eu/robohelp/toolbarscripts

    Replace line 59 with: window.location = "mailto:&subject="+title+" "+escape(url)+"&body="+message+"\n"+title+": "+escape(url);

    That should work the way you want.

    Greet,

    Willam

    October 18, 2011

    Is it possible to do the same thing using an in-line script rather than a stored file?

    BTW, IE crashes when I open your Web page and click the script.

    Peter Grainge
    Community Expert
    Community Expert
    October 16, 2011

    With anything like this the answer is to create a small test project with just a few topics and see what happens. If it messes up, no harm done to your project.

    One thing I would be checking is whether the link is clickable in the subject line. If it is not, it means the recipient has got to cut and paste it into a browser rather than just click it.


    See www.grainge.org for RoboHelp and Authoring tips

    @petergrainge

    Use the menu (bottom right) to mark the Best Answer or Highlight particularly useful replies. Found the answer elsewhere? Share it here.
    October 17, 2011

    Thanks Peter. In this scenario, the recipient will be the content author, so there will probably seldom be a need to open the topic from the server. The topic name will tell the content author where to go in the project source to find whatever it is that the feedback pertains to.