Ignore:
Timestamp:
2017-03-31T19:42:22+13:00 (7 years ago)
Author:
ak19
Message:
  1. gs.functions should not be declared as new Array() as its array features are not being used (and if it were an array, declare using the array literal notation =[] which is faster). gs.functions is now declared as a JavaScript object since that's how it's being used with functions getting attached to gs.functions as properties. 2. callMetadataServer and helper functions are now getting attached to the gs.functions object by being declared as gs.functions.callMetadataServer, instead of being global functions attached to the browser window object. 3. Similarly, user_comments.js attaches its functions to gs.usercomments rather than leaving them global as before.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/default/transform/layouts/usercomments.xsl

    r31557 r31558  
    4848      </div>
    4949     
    50       <input type="submit" id="usercommentSubmitButton" onclick="addUserComment(document.AddUserCommentForm.username.value, document.AddUserCommentForm.comment.value, document.AddUserCommentForm.d.value, document); return false;"><xsl:attribute name="value"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'usercomments.submit')"/></xsl:attribute></input>
     50      <input type="submit" id="usercommentSubmitButton" onclick="gs.usercomments.addUserComment(document.AddUserCommentForm.username.value, document.AddUserCommentForm.comment.value, document.AddUserCommentForm.d.value, document); return false;"><xsl:attribute name="value"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'usercomments.submit')"/></xsl:attribute></input>
    5151      <label id="usercommentfeedback"><xsl:comment>Text to prevent empty tags from becoming self-closing tags</xsl:comment></label>
    5252
Note: See TracChangeset for help on using the changeset viewer.