Re: [Tutor] Option on How to create web Interface

2014-05-22 Thread Alan Gauld
On 22/05/14 19:47, Chris “Kwpolska” Warrick wrote: On Thu, May 22, 2014 at 12:54 AM, Alan Gauld wrote: But basically this just creates a text file in a folder somewhere. Its only when that is accessed via a web server that it gets sent to a browser, and only as a static file. If you wanted to

Re: [Tutor] Option on How to create web Interface

2014-05-22 Thread Chris “Kwpolska” Warrick
On Thu, May 22, 2014 at 12:54 AM, Alan Gauld wrote: > But basically this just creates a text file in a folder somewhere. > Its only when that is accessed via a web server that it gets > sent to a browser, and only as a static file. > > If you wanted to do it dynamically you'd have a file called >

Re: [Tutor] Option on How to create web Interface

2014-05-21 Thread Dave Angel
fabu desay Wrote in message: > If I got the problem correctly What problem is that? I see no context. > ,you can equally create + open a file > file = open(filename,+wr) But the second argument must be a string. I cannot imagine any content in the wrong variable that would produce a strin

Re: [Tutor] Option on How to create web Interface

2014-05-21 Thread Danny Yoo
As a web server, you would not even be trying to open a file on disk. You've most likely got the network socket as a file-like object in hand: you'd probably write directly to that file-like object and avoid touching any disk whatsoever. You want to avoid touching disk if possible, especially on h

Re: [Tutor] Option on How to create web Interface

2014-05-21 Thread Alan Gauld
On 21/05/14 16:50, fabu desay wrote: If I got the problem correctly,you can equally create + open a file file = open(filename,+wr) You wouldn't normally use +wr as a mode; that introduces a lot of complications. Usually you just open to read, or open to write. In your case w is all you need.

[Tutor] Option on How to create web Interface

2014-05-21 Thread fabu desay
If I got the problem correctly,you can equally create + open a file file = open(filename,+wr) The file should have the HTML extension You can now pace your web contents in the file.html you created that should work by trigering the python file you programed in and it inturn creates the website or