THE WELCH COMPANY
440 Davis Court #1602
San Francisco, CA 94111-2496
415 781 5700
S U M M A R Y
DIARY: May 15, 1999 11:18 AM Saturday;
Rod Welch
Revise function to create internal HTML links.
1...Summary/Objective
2...F1 F1 F7 Link Documents Based on Flag Set By F1 F1 F8
3...Develop Process
...a...Anchor Sets Flag for Linking
...b...Link Files, Internal Lines, or Templates
4...Background and Analsys
5...0704081 - Create HTML Links within Documenrts, F1 F1 F7
6...a. Link Between Files - F1 F1 F7
7...a. Templates or Linking in Same File - F1 F1 F7
.....Launch Template Operation Instead of Linking Between Files
........SDS Link Template
........Letter Link Template, Alternate
........SDS Record Link to Welchco Home Page Only - F1 F1 F7
8...c. Link Lines in Same File
.....Eliminate HTML Format for Internal Links, Use Only SDS Format
9...000008 Assign Internal Links to F1 F1 F7 when Mark 2 Set
10...0704086 F1 F1 F8 Sets Flag Assign F1 F1 F7 to Internal Link
11...000006 Linking, Don't link editor Lines with Medit Commands
..............
Click here to comment!
CONTACTS
SUBJECTS
Intranet Integration
Links, Convert SDS to HTML Standard Format
Links Create within Editor Files, 0704081
Anchor Convert to HTML
Links, Convert SDS to HTML Standard Format,
Template HTML Link to Web Address, F1 F1 F7, 0704086
1008 - ..
1009 - Summary/Objective
1010 -
101001 - Follow up ref SDS 11 0000, ref SDS 10 0000.
101002 -
101003 - Combined 0704086 into 0704081 so there is a single way to link
101004 - internally and between files. Eliminated html link code and instead
101005 - simply enter SDS link ID, which is changed to html code when a file is
101006 - converted into html by 0122.
101007 -
101008 - [On 990530 further consolidation of code eliminated functions F1
101009 - F1 F7 and F1 F1 F8. ref SDS 18 1044]
101010 -
101011 -
101012 - ..
1011 -
1012 -
1013 - Planning
1014 -
101401 - F1 F1 F7 Link Documents Based on Flag Set By F1 F1 F8
101402 -
101403 - Up until now we have had a system to click or press enter for linking
101404 - SDS records and for linking documents into SDS records.
101405 -
101406 - [On 990530 eliminated functions F1 F1 F7 and F1 F1 F8; everything
101407 - is done by Enter and F1 F6. ref SDS 18 1645]
101408 -
101409 - This requires placing the cursor at a place where a link is
101410 - wanted. Within SDS records, move to the link address, place
101411 - cursor in the line number field, and press enter or double click.
101412 -
101413 - Use Ctrl F1 to enter Mark 2 at the link location and jump to the
101414 - Reference field. Open an SDS record or a document, move to the
101415 - location for the link address and press Enter or double click.
101416 -
101417 -
101418 - F1 F1 F7 links two documents together, after flag is set by F1 F1 F8
101419 - that enters an ending html anchor code.
101420 - ..
101421 - Menu creates internal links for documents.
101422 -
101423 - These internal links have been applying full HTML code, with the
101424 - anchor, NAME and end anchor components. This is bothersome using
101425 - the files for work and editing, compared with the SDS link scheme
101426 - of using simply <nnnn.
101427 -
101428 - Today, I want to convert to a single SDS scheme <nnnn, because
101429 - 0122 converts these links to HTML. ref SDS 0 9764
101430 -
101431 - We want F1 F1 F7 to link internal documents as well as external
101432 - documents.
101433 -
101434 - F1 F1 F7 calls 0704086 for external links
101435 -
101436 - Make F1 F1 F7 also call 0704081 internal links
101437 -
101438 - ..
101439 - Looks like what we really need to do is to combine 0704081 and
101440 - 0704086 into a single routine so they can be called with a single
101441 - function.
101442 -
101443 -
101444 - Develop Process
101445 -
101446 -
101447 - [On 990530 eliminated these calls. ref SDS 18 1044]
101448 -
101449 - [Planning on 990530 is at ref SDS 18 1645.]
101450 -
101451 - F1 F1 F8
101452 - a. Anchor Sets Flag for Linking
101453 -
101454 - Sets 73 1691, ref OF 2 0294
101455 -
101456 - Enters ending anchor spec /A /B
101457 -
101458 - Sets flags for linking internally and externally.
101459 -
101460 - Enters Mark 2 to set up for linking internally.
101461 -
101462 -
101463 - F1 F1 F7
101464 - b. Link Files, Internal Lines, or Templates
101465 -
101466 - Was it called in a file where F1 F1 F8 has been set?
101467 -
101468 - Does, 73 = 1691?
101469 -
101470 - a. Yes, 73 = 1691, so either...
101471 -
101472 - Was it called on the same line as F1 F1 F8?
101473 -
101474 - 1. Yes, so enter template if called on same line as F1
101475 - F1 F8
101476 -
101477 - 2. No, create internal link to line where F1 F1 F8 was
101478 - entered based on Mark 2.
101479 -
101480 - b. No, 73 != 1691, so F1 F1 F8 has not been set,
101481 -
101482 - Has flag for external link been set, i.e., has F1 F1 F8 been
101483 - used in another file?
101484 -
101485 - Does global 73 = 1691?
101486 -
101487 - 1. Yes, global 73 = 1691, so grab file ID and anchor
101488 - spec,,if any on the current line, return to target
101489 - file where F1 F1 F8 was set, and enter link between
101490 - two files.
101491 -
101492 - If SDS record, use that template.
101493 -
101494 - Archived SDS record, use gfname
101495 -
101496 - This permits linking to archived records
101497 - created by others, but not current records,
101498 - which should be okay.
101499 -
101500 - Current SDS, construct filename from record
101501 - diagnostics
101502 -
101503 - If document, use that template
101504 -
101505 - 2. No, global 73 != 1691, so enter an HTML anchor
101506 - template on the current line, or link two lines.
101507 -
101508 - Is current line the same as Mark 2 set by F1 F1 F8
101509 - that enters ending anchor code?
101510 -
101511 - a. Yes, so enter template
101512 -
101513 - b. No, so link current line to Mark 2.
101514 -
101515 -
101516 - ..
101517 - Background and Analsys
101518 -
101519 - Currently, F1 F1 F7 creates links between files by calling 0704086,
101520 - and F1 F1 F8 enters an ending spec, by calling 0704086 #2
101521 -
101522 - [On 990530 eliminated these calls. ref SDS 18 1044]
101523 -
101524 - [Planning on 990530 is at ref SDS 18 1645.]
101525 -
101526 - It would be nice to use F1 F1 F7 for internal links as well, so there
101527 - is symmetry in accomplishing similar functions.
101528 -
101529 - We might be able to do this based on mark 2.
101530 -
101531 - Mark 2 is set by macro 8 when Ctrl F1 is used to jump to the top of
101532 - the file, or in the case of SDS to the bottom of the SDS reference
101533 - list in order to select an SDS record, document or file to open.
101534 -
101535 - We only need this feature for editor files and not SDS.
101536 -
101537 - Macro 8 sets 237 1 to establish mark 2 is set. This used for linking
101538 - SDS records to other records and documents.
101539 -
101540 - We could make 0704081 turn off mark 2 in documents.
101541 -
101542 - This would allow giving F1 F1 F7 for documents, a conditional
101543 - assignment based on whether mark 2 is set.
101544 -
101545 - Seems a little wild because mark 2 is set anytime we jump to the top
101546 - of the file.
101547 -
101548 - Actually, we may be able to refine this by making the assignment of
101549 - F1 F1 F7 conditioned on the flag for linking files not being set.
101550 - That flag is only set when F1 F1 F8 has entered the ending anchor
101551 - code.
101552 -
101553 - Maybe we can use this to control assigning 0704081 to F1 F1 F7.
101554 -
101555 -
101556 -
1016 -
1017 -
1018 - Progress
1019 -
101901 - ..
101902 - 0704081 - Create HTML Links within Documenrts, F1 F1 F7
101903 -
101904 - Follow up ref SDS 13 2688, ref SDS 11 3120.
101905 -
101906 - [On 990530 eliminated these calls. ref SDS 18 1044]
101907 -
101908 - [Planning on 990530 is at ref SDS 18 1645.]
101909 -
101910 - Line 20, ref OF 2 5976, -goto bcs at beginning launches initial
101911 - activity as linking, which also a template option.
101912 -
101913 - Per planning, ref SDS 0 7644, want to eliminate entering full html
101914 - anchor code for internal links based on work yesterday in the record
101915 - at ref SDS 17 3024, and planning above. ref SDS 0 2967 It is not
101916 - needed because 0122 converts all anchors into html code. ref OF 1 1363
101917 - This change is accomplished below. ref SDS 0 5562
101918 -
101919 - Decided to combine 0704086 into this 0704081 operation, because the
101920 - processes are closely related, per planning above. ref SDS 0 7644
101921 -
101922 - ..
101923 - a. Link Between Files - F1 F1 F7
101924 -
101925 - Line 200, ref OF 2 8344, -label nltr if the link flag is not in
101926 - current file before global is read, but the global flag has been
101927 - set, 73 = 1691, then this an operation to link the current file
101928 - to the target file, markcur 49 set by F1 F1 F8.
101929 -
101930 - If global 72 1691 is not set, do templates or internal linking,
101931 - below. ref SDS 0 1520
101932 -
101933 - Line 210, ref OF 2 7548, -label nltr about 30 lines below, if this
101934 - is a current SDS record, create a flag global 68 773 to so the
101935 - filename can be captured from the record ID code, rather than
101936 - gfname, since the web site date base uses only the SDS file
101937 - structure, and not the current SDS record ID system.
101938 -
101939 - Line 230, ref OF 2 0782, -label lpanK, see if there is an anchor
101940 - on the line, and if so use it.
101941 -
101942 - Line 260, ref OF 2 5490, -label anch, if there is no anchor on the
101943 - line set a flag 70 2 not to use an anchor when creating the link
101944 - in the target file.
101945 -
101946 - Line 290, ref OF 2 4651, -label fbws in the target file, insert
101947 - the link between the current word and the previous word.
101948 -
101949 - Line 310, ref OF 2 4620, -label bhcs use split within margins and
101950 - add a line, then position the cursor on the left margin, and do
101951 - an up so the link address can be entered on a blank line.
101952 -
101953 - Line 320, ref OF 2 9428, -label bhcs about 30 lines below, return
101954 - to the original file and use gfname to capture the filename.
101955 -
101956 - Convert SD for the SDS directory to lower case sd for unix case
101957 - sensitive directories on the web server.
101958 -
101959 - Cannot capture filename initially, because it uses counters 1 -
101960 - 25 or so, and this crashes a bunch of stuff.
101961 -
101962 - Line 360, ref OF 2 1991, -label bhcs, if this is a current SDS
101963 - record, return to the linked file and get SDS file directory
101964 - information by reading the header.
101965 -
101966 - Line 400, ref OF 2 0713, -label ncSDS enter htm file extension.
101967 -
101968 - Line 420, ref OF 2 0858, -label ncSDS 20 lines below, return to
101969 - the target file and get the anchor if one was specified.
101970 -
101971 -
101972 -
101973 - a. Templates or Linking in Same File - F1 F1 F7
101974 -
101975 - Line 200, ref OF 2 8344, -label nltr if...
101976 -
101977 - 1. link flag is in current file before global is read, then this
101978 - is the file where an anchor was entered with F1 F1 F8, so we
101979 - can do template code.
101980 -
101981 - 2. link flag is not in current file before global is read, but
101982 - the global flag has not been set, it means this is a template
101983 - operation.
101984 - ..
101985 - Launch Template Operation Instead of Linking Between Files
101986 -
101987 - Line 440, ref OF 2 7462, -label eto first check if this is an SDS
101988 - record. If so, do that special template for citing the web site
101989 - only. It does a special template to cite web site only. Since it
101990 - can directly link to any SDS record or document, it does not need
101991 - these templates. ref SDS 0 1978
101992 -
101993 - If current line is the same as Mark 2, then do process that links
101994 - the lines. ref SDS 0 9640
101995 -
101996 -
101997 - SDS Link Template
101998 -
101999 - Line 460, ref OF 2 1815, -label 2Pass1, if we start on a
102000 - character, find the beginning of the word string, so the
102001 - template is inserted in front of the current word.
102002 -
102003 - Line 470, ref OF 2 1134, -label 2Pass if we are on a space,
102004 - move to the next position, and split within margins. Move the
102005 - cursor to the beginning of the line, create a blank line and
102006 - put the template on that line.
102007 -
102008 - Save this position with savescr 14 and setcur 1 0, so if F1 F1
102009 - F7 is run immediately again, it can do a letter template based
102010 - on the cursor not having moved.
102011 -
102012 -
102013 - ..
102014 - Letter Link Template, Alternate
102015 -
102016 - Line 480, ref OF 2 3784, -label ltr this enters an alternate
102017 - template for a letter or document other than SDS record.
102018 -
102019 - On the first pass, the template operation enters an SDS string. It
102020 - does savescr 14 and setcura 1 0 to save x y coordinates.
102021 -
102022 - User can call F1 F1 F7 again to enter a letter/document to
102023 - replace the SDS template.
102024 -
102025 - Line 170, ref OF 2 4471, -label bcs if letter template is set,
102026 - we do setcur 3 0 to compare cursor position. If the cursor has
102027 - not been moved, user wants to enter a letter template, so do
102028 - that. If the cursor has been moved, user is doing something
102029 - else, so do that, and turn off letter template flag.
102030 -
102031 -
102032 - ..
102033 - SDS Record Link to Welchco Home Page Only - F1 F1 F7
102034 -
102035 - Line 500, ref OF 2 4164, -label etsds in SDS records the only
102036 - template we will use is for specifying the web site home page,
102037 - since we can link everything else directly in SDS.
102038 -
102039 - This is the only task for F1 F1 F7 in an SDS record, ref SDS 0
102040 - 1520, and occurs only when the file link flag, global 73 1691,
102041 - is not set. ref SDS 0 6952
102042 -
102043 - If the cur line is not blank return error message, so we don't
102044 - overwrite anything. This is needed because a lot of things can
102045 - turn off the global link flag, and we don't want to enter this
102046 - web site address over existing text.
102047 -
102048 -
102049 -
102050 - ..
102051 - c. Link Lines in Same File
102052 -
102053 - Line 540, ref OF 2 6832 -label ilink, this is the code that was
102054 - formerly 0704086 to link lines in the same file.
102055 -
102056 - Line 200, ref OF 2 8344, -label nltr 20 lines below, if 73 = 1691
102057 - it means that F1 F1 F7 was called in the same file where F1 F1 F8
102058 - was used, so this is either a template or a linking operation.
102059 -
102060 - Line 450, ref OF 2 7462, -label eto, if the line numbers are
102061 - different, then we are doing a linking operation.
102062 -
102063 -
102064 - ..
102065 - Eliminate HTML Format for Internal Links, Use Only SDS Format
102066 -
102067 - Line 590, ref OF 2 4514, -label splt removed code that entered an
102068 - html anchor string, and simply enter <nnnn, which is the format
102069 - for SDS.
102070 -
102071 - This makes editing the stuff much easier.
102072 -
102073 - Since 0122 to convert SDS anchor formats into HTML, ref OF 1 1363,
102074 - this provides uniform method.
102075 -
102076 -
102077 -
102078 -
102079 - 000008 Assign Internal Links to F1 F1 F7 when Mark 2 Set
102080 -
102081 -
102082 - Line 740, ref OF 4 4877, -entry 156, sets...
102083 -
102084 - F1 F1 F7 @c:\sd\03\0704086
102085 -
102086 - F1 F1 F8 @c:\sd\03\0704086 #2
102087 -
102088 - [On 990530 eliminated these calls. ref SDS 18 1044]
102089 -
102090 - [Planning on 990530 is at ref SDS 18 1645.]
102091 -
102092 - Changed this today to call 0704081, since we are combining 0704086
102093 - into 0704081.
102094 -
102095 -
102096 - ..
102097 - 0704086 F1 F1 F8 Sets Flag Assign F1 F1 F7 to Internal Link
102098 -
102099 - Follow up
102100 -
102101 - This processor was eliminated today and the operations were
102102 - transferred into 0704081 at ref SDS 0 9640.
102103 -
102104 - Reason for eliminating 0704086 is above. ref SDS 0 5920
102105 -
102106 -
102107 - ..
102108 - 000006 Linking, Don't link editor Lines with Medit Commands
102109 -
102110 - Need to fix this.
102111 -
102112 - If there is a dash on the line, don't link to it.
102113 -
102114 - [Went back and did this in the record on 990505 to keep this
102115 - related stuff together. ref SDS 16 9856]
102116 -
102117 -
102118 -
102119 -
102120 -