Thread: create html

    #1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2004
    Posts
    11
    Rep Power
    0

    create html


    Hi,
    I want to create an html page from a python script that will show some data in matrix form. How this can be done in some simple way? Is it necessary to involve cgi?

    Nikos
  2. #2
  3. Mini me.
    Devshed Novice (500 - 999 posts)

    Join Date
    Nov 2003
    Location
    Cambridge, UK
    Posts
    783
    Rep Power
    14
    There are many ways for Python to create web-pages.

    The answer to your question depends on what you want to do - what is the problem you are trying to solve?

    Do you have write access to a web-server that allows CGI?

    grim
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2004
    Posts
    11
    Rep Power
    0
    The problem that i want to solve is the following:

    I would like to have a python script that will produce when i will execute it an html file containing some tables of numbers and some graphs of these tables. I already have the python script with the lists and the graphs. I just want to post them in an html file each time i evaluate the script.
    I dont have any write access to some external server,i have only installed some kind of 'personal' server called 'abyss'. I really dont know what route to follow because there exist many possibilities for this kind of job as you also stated. I would really appreciate some guidelines...

  6. #4
  7. Mini me.
    Devshed Novice (500 - 999 posts)

    Join Date
    Nov 2003
    Location
    Cambridge, UK
    Posts
    783
    Rep Power
    14
    I see Abyss supports CGI...

    If the cost to render the page (in CPU, memory and time) is low then CGI generating the web-page on-demand is fine.

    If it takes several seconds of number crunching to produce the results then on-the-fly on-demand generation would be a problem to other users of the machine and would be slow for your end-users. In this case periodically generating a static web-page by writing to file is probably the way to go. Abyss will have a directory configured for web-pages.

    grim
  8. #5
  9. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2004
    Posts
    346
    Rep Power
    0
    either that or implement it in javascript...

IMN logo majestic logo threadwatch logo seochat tools logo