home *** CD-ROM | disk | FTP | other *** search
/ WinFiles.com 1998 June / WF0698_3.ISO / servers-websrv / websuite.exe / CHAT.AP_ / CHAT.AP
Text File  |  1998-04-01  |  3KB  |  108 lines

  1. <[
  2. // Personal World Chat - Main
  3. // (c) 1997-98 SmartDesk, Inc., All Rights Reserved
  4.  
  5. _apGenerate( )
  6.  
  7. websrvr = 0 + param( 1 )
  8. sessionId = 0 + param( 2 )
  9.  
  10. session = new( "session", websrvr, sessionId )
  11.  
  12. channel = 0 + session.var( "channel" )
  13. if ( channel < 1 )
  14.     channel = 1
  15. end
  16.  
  17. alias  = session.var( "alias" )
  18.  
  19. id = session.var( "id" )
  20. if ( strempty( id ) || strempty( alias ) )
  21.     session._redir( "One Moment Please...", "sdchat.htm?channel=" + channel )
  22.     return( 0 )
  23. end
  24.  
  25.  
  26. file = fileFixPath( webServerHome( websrvr ) + "\\chat\\chan" + channel + ".cfg" )
  27. if ( ! fileExists( file ) )
  28.     hfile = fcreate( file, 0 )
  29.     if ( hfile > 0 )
  30.         fwriteline( hfile, "[Comments]" )
  31.         fwriteline( hfile, "1=Hello Everybody!" )
  32.         fwriteline( hfile, "2=Greetings All!" )
  33.         fwriteline( hfile, "3=Howdy!" )
  34.         fwriteline( hfile, "4=Cool!" )
  35.         fwriteline( hfile, "5=Way cool!" )
  36.         fwriteline( hfile, "6=Awesome!" )
  37.         fwriteline( hfile, "7=Hmmm..." )
  38.         fwriteline( hfile, "8=Ahhh, yeah..." )
  39.         fwriteline( hfile, "9=Geeze..." )
  40.         fwriteline( hfile, "10=Say what?" )
  41.         fwriteline( hfile, "11=Good-bye" )
  42.         fwriteline( hfile, "12=Later, dude." )
  43.         fwriteline( hfile, "13=Chow, man." )
  44.         fwriteline( hfile, "" )
  45.         fwriteline( hfile, "[Images]" )
  46.         fwriteline( hfile, "1=SmartDesk Logo|/image/sdlogo.gif" )
  47.         fwriteline( hfile, "2=VirtualPROMOTE Logo|/image/vplogo.jpg" )
  48.         fwriteline( hfile, "3=WINC Logo|chathdr.jpg" )
  49.         fwriteline( hfile, "" )
  50.         fwriteline( hfile, "[Links]" )
  51.         fwriteline( hfile, "1=SmartDesk|http://www.smartdesk.com" )
  52.         fwriteline( hfile, "2=VirtualPROMOTE|http://www.virtualpromote.com" )
  53.         fwriteline( hfile, "" )
  54.         fwriteline( hfile, "[Sounds]" )
  55.         fwriteline( hfile, "1=Applause|applause.wav" )
  56.         fwriteline( hfile, "2=Opps|oops.wav" )
  57.         fwriteline( hfile, "" )
  58.         fwriteline( hfile, "[Emoticons]" )
  59.         fwriteline( hfile, "1=:)" )
  60.         fwriteline( hfile, "2=;)" )
  61.         fwriteline( hfile, "3=:-)" )
  62.         fwriteline( hfile, "4=;-)" )
  63.         fwriteline( hfile, "5=:o)" )
  64.         fwriteline( hfile, "6=;o)" )
  65.         fwriteline( hfile, "7=:<)" )
  66.         fwriteline( hfile, "8=:(" )
  67.         fwriteline( hfile, "9=:o" )
  68.         fwriteline( hfile, "10=@#!$%&$#" )
  69.         fwriteline( hfile, "11=!!!!!!!" )
  70.         fwriteline( hfile, "12=???????" )
  71.         fwriteline( hfile, "" )
  72.         fwriteline( hfile, "[Actions]" )
  73.         fwriteline( hfile, "1=User Name" )
  74.         fwriteline( hfile, "2=Alias" )
  75.         fwriteline( hfile, "3=Email Address" )
  76.         fwriteline( hfile, "4=Time Stamp" )
  77.         fwriteline( hfile, "5=Date" )
  78.         fwriteline( hfile, "6=Time" )
  79.         fwriteline( hfile, "" )
  80.  
  81.         fclose( hfile )
  82.     end
  83. end
  84.  
  85. ]>
  86.  
  87. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
  88. <!-- SmartDesk Active Page, www.smartdesk.com -->
  89. <HTML>
  90. <HEAD>
  91. <TITLE>SmartDesk Web Chat</TITLE>
  92. </HEAD>
  93.  <FRAMESET BORDER="0" FRAMEBORDER="no" ROWS="105, *">
  94.  
  95.   <[ 
  96.   qstr = "?id=" + webEncodeUrl( id ) + "&channel=" + channel + "&alias=" + webEncodeUrl( alias ) 
  97.   ]>
  98.  
  99.   <FRAME NAME="winc_top" SCROLLING="no" NORESIZE SRC="/chat/chat1.htm<[ ! qstr ]>" >
  100.   <FRAME NAME="winc_bottom" NORESIZE SRC="sdchat.htm<[ ! qstr ]>&cmd=ChatText">
  101.  </FRAMESET>
  102.   <BODY>
  103.  <NOFRAMES>
  104.    <H2>The WINC chat program requires frame support</H2>
  105.   </BODY>
  106.  </NOFRAMES> 
  107. </HTML>
  108.