File name: addrbook/memo.sub (1,134 bytes) Text file viewer v1.2
    1 : #!/bin/wel
    2 : 
    3 : /* file: memo.sub
    4 : 
    5 :    메모 폼 출력 부 프로그램 (author: 서광현)
    6 : 
    7 :    Copyright (c) 2001/02/22 by Wesoft
    8 :    All Rights Reserved.
    9 : */
   10 : 
   11 : fm= formopen("form/memo.fom");
   12 : if(fm==FORM_OPENERR) return err_form("memo.fom");
   13 : 
   14 : memo_recnt= get_recount(mysql, memotable, "");
   15 : tot_page= memo_recnt / mpagerec;
   16 : if(memo_recnt%mpagerec>0) tot_page++;
   17 : view_page= val(pg);
   18 : if(view_page<1) view_page= 1;
   19 :  else if(view_page>tot_page) view_page= tot_page;
   20 : start_rec= (view_page-1) * mpagerec;
   21 : 
   22 : qstr= "select selno,wdtime,name,memo from " ~ memotable
   23 :     ~ " order by wdtime desc limit " ~ start_rec ~ "," ~ mpagerec;
   24 : 
   25 : if(mysql_query(mysql, qstr)==MYSQL_ERR) return err_query();
   26 : myresult= mysql_store_result(mysql);
   27 : if(myresult==MYSQL_ERR) return err_store_result();
   28 : row_recnt= mysql_num_rows(myresult);
   29 : for(rec=1; rec<=row_recnt; rec++)
   30 :  {
   31 :     row= mysql_fetch_row(myresult);
   32 :     if(row!=MYSQL_ERR)
   33 :      {
   34 :         selno= row[0];
   35 :         wdtime= mid(insert_week(row[1]), 6, 15);
   36 :         name= row[2];
   37 :         memo= row[3];
   38 :         formmerge(0);
   39 :      }
   40 :  }
   41 : mysql_free_result(myresult);
   42 : selno= wdtime= name= memo= "";
   43 : formdump();
   44 : formclose();
   45 : return;
File name: addrbook/memo.sub (1,134 bytes) Wesoft Corp. ⓒ 2001 All rights reserved.