Hi
Attempting to port a Linux program from book titled "C Programming in Linux) (circa 2008) to my Windows 8.1 running Pelles C latest version. Here following is the code running in console mode.
#include <stdio.h>
#include <string.h>
/* MAIN PROGRAM BODY */
int main(int argc, char *argv[], char *env[])
_clrscr(); // Erase the user's output screen
printf("\n\n");
printf("Content-type:text/html\n\n");
printf("<html>\n");
printf("<body bgcolor=\"%s\">\n", argv[1]);
printf("<body>\n");
printf("<html>\n");
printf("\n\n");
return 0; // another way of ending program
} /* END OF MAIN PROGRAM */
Does not work in Pelles C, running on Windows 8.1. Might be because program was written to run in Linux. Appears to be related to the statement "int main(int argc, char *argv[], char *env[])". The last argument does not appear to work. I don't get the webpage to open at all. As though the printf statements for the generation of the webpages are not working.
What am I NOT doing or doing WRONG??
Thanks in advance!!
royski
Email: Removed. (It's not a good idea to show personal Email on a public forum, unless you like spam...)