872{
879 {
881 {
884 {
885 case 'f':
886 case 'h':
887 case 'H':
888 {
889 char temp[256];
891 if ((*
p==
'h')&&(htmldir!=
NULL))
892 strcat(sys,"file://localhost");
893 else if ((*
p==
'H')||(htmldir==
NULL))
895
896 if (hentry !=
NULL && *(hentry->
url) !=
'\0')
897 #ifdef HAVE_VSNPRINTF
898 {
900 #ifdef SINGULAR_4_2
901 snprintf(temp,256,"%s/%d-%d/%s", htmldir,
904 #else
905 snprintf(temp,256,"%s/%d-%d-%d/%s", htmldir,
909 #endif
911 else
912 snprintf(temp,256,
"%s/%s", htmldir, hentry->
url);
913 }
914 else
915 {
917 #ifdef SINGULAR_4_2
918 snprintf(temp,256,"%s/%d-%d/index.htm", htmldir,
921 );
922 #else
923 snprintf(temp,256,"%s/%d-%d-%d/index.htm", htmldir,
927 );
928 #endif
929 else
930 snprintf(temp,256,"%s/index.htm", htmldir);
931 }
932 #else
933 {
935 #ifdef SINGULAR_4_2
936 sprintf(temp,"%s/%d-%d/%s", htmldir,
940 else
941 sprintf(temp,
"%s/%s", htmldir, hentry->
url);
942 #else
943 sprintf(temp,"%s/%d-%d-%d/%s", htmldir,
948 else
949 sprintf(temp,
"%s/%s", htmldir, hentry->
url);
950 #endif
951 }
952 else
954 #ifdef SINGULAR_4_2
955 sprintf(temp,"%s/%d-%d/index.htm", htmldir,
958 );
959 #else
960 sprintf(temp,"%s/%d-%d-%d/index.htm", htmldir,
964 );
965 #endif
966 else
967 sprintf(temp,"%s/index.htm", htmldir);
968 }
969 #endif
970 strcat(sys,temp);
972 {
973 char *
pp=(
char *)strchr(sys,
'#');
975 {
979 }
980 }
982 break;
983 }
984 case 'i':
985 {
987 if (i_res!=
NULL) strcat(sys,i_res);
988 else
989 {
990 WarnS(
"singular.info not found");
991 return;
992 }
994 break;
995 }
996 case 'n':
997 {
998 char temp[256];
999 if ((hentry!=
NULL) && (*(hentry->
node) !=
'\0'))
1000 sprintf(temp,
"%s",hentry->
node);
1001
1002
1003 else
1004 sprintf(temp,"Top");
1005 strcat(sys,temp);
1007 break;
1008 }
1009 case 'v':
1010 {
1011 char temp[256];
1015 strcat(sys,temp);
1017 break;
1018 }
1019 default: break;
1020 }
1022 }
1023 else
1024 {
1027 }
1028 }