Coastal & Marine Geology InfoBank

Home FACS Activities Atlas Geology School Related Sites More

USGS InfoBank program -- dates2html

Skip navigational links
Loading
InfoBank Programs: by Name   by Topic  
Expanded Description
Topic Description
Name
dates2html
Synopsis
/infobank/programs/html/dates2html/dates2html.for
Description
  Program to generate list of days for an activity.

       
AUTHOR
  Clint Steele        7/26/01

  modified
  Sumy Tom			8/30/09

    
Reads
          read (90, '(a7,t10,i2,1x,i2,1x,i4,
     *                t25,i3,
     *                t34,i2,1x,i2,1x,i4,
     *                t49,i3)', end = 99)
     *        ID, 
     *        StartMonth, StartDay, StartYear,
     *        StartJDay, 
     *        EndMonth, EndDay, EndYear,
     *        EndJDay
          read (92, '(i4.4,1x,i2.2,1x,i2.2,1x,i3.3,1x,
     *                i4.4,1x,i2.2,1x,i2.2,1x,i3.3,1x,q,a)',
     *                end = 999)
     *                StartYear,
     *                StartMonth, 
     *                StartDay,
     *                StartJDay,
     *                EndYear,
     *                EndMonth, 
     *                EndDay,
     *                EndJDay,
     *                IDLength,
     *                ID(1:IDLength)
              read (65, '(q,a)', end = 6599)
     *            IDsLinkLength, IDsLink(1:IDsLinkLength)
      read (90, '(t36,i4)', end = 99) FirstYear
          read (90, '(t36,i4)', end = 99) LastYear
Writes
              write (91, '(i4.4,1x,i2.2,a,i2.2,1x,i3.3,1x,
     *                     i4.4,1x,i2.2,a,i2.2,1x,i3.3,1x,a)')
     *                StartYear,  
     *                StartMonth, '/', 
     *                StartDay, 
     *                StartJDay,
     *                EndYear,
     *                EndMonth, '/',
     *                EndDay,
     *                EndJDay,
     *                ID(1:IDLength)
              write (91, '(i4.4,1x,a,1x,
     *                     i4.4,1x,i2.2,a,i2.2,1x,i3.3,1x,a)')
     *                EndYear,
     *                '01/01 001', 
     *                EndYear,
     *                EndMonth, '/',
     *                EndDay,
     *                EndJDay,
     *                ID(1:IDLength)
              write (91, '(i4.4,1x,i2.2,a,i2.2,1x,i3.3,1x,
     *                     i4.4,1x,a,1x,i3.3,1x,a)')
     *                StartYear,  
     *                StartMonth, '/', 
     *                StartDay, 
     *                StartJDay,
     *                StartYear,  
     *                '12/31',
     *                YearLength,
     *                ID(1:IDLength)
                  write (94, '(12x,a,/)') '</tabl
                  write (94, '(10x,a)') '</t
                  write (94, '(8x,a)') '</t
                  write (94, '(6x,a,/)') '</tabl
                  write (94, '(/,6x,a,/)') '<br 
                  write (94, '(6x,a,/,6x,a,/,6x,a)')
     *                '<div class="quote"
     *                'Time is nature''s way of making sure that '//
     *                'everything doesn''t happen at once.',
     *                '</di
              write (OutDate, '(i4.4)') CurrentYear
              write (94, '(/,a,/)') '<br 
              write (94, '(a)') '<di
              write (94, '(2x,a)') '<table class="info" width="600
              write (94, '(4x,a)') '<t
              write (94, '(6x,a)') '<t
              write (94, '(8x,a)') 'This provides year/date-based '//
     *                            'access to Field Activity metadata '//
     *                             'and data.'
              write (94, '(10x,a)') '<u
              write (94, '(12x,a)') '<l
              write (94, '(14x,a)') 'Activity IDs are listed '//
     *                              'chronologically from the day '//
     *                              'the activity started.'
              write (94, '(12x,a)') '</li>&
              write (94, '(12x,a)') '<l
              write (94, '(14x,a)') 'When the starting date of the '//
     *                               'Field Activity is unknown, the '//
     *                               'first day of the year is used.'
              write (94, '(12x,a)') '</li><br />'  
              write (94, '(10x,a)') '</ul&
              write (94, '(6x,a)') '</t
              write (94, '(6x,a)') '<t
              write (94, '(6x,a)')
     *            '<img src = "http://walrus.wr.usgs.gov/
     *            'infobank/programs/html/training/IBDemo/'//
     *            'rawjpg/ByYear.jpg" alt = "Year" width = "150"/>'           
              write (94, '(6x,a)') '</td>'        
              write (94, '(4x,a)') '</t
              write (94, '(2x,a)') '</tabl
              write (94, '(a)')'</di
              write (94, '(/,a,/)') '<br 
              write (94, '(a)') '<di
              write (94, '(6x,a)') 
     *         '<table class="noborder">  <!-- tab
              write (94, '(8x,a)') '<t
              write (94, '(10x,a)') '<td width="5%
          write (HyphenID, '(10x)')
          write (Link, '(512x)')
          write (Link, '(a)')
     *        '/infobank/'//
     *        ID(1:1)//
     *        '/'//
     *        ID(1:IDLength)//
     *        '/meta/'//
     *        HyphenID(1:IDLength+3)//
     *        '.ids'
          write (94, '(14x,a)') '<t
              write (94, '(16x,a,i2.2,a,i2.2,a,i2.2,a,i2.2,a,/)')
     *            '<td class="white"
     *            StartMonth,'/',StartDay,'-',
     *            EndMonth,'/',EndDay,
     *            '</t
              write (94, '(16x,a,i2.2,a,i2.2,a,i2.2,a,i2.2,a,/)')
     *            '<td class="light"
     *            StartMonth,'/',StartDay,'-',
     *            EndMonth,'/',EndDay,
     *            '</td&g
          write (94, '(16x,a)') '<t
          write (94, '(18x,a,i3.3,a)')
     *    '<table class="border" rules="all" width
     *    YearLength,'> <!-- table 
          write (94, '(20x,a)') '<t
              write (94, '(22x,a,i,a)')
     *            '<td width=
     *            StartJDay-1,
     *           '"> <
              write (94, '(22x,a,i,a)')
     *            '<td width=
     *            EndJDay-StartJDay+1,
     *            '" bgcolor="#ffffff">
     *            ' </t
              write (94, '(22x,a,i,a)')
     *            '<td class="dark" width=
     *            EndJDay-StartJDay+1,
     *            '"> <
              write (94, '(22x,a,i,a)')
     *            '<td width=
     *            YearLength-EndJDay+1,
     *            '"> <
          write (94, '(20x,a)') '</t
          write (94, '(18x,a)') '</table>  <!-- tab
          write (94, '(16x,a,/)') '</t
         write (94, '(16x,a)') '<td class="light
                  write (94, '(18x,a)') 
     *            '<strong&
     *            IDsLink(30:IDsLinkLength)//
     *            '</stron
                  write (94, '(18x,a)')
     *            '  '//
     *            IDsLink(30:IDsLinkLength)
          write (94, '(16x,a)') '</t
          write (94, '(16x,a)') '<t
          write (94, '(18x,a)') 
     *        '<table class="noborder"> <!-- tab
          write (94, '(20x,a)') '<t
          write (94, '(22x,a)') '<t
              write (94, '(24x,a)')
     *                   '<a href="http://walrus.wr.usgs.gov
     *                   '/infobank/'//LowercaseID(1:1)//'/'//
     *                    LowercaseID(1:IDLength)//'/html/'//
     *                    LowercaseHyphenID(1:IDLength+3)//
     *                    '.index.png">'//
     *                    '<img src="http://walrus.wr.usgs.gov
     *                     ResizedIndex(1:ResIndexLength)//
     *               '" alt = "thumbnail map" width="75"></a>
                   write (94, '(24x,a)')
     *                '<a href="http://walrus.wr.usgs.gov
     *                '/infobank/'//LowercaseID(1:1)//'/'//
     *                 LowercaseID(1:IDLength)//'/html/'//
     *                LowercaseHyphenID(1:IDLength+3)//
     *                '.nav.jpg">
     *                '<img src="http://walrus.wr.usgs.gov
     *                 ResizedJpg(1:ResJpgLength)//
     *               '" alt = "thumbnail map" width="75">
     *                 '</a>&
          write (94, '(22x,a)') '</t
          write (94, '(22x,a)') '<td align="center
            write (94, '(24x,a)') 
     *        '<a href="http://walrus.wr.usgs.gov
     *        '/infobank/'//LowercaseID(1:1)//'/'//
     *        LowercaseID(1:IDLength)//'/kml/'//
     *        LowercaseHyphenID(1:IDLength+3)//'.nav.kmz"&g
            write (94, '(24x,a)')
     *        '<img src="http://walrus.wr.usgs.gov
     *        '/infobank/programs/html/tools/googleearth.jpg" '//
     *        'alt="Google Earth icon" width="12" border="0">&l
            write (94, '(24x,a)') '<br 
            write (94, '(24x,a)')
     *        '<a href="http://maps.google.com/maps?q=
     *        'http://walrus.wr.usgs.gov'//
     *        '/infobank/'//LowercaseID(1:1)//'/'//
     *        LowercaseID(1:IDLength)//'/kml/'//
     *        LowercaseHyphenID(1:IDLength+3)//'.nav.kmz'//
     *        '&t=h" target="new"&g
            write (94, '(24x,a)')
     *        '<img src="http://walrus.wr.usgs.gov
     *        '/infobank/programs/html/tools/googlemaps.jpg" '//
     *        'alt="Google Maps icon" width="12" border="0">&l
          write (94, '(22x,a)') '</t
          write (94, '(20x,a)') '</t
          write (94, '(18x,a)') '</table>  <!-- table 5
          write (94, '(16x,a)') '</t
          write (94, '(14x,a,/)') '</t
      write (94, '(12x,a,/)') '</tabl
      write (94, '(10x,a)') '</t
      write (94, '(8x,a)') '</t
      write (94, '(6x,a,/)') '</tabl
      write (94, '(6x,a)') '<br 
      write (94, '(6x,a,/,6x,a,/,6x,a)')
     *    '<div class="quote"
     *    'Time is nature''s way of making sure that '//
     *    'everything doesn''t happen at once.',
     *    '</di
      write (94, '(12x,a)') 
     *    '<table class="border" rules="all">  <!-- tab
      write (94, '(14x,a)') '<t
      write (94, '(16x,a,/)') 
     *  '<th align="center" class="dark"&
     *           'Dates</th
      write (94, '(16x,a)') '<t
      write (94, '(18x,a,i3.3,a)') 
     *   '<table class="border" rules="cols" bgcolor="#ccffff" width
     *   YearLength,'>  <!-- table 
      write (94, '(20x,a)') '<t
      write (94, '(22x,a)') 
     *  '<td class="dark" width="31" align="center">J
      write (94, '(22x,a,i2.2,a)') 
     *  '<td class="dark" width="', YearLength - 3
     *    '" align="center">F<
      write (94, '(22x,a)') 
     *  '<td class="dark" width="31" align="center">M
      write (94, '(22x,a)') 
     *  '<td class="dark" width="30" align="center">A
      write (94, '(22x,a)') 
     *  '<td class="dark" width="31" align="center">M
      write (94, '(22x,a)') 
     *  '<td class="dark" width="30" align="center">J
      write (94, '(22x,a)') 
     *  '<td class="dark" width="31" align="center">J
      write (94, '(22x,a)') 
     *  '<td class="dark" width="31" align="center">A
      write (94, '(22x,a)') 
     *  '<td class="dark" width="31" align="center">S
      write (94, '(22x,a)') 
     *  '<td class="dark" width="31" align="center">O
      write (94, '(22x,a)') 
     *  '<td class="dark" width="30" align="center">N
      write (94, '(22x,a)') 
     *  '<td class="dark" width="31" align="center">D
      write (94, '(20x,a)') '</t
      write (94, '(18x,a)') '</table>  <!-- tab
      write (94, '(16x,a,/)') '</t
      write (94, '(16x,a)') 
     *  '<th class="dark" align = "center"> Activity Page 
      write (94, '(16x,a)') 
     *  '<th class="dark" align = "center"> GE/kmz Maps 
      write (94, '(14x,a,/)') '</t
      write (94, '(2x,a)') '<t
      write (94, '(4x,a)') 
     *    '<td valign="top" align="right" width="10%
      write (94, '(6x,a)') '<b>Year
      write (94, '(4x,a,/)') '</t
      write (94, '(4x,a)') '<td valign="middle
          write (AYear, '(i4.4)') Year
              write (94, '(6x,a,i2.2,a)')
     *            '<a href="http://walrus.wr.usgs.gov
     *            '/infobank/programs/html/dates2html'//
     *            '/'//AYear//'.html">',ShortYear,'</a>
      write (94, '(4x,a)') '</t
      write (94, '(2x,a,/)') '</t
Opens
      open (unit = 90,
     *      access = 'sequential',
     *      form = 'formatted',
     *      status = 'old',
     *      name = '/infobank/programs/keep/dates.keep')
      open (unit = 91,
     *      access = 'sequential',
     *      form = 'formatted',
     *      status = 'unknown',
     *      file = '/infobank/tmp/dates2html_days.temp')
      open (unit = 92,
     *      access = 'sequential',
     *      form = 'formatted',
     *      status = 'old',
     *      file = '/infobank/tmp/dates2html_sorted.temp')
              open (unit = 94,             ! header
     *            access = 'sequential',
     *              form = 'formatted',
     *            status = 'unknown',
     *              file = '/infobank/tmp/dates2html.part1.temp')
          open (unit = 65,
     *          access = 'sequential',
     *          form = 'formatted',
     *          status = 'unknown',
     *          name = Link(1:LinkLength))
      open (unit = 90,
     *      status = 'old',
     *      access = 'sequential',
     *      form = 'formatted',
     *      name = '/infobank/tmp/dates2html_htmllist.temp')
Calls
          call stringlen (ID, IDLength)
      call system ('/bin/sort '//
     *     '/infobank/tmp/dates2html_days.temp > 
     *     '/infobank/tmp/dates2html_sorted.temp')
      call system ('/bin/rm /infobank/tmp/dates2html_days.temp')
                  call htmlfoot (94,
     *                'http://walrus.wr.usgs.gov/'//
     *                'infobank/programs/html/'//
     *                'dates2html/'//
     *                OutDate//'.html')
                  call system ('/bin/cat '//
     *                '/infobank/tmp/dates2html.part1.temp '//
     *                '> /infobank/programs/html/
     *                'dates2html/'//OutDate//'.html')
                  call system ('/bin/rm '//
     *                '/infobank/tmp/dates2html.part*.temp')
              call htmlhead (94, 'CMG Activities by Year ('//OutDate//
     *            ')')
              call includeit (94,
     *        '/infobank/programs/html/tools/activities.tabs')
              call includeit (94,
     *        '/infobank/programs/html/tools/home.fieldwork.tabs')
              call includeit (94,
     *      '/infobank/programs/html/tools/activities.years.tabs')
      call includeit (94,
     *    '/infobank/programs/html/tools/virtualglobesstart.tabs')
      call includeit (94,
     *    '/infobank/programs/html/tools/virtualglobesend.tabs')
      call includeit (94,
     *    '/infobank/programs/html/tools/iconlegendstart.tabs')
      call includeit (94,
     *    '/infobank/programs/html/tools/virtualglobeslegend.keep')
      call includeit (94,
     *    '/infobank/programs/html/tools/iconlegendend.tabs')
              call datecontrol
      call includeit (94,
     *            '/infobank/programs/keep/contents.keep')
              call datebar (YearLength, CurrentYear)
          call stringlen (Link, LinkLength)
          call changecase ('SMALLS', Link(1:LinkLength))
          call changecase ('SMALLS', LowercaseID)
          call changecase ('SMALLS', LowercaseHyphenID)
              call stringlen (ResizedIndex, ResIndexLength)
                 call system ('/bin/cp '//
     *                        '/infobank/'//LowercaseID(1:1)//'/'//
     *                        LowercaseID(1:IDLength)//'/html/'// 
     *                        LowercaseHyphenID(1:IDLength+3)//
     *                        '.index.png '//
     *                        ResizedIndex(1:ResIndexLength))
                  call system ('mogrify -resize 150x150 '//
     *                         ResizedIndex(1:ResIndexLength)) 
                 call stringlen (ResizedJpg, ResJpgLength)
                      call system ('/bin/cp '//
     *                        '/infobank/'//LowercaseID(1:1)//'/'//
     *                        LowercaseID(1:IDLength)//'/html/'// 
     *                        LowercaseHyphenID(1:IDLength+3)//
     *                        '.nav.jpg '//
     *                        ResizedJpg(1:ResJpgLength))
                      call system ('mogrify -resize 150x150 '//
     *                         ResizedJpg(1:ResJpgLength)) 
      call htmlfoot (94,
     *                'http://walrus.wr.usgs.gov/'//
     *                'infobank/programs/html/'//
     *                'dates2html/'//
     *                OutDate//'.html')
      call system ('/bin/cat '//
     *                '/infobank/tmp/dates2html.part1.temp '//
     *                '> /infobank/programs/html/
     *                'dates2html/'//OutDate//'.html')
      call system ('/bin/rm '//
     *                '/infobank/tmp/dates2html.part*.temp')
      call system ('/bin/rm '//
     *                '/infobank/tmp/dates2html_*.temp')
      call system ('/bin/ls -1 '//
     *    '/infobank/programs/html/dates2html/????.html > 
     *    '/infobank/tmp/dates2html_htmllist.temp')

Skip footer navigational links

Coastal and Marine Science Centers:  Pacific   St. Petersburg   Woods Hole  
InfoBank   Coastal and Marine Geology Program   Geologic Information   Ask-A-Geologist   USGS Disclaimer  


Accessibility FOIA Privacy Policies and Notices

Take Pride in America logo USA.gov logo U.S. Department of the Interior | U.S. Geological Survey
URL: http://walrus.wr.usgs.gov/infobank/programs/html/dates2html/dates2html.doc.html
Page Contact Information: InfoBank staff
Page Last Modified: Thu Nov 14 03:04:09 PST 2013  (chd)