home *** CD-ROM | disk | FTP | other *** search
- Nicolas Leblanc #2 @20302
- Mon Jul 03 02:22:19 1995
- ┌┬─── ── ─ ─ ── ───────────────────────────────────────────────────┬─ ∙∙
- ││ Alternative Worlds Presents │
- └┼─────────────────────────────────────────────────────────────────────┐
- ││ Mod Name » FMD-44a.MOD │∙
- ││ Difficulty » █▒▒▒▒▒▒▒▒▒▒ (1/10) │:
- ││ WWIV Version » 4.24 ││
- ││ Date Affected » 07/03/95 ││
- :│ Files Affected » BBSOVL1.C ││
- ∙│ Description » Better Email System (WWIVnet/Internet/Fidonet) ││
- └─────────────────────────────────────────────────────────────────────┼┐
- │ A French Mod Division Release - (C) 1995 FMD Software ││
- ∙∙ ─┴─────────────────────────────────────────────────── ── ─ ─ ── ───└┘
-
- ┌┬══════════════════┐
- ││ Long Description ││
- └══════════════════┴┘
-
- This modification will prompt your user when he wants to send an email to
- know if he wants to send an email over WWIVnet, Internet, Fidonet or local.
- This will ease the user's work by converting the addresses for him and sending
- it through a good gateway.
-
- This modification is based on a modification done by Secret Agent Man, for
- v4.23, except that this one is not a mail room modification, it's simply
- a prompt, your email routine is not affected and it just looks like stock
- WWIV, there is no graphical user interface.
-
- There is extra informations if you're not in expert mode on this modification,
- we guess that if your user is able to know all commands of WWIV by his heart,
- he's able to figure how this will work by himself.
-
- This modification is also configurable with WWIV.INI, but it's not required.
-
- Revision A:
-
- A mistery happened, I have no idea why the mod wasn't working right when
- it was on my system, I looked in the code and found out many errors. If you
- are upgrading, change the send_inet_mail and send_fido_mail functions, and add
- "@" in WWIV.INI before the node numbers.
-
- ┌┬═══════┐
- ││ Tests ││
- └═══════┴┘
-
- This modification has been tested on a virgin WWIV v4.24 source using
- Borland C++ v4.5
-
- ──────────────────────────────────────────────────────────────────────────────
- Legend
- ╔═══╤══════════════════┐
- │ + │ Add This Line │
- │ - │ Delete This Line │
- │ * │ Modify This Line │
- │ = │ Existing Line │
- └═══╧══════════════════╝
- ───[Step 1]────────────────────────────────────────────────────────────────────
-
- Load BBSOVL1.C and replace function send_email by this one:
-
- void send_email(void)
- {
- char s1[81], ch;
- unsigned short sy,un;
-
- write_inst(INST_LOC_EMAIL,0,INST_FLAGS_NONE);
- helpl=14;
- nl();
- ansic(1);
- pl("Select mail type:");
- nl();
- npr("2L7)1 Local mail\r\n");
- npr("2F7)1 Fidonet mail\r\n");
- npr("2I7)1 Internet mail\r\n");
- npr("2W7)1 WWIVnet mail\r\n");
- npr("2Q7)1 Quit\r\n");
- nl();
- npr("2Which type, <C/R>=Local) ? ");
- mpl(1);
- ch=onek("LFIWQ\r");
- switch(ch)
- {
- case 'F': send_fido_mail(); break;
- case 'I': send_inet_mail(); break;
- case 'W':
- pl("4WWIVnet E-mail.0");
- nl();
- if ((sysstatus_expert & thisuser.sysstatus)==0)
- {
- pl("To send a WWIVnet email, you need to send your email this way:");
- nl();
- pl("1UserNumber7@1WWIVnetAddress");
- pl("1UserName7@1WWIVnetAddress");
- nl();
- pl("Example:");
- nl();
- pl("232@55512");
- pl("JOHN DOE @55512");
- }
- nl();
- case '\r':
- case 'L':
- nln(2);
- pl(get_string(15));
- outstr(":");
- input(s1,75);
- helpl=0;
- irt[0]=0;
- irt_name[0]=0;
- parse_email_info(s1,&un,&sy);
- grab_quotes(NULL, NULL);
- if (un || sy)
- email(un,sy,0,0);
- break;
- case 'Q': return;
- }
- }
-
- ───[Step 2]────────────────────────────────────────────────────────────────────
-
- Block copy the following 3 functions just below the send_email function:
-
- char *s_and_r(char *string,char old,char nw)
- {
- short i= 0;
-
- do {
- if (string[i]==old)
- string[i]=nw;
- i++;
- } while(string[i]!='\0');
- return(string);
- }
-
- void send_inet_mail(void)
- {
- char *s,s1[81],s2[81],*ss;
- unsigned short sy,un;
-
- outchr(12);
- write_inst(INST_LOC_EMAIL,0,INST_FLAGS_NONE);
- nl();
- nl();
- npr("4Internet E-mail.0\r\n");
- nl();
- if ((sysstatus_expert & thisuser.sysstatus)==0)
- {
- pl("To send an Internet email, you need to send your email this way:");
- nl();
- pl("1UserName7@1server");
- nl();
- pl("Example:");
- nl();
- pl("john.doe@nowhere.com");
- }
- nl();
- pl("Enter the Internet E-mail address.");
- outstr(":");
- inputl(s1,60);
- strupr(s1);
- if (s1[0]==0)
- {
- pl(get_string(14));
- return;
- }
- s=s_and_r(s1,64,35);
- helpl=0;
- irt[0]=0;
- irt_name[0]=0;
- strcpy(s2,"@9023");
- if (ini_init("WWIV.INI", "FMD", NULL)==0)
- {
- if ((ss=ini_get("INTERNET_GATEWAY_NODE", -1, NULL))!=NULL)
- {
- strcpy(s2, ss);
- }
- ini_done();
- }
- strcat(s, s2);
- parse_email_info(s,&un,&sy);
- grab_quotes(NULL, NULL);
- if (un || sy)
- email(un,sy,0,0);
- else
- pl("Invalid address format.");
- }
-
- void send_fido_mail(void)
- {
- char s[81],s1[81],s2[81],s3[81],*ss;
- unsigned short sy,un;
-
- outchr(12);
- write_inst(INST_LOC_EMAIL,0,INST_FLAGS_NONE);
- helpl=14;
- npr("4Fidonet E-mail.0\r\n");
- nl();
- if ((sysstatus_expert & thisuser.sysstatus)==0)
- {
- pl("To send a Fidonet email, you will be prompted for 2 things:");
- nl();
- pl("1User Name");
- pl("1Fidonet Address");
- nl();
- pl("Example:");
- nl();
- pl("John Doe");
- pl("1:167/999");
- }
- nl();
- pl("Enter the Name of the person you want to email.");
- outstr(":");
- inputl(s1,31);
- strupr(s1);
- if (s1[0]==0)
- {
- pl(get_string(14));
- return;
- }
- pl("Enter the Fidonet address of that person.");
- outstr(":");
- input(s2,15);
- if (s2[0]==0)
- {
- pl(get_string(14));
- return;
- }
- helpl=0;
- irt[0]=0;
- irt_name[0]=0;
- sprintf(s,"%s (%s) ",s1,s2);
- strcat(s3,"@1020");
- if (ini_init("WWIV.INI", "FMD", NULL)==0)
- {
- if ((ss=ini_get("FIDONET_GATEWAY_NODE", -1, NULL))!=NULL)
- {
- strcpy(s3, ss);
- }
- ini_done();
- }
- strcat(s, s3);
- parse_email_info(s,&un,&sy);
- grab_quotes(NULL, NULL);
- if (un || sy)
- email(un,sy,0,0);
- else
- pl("Invalid address format.");
- }
-
- ───[Step 3]────────────────────────────────────────────────────────────────────
-
- Load WWIV.INI, if you don't have a [FMD] section, create it and add the
- following lines:
-
- [FMD]
- ; Node of the Internet Gateway
- INTERNET_GATEWAY_NODE = @9023
- ; Node of the Fidonet Gateway
- FIDONET_GATEWAY_NODE = @1020
-
- Please change those value to the closest gateways from your system, I found
- those by searching the WWIVnet listing, and I'm not sure they are working
- (they should). I have not been able to retrace the addresses from Secret Agent
- Man's modification since they were pre-changeover nodes.
-
- ───[Step 4]────────────────────────────────────────────────────────────────────
-
- Do a MAKE FCNS and compile back the BBS, you are ready to enjoy a very
- simple modification that gives you a lot more tools for your WWIV system.
-
- French Proverb: Il n'y a que la vérité qui blesse.
-
- For comments, bug report and suggestion, e-mail at the following address:
-
- Nicolas LeBlanc 2@20302.WWIVnet (aka Spotnick)
- -> spotnick@gamemaster.qc.ca
- Martin Bourdages 242@20306 / 3@20302.WWIVnet (aka Dark Shadow)
- -> martin.bourdages@radio.magicnet.com
-
- => French Mod Division Support Sub <=
- SubType: FMD
- Host: @20302 (WWIVnet)
- Scan sublist for other networks
-
- Read PRODUCTS.FMD for the full list of our support systems.
-
- ───[EOF]──────────────────────────────────────────────────────────────────────
-