2

If my server is at example.com, running

$ wget example.com

will only download the file index.html. How can I make wget either

  • download another file instead of index.html
  • download this file along index,html

I have all redirection I could find pubkey.asc is my file):

  1. <meta http-equiv="Refresh" content="seconds; url=pubkey.asc "> 
    
  2.  <script language="javascript">
    window.location.href = "http://example.com"
    

  3. <link rel="canonical" href="pubkey.asc"/>
    
  4. <script> document.location.href="pubkey.asc";</script>
    
  5. <script>window.location.href='pubkey.asc';</script>

  6. <meta http-equiv="refresh" content="0; url=pubkey.asc" />
    


PS: I am posting here instead of web.stackexchange since wget mechanism is involved.

user123456
  • 563
  • 1
  • 7
  • 20

1 Answers1

1
<!DOCTYPE html>
<head>
<meta http-equiv="refresh" content="0;URL=pubkey.asc">
</head>
<body>
</body>
</html>

Combined with wget -r http://example.com

downloads both index.html and pubkey.asc

user993553
  • 429
  • 3
  • 8