topical media & game development

talk show tell print

lib-ch-example-ref-cgi-setCharSet.cgi / cgi



  #!/bin/ch
  /* Copyright (c) 2001 by SoftIntegration, Inc. All Rights Reserved */
  include <cgi.h>
  
  int main() {
    class CResponse Response;
    chchar *charSet_def, *charSet_cur;
  
    // get default char set
    charSet_def = Response.getCharSet();
    // put char set "ISO-LATIN-1"
    Response.setCharSet("ISO-LATIN-1");
    // get current char set
    charSet_cur = Response.getCharSet();
  
    Response.begin();
    Response.title("Test of Response.setCharSet and Response.getCharSet");
    printf("<H1> Test of Response.setCharSet and Response.getCharSet </H1> 
\n"); printf("The Default Char Set is : \%s <br>\n", charSet_def); printf("The Current Char Set is : \%s <br>\n", charSet_cur); Response.end(); }


(C) Æliens 20/2/2008

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.