Uploaded image for project: 'JSPWiki'
  1. JSPWiki
  2. JSPWIKI-373

jspwiki-edit.js: sign - Date (25 Sep 07) is a hard coded string in javascript-file

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: 2.6.3, 2.8
    • Fix Version/s: 2.8
    • Component/s: Editors
    • Labels:
      None
    • Environment:

      All platforms and browsers

      Description

      ,sign:

      {snippet:["\\\\\n--",Wiki.UserName+", 25 Sep 07","\n"],tab:[Wiki.UserName,"25 Sep 07",""]}

      25 Sep 07 is hard coded

      Solution:

      var now = new Date();
      var day = ((now.getDate() < 10) ? "0" + now.getDate() : now.getDate())
      var month = ((now.getMonth() < 10) ? "0" + now.getMonth() : now.getMonth())
      var currentDate = now.getFullYear() + "" + month + "" + day;

      ,sign:

      {snippet:["\\\\\n--",Wiki.UserName+", " + currentDate,"\n"],tab:[Wiki.UserName,currentDate,""]}

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              bohni Stefan Bohn
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: