Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??

Here is the start of the Gentle Feedback Free Nodelet Hack

Untested, but I'm pretty sure I got the magic strings right

<script language="javascript" type="text/javascript"> <!--// var TehGentleFeedback = function() { if( document.getElementById("Gentle-Feedback-Popup") !== null ){ /* single instance checker */ return; } String.prototype.escapeHTML = function(){ var result = ""; for(var i = 0; i < this.length; i++){ if(this.charAt(i) == "&" && this.length-i-1 >= 4 && this.substr(i, 4) != "&amp;"){ result = result + "&amp;"; } else if(this.charAt(i)== "<"){ result = result + "&lt;"; } else if(this.charAt(i)== ">"){ result = result + "&gt;"; } else { result = result + this.charAt(i); } } return result; }; var IQ = function IQ(msg){ msg = "/msg `[`author_title\``] " + msg; var ret = ''; ret += '<form method="post" action="?" enctype="multipart/form +-data">'; ret += '<input name="op" type="hidden" value="message">'; ret += '<input name="node_id" type="hidden" value="`id`">'; ret += '<input name="message" type="hidden" value="' + msg +'" +>'; ret += '<input type="submit" value="send">'; ret += msg.escapeHTML(); ret += '</form>' return ret; }; var SURVEY = function(){ return 'shabba' }; var p = document.createElement("p"); var ret = '<div id="Gentle-Feedback-Popup" style="padding: 1em 1em + 1em 1em; background:white;border:5px red dashed; position: fixed; le +ft:120px; top:20px; z-index:3; display: block; visibility: visible; w +idth:80%; " >'; ret += '<button style="width:100%" onclick="this.parentNode.parent +Node.parentNode.removeChild(this.parentNode.parentNode);">Close</butt +on><hr>'; ret += "<p>Gentle Feedback <p> Instant Quicky <p> "; ret += IQ("Regarding [`id`|`title\`], title ok, enough information + provided, formatting acceptable, nice job "); ret += IQ("Regarding [`id`|`title\`], blah blah blah"); ret += IQ("Hello"); ret += "<hr>" + SURVEY(); ret += '<hr> <button style="width:100%" onclick="this.parentNode.p +arentNode.parentNode.removeChild(this.parentNode.parentNode);">Close< +/button>'; ret += "</div>"; p.innerHTML = ret; document.body.appendChild(p); return; }; //--> </script> <a href='javascript:TehGentleFeedback()'>TehGentleFeedback()</a>

For the magic strings refer to

I ran out of steam for SURVEY , implement as you see fit

In reply to Re: Approval feedback (Gentle Feedback Free Nodelet Hack) by Anonymous Monk
in thread Approval feedback by cavac

Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":

  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?

    What's my password?
    Create A New User
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others chanting in the Monastery: (4)
    As of 2021-05-07 21:38 GMT
    Find Nodes?
      Voting Booth?
      Perl 7 will be out ...

      Results (95 votes). Check out past polls.