Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 994291
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T06:33:09+00:00 2026-05-16T06:33:09+00:00

I found the following code to decode a ROT13 string and put it into

  • 0

I found the following code to decode a ROT13 string and put it into a webpage with JavaScript:

<script type="text/javascript">
 document.write("string".replace(/[a-zA-Z]/g, 
 function(c){return String.fromCharCode((c<="Z"?90:122)>=(c=c.charCodeAt(0)+13)?c:c-26);}));
</script>

I need a similar JavaScript code to decode ROT47.

I found a few functions, but I have no idea how to get it into the same script, so it will put the decoded string into a webpage.

One of them is here – http://www.visualco.de/ROTn.js.html

Can someone please help?

Thanks a lot!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T06:33:09+00:00Added an answer on May 16, 2026 at 6:33 am

    Simply copy the needed functions into your JavaScript. At the appropriate place, do

    <script type="text/javascript">
     document.write(ROT47("string"));
    </script>
    

    necessary functions:

    //
    // ROTn.js -- ROT13 and ROT14
    //
    // JavaScript-code   implementing   ROT13  and   ROT47.    Useful  to   obscure
    // email-adresses and telephone numbers from inquisitorial site crawlers.
    //
    // Usage:
    //   <script type="text/javascript">
    //     ROT13('<n uers="znvygb:vasb@ivfhnypb.qr">vasb@ivfhnypb.qr</n>');
    //   </script>
    //
    // Resources:
    //     http://de.wikipedia.org/wiki/ROT13
    //     http://www.drweb.de/magazin/codieren-und-verschlusseln-mit-javascript/
    //
    ////////////////////////////////////////////////
    // (C) 2010 Andreas  Spindler. Permission to use, copy,  modify, and distribute
    // this software and  its documentation for any purpose with  or without fee is
    // hereby  granted.   Redistributions of  source  code  must  retain the  above
    // copyright notice and the following disclaimer.
    //
    // THE SOFTWARE  IS PROVIDED  "AS IS" AND  THE AUTHOR DISCLAIMS  ALL WARRANTIES
    // WITH  REGARD   TO  THIS  SOFTWARE   INCLUDING  ALL  IMPLIED   WARRANTIES  OF
    // MERCHANTABILITY AND FITNESS.  IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
    // SPECIAL,  DIRECT,   INDIRECT,  OR  CONSEQUENTIAL  DAMAGES   OR  ANY  DAMAGES
    // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
    // OF  CONTRACT, NEGLIGENCE  OR OTHER  TORTIOUS ACTION,  ARISING OUT  OF  OR IN
    // CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
    // 
    // $Writestamp: 2010-06-09 13:07:07$
    // $Maintained at: www.visualco.de$
    
    function ROTn(text, map) {
      // Generic ROT-n algorithm for keycodes in MAP.
      var R = new String()
      var i, j, c, len = map.length
      for(i = 0; i < text.length; i++) {
        c = text.charAt(i)
        j = map.indexOf(c)
        if (j >= 0) {
          c = map.charAt((j + len / 2) % len)
        }
        R = R + c
      }
      return R;
    }
    
    function ROT47(text) {
      // Hides all ASCII-characters from 33 ("!") to 126 ("~").  Hence can be used
      // to obfuscate virtually any text, including URLs and emails.
      var R = new String()
      R = ROTn(text,
      "!\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~")
      return R;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I found the following code to create a tinyurl.com url: http://tinyurl.com/api-create.php?url=http://myurl.com This will automatically
I was reading a book on templates and found the following piece of code:
According to what I have found so far, I can use the following code:
I was just reviewing some old code and found the following (inside foo.asp): Const
Following the JSONRequest proposa l, I've found code for the JSONRequest object . However,
Found the following in an Oracle-based application that we're migrating (generalized) : SELECT Table1.Category1,
I found the following rather strange. Then again, I have mostly used closures in
I'm converting an application to use Java 1.5 and have found the following method:
following the wealth of information found here how can we get an external .config
Maybe someone found a workaround for the following problem: It seems as if AXIS

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.