1ef45efc620ac70282b5db7b38e62be226c37cd5
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

1) #!/usr/bin/env wml
Runa A. Sandvik list available languages /...

Runa A. Sandvik authored 13 years ago

2) #use "functions.wmi"
3) 
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

4)     <div id="footer">
Sebastian Hahn de-xhtmlify more stuff

Sebastian Hahn authored 13 years ago

5)     	<div class="onion"><img src="$(IMGROOT)/onion.jpg" alt="Tor"></div>
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

6)       <div class="about">
Andrew Lewman update phone number across...

Andrew Lewman authored 11 years ago

7)     <p>"Tor" and the "Onion Logo" are registered trademarks of
8)     <a href="<page docs/trademark-faq>">The Tor Project, Inc.</a>
9)     Content on this site is licensed under a <a
10)     href="http://creativecommons.org/licenses/by/3.0/us/">Creative
11)     Commons Attribution 3.0 United States License</a>, unless
12)     otherwise noted.</p>
Andrew Lewman move the svn-based info int...

Andrew Lewman authored 13 years ago

13) <!--
Sebastian Hahn Grab the last modified date...

Sebastian Hahn authored 12 years ago

14)         # This will grab the date from svn info/git
15)         # REQUIRES svn or git for this to work
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

16)         <:{
Sebastian Hahn Grab the last modified date...

Sebastian Hahn authored 12 years ago

17)           my $svninfo = `svn info 2>/dev/null`;
18)           my $modifydate;
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

19)           if ($svninfo =~ m/Last Changed Date: (\d{4}-\d{2}-\d{2})\s(\d{2}:\d{2}:\d{2})\s(.*)\s\((.*)\)/) {
Sebastian Hahn Grab the last modified date...

Sebastian Hahn authored 12 years ago

20)             $modifydate = "$4 $2 $3";
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

21)             # remove commas from date
22)             $modifydate =~ s/,//;
Sebastian Hahn Grab the last modified date...

Sebastian Hahn authored 12 years ago

23)           } else {
24)             $modifydate = `git log --format=%cd -n 1`
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

25)           }
Sebastian Hahn Grab the last modified date...

Sebastian Hahn authored 12 years ago

26)           print 'Last modified: '.$modifydate."\n";
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

27)         }:>
28)         <:{
29)           #my $compiledate = `date`;
30)           my $compiledate = `date +"%a %b %d %Y %k:%M:%S %z"`;
31)           print 'Last compiled: '.$compiledate."\n";
32)         }:>
Andrew Lewman move the svn-based info int...

Andrew Lewman authored 13 years ago

33) -->
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

34)       </div>
35)       <!-- END ABOUT -->
36)       <div class="col first">
37)       	<h4>About Tor</h4>
38)         <ul>
Andrew Lewman fix up the info blurb, upda...

Andrew Lewman authored 13 years ago

39)           <li><a href="<page about/overview>">What Tor Does</a></li>
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

40)           <li><a href="<page about/torusers>">Users of Tor</a></li>
41)           <li><a href="<page about/corepeople>">Core Tor People</a></li>
42)           <li><a href="<page about/sponsors>">Sponsors</a></li>
43)           <li><a href="<page about/contact>">Contact Us</a></li>
44)         </ul>
45)       </div>
46)       <!-- END COL -->
47)       <div class="col">
48)       	<h4>Get Involved</h4>
49)         <ul>
50)           <li><a href="<page donate/donate>">Donate</a></li>
Andrew Lewman update phone number across...

Andrew Lewman authored 11 years ago

51)           <li><a href="<page docs/documentation>#MailingLists">Mailing Lists</a></li>
Andrew Lewman link to the right mirror page

Andrew Lewman authored 13 years ago

52)           <li><a href="<page getinvolved/mirrors>">Mirrors</a></li>
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

53)           <li><a href="<page docs/hidden-services>">Hidden Services</a></li>
54)           <li><a href="<page getinvolved/translation>">Translations</a></li>
Andrew Lewman comment out careers in the...

Andrew Lewman authored 12 years ago

55) #          <li><a href="<page getinvolved/open-positions>">Careers</a></li>
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

56)         </ul>
57)       </div>
58)       <!-- END COL -->
59)       <div class="col">
60)       	<h4>Documentation</h4>
61)         <ul>
62)           <li><a href="<page docs/tor-manual>">Manuals</a></li>
63)           <li><a href="<page docs/documentation>">Installation Guides</a></li>
Andrew Lewman remove the glossary. fix up...

Andrew Lewman authored 13 years ago

64)           <li><a href="<wiki>">Tor Wiki</a></li>
Andrew Lewman link the static faq page in...

Andrew Lewman authored 13 years ago

65)           <li><a href="<page docs/faq>">General Tor FAQ</a></li>
Andrew Lewman first cut of the new, shiny...

Andrew Lewman authored 13 years ago

66)         </ul>
67)       </div>
68)       <!-- END COL -->
Runa A. Sandvik list available languages /...

Runa A. Sandvik authored 13 years ago

69) 
Andrew Lewman remove the newsletter cruft...

Andrew Lewman authored 11 years ago

70) #	<!-- List available languages -->
71) #	<div class="col wider">
72) #	<h4>Languages</h4>
73) #	<: if (has_translations()) {  :>
74) #		<p>
75) #		This page is also available in the following languages:
76) #		<: print list_translations() :>.<br />
77) #		How to set <a href="http://www.debian.org/intro/cn#howtoset">the default document language</a>.
78) #		</p>
79) #	<: }; :>
80) #	</div>
Runa A. Sandvik list available languages /...

Runa A. Sandvik authored 13 years ago

81) 
Andrew Lewman comment out careers in the...

Andrew Lewman authored 12 years ago

82) # LANGUAGE SWITCH CGI 
83) #      <div class="col wider">
84) #      	<h4>Languages</h4>
85) #        # this is a cgi trampoline to bounce us to the right page
86) #        # alternately, if the client supports javascript we can redirect that way
87) #        # noscript does not block onclick but clients may have disabled javascript completely
88) #        #
89) #        # for this to work we need to know the relative path from the document root
90) #        # to the current directory that wml is in. 
91) #        <form action="$(DOCROOT)/cgi-bin/languageswitch.cgi">
92) #          <select name="Language" id="lang">
93) #          <:{
94) #            #import "perl-globals.wmi";
95) #            use Cwd;
96) #            use Cwd 'abs_path';
97) #            use File::Spec;
98) #            my $urlbase = File::Spec->abs2rel(getcwd(),abs_path("$(DOCROOT)"));
99) #            my $LANGUAGES;
100) #            my $page = $WML_SRC_FILENAME;
101) #            opendir(DIR, getcwd()) or die $!;
102) #            # take a look and see what language support we have
103) #            while (my $file = readdir(DIR)) {
104) #                if (-d $file) {
105) #                    if (-e "$file/$page") {
106) #                        my $url = $urlbase.'/'.$WML_SRC_BASENAME.'.html.'.$file;
107) #                        my $url2js = $WML_SRC_BASENAME.'.html.'.$file;
108) #                        print '<option value="'.$url.'" onclick="window.location=\''.$url2js.'\'">'.$LANGUAGES{$file}.'</option>'."\n" unless not defined $LANGUAGES{$file};
109) #                    }
110) #                }
111) #            }
112) #            closedir(DIR);
113) #          }:>
114) #          </select>
115) #          <input class="go" type="submit" name="submit" value="Go">
116) #        </form>
117) #        <p>Questions on this? Visit <a href="http://www.debian.org/intro/cn#howtoset">how to set the default document language</a>.</p>
118) #      </div>
119) #