Qbasicnews.com

Full Version: web site making
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4
if a guy put a gun to your head and said "make me the best web site ever" what would you use html or php. what support does php require?

Silent-Death

I like to use html and save the stuff as .htm (it's more univeral i hear)... but then again i'm kind of a beginner at that stuff so i could easily be wrong.
Well, that depends on the type of site you're making. If you will rarely have to change the pages, just use plain HTML.

On the other hand, if you want to automate updates and make other interactive things (such as forums), you have to use PHP (or another scripting language.)
To use PHP, the server has to have PHP installed on it, since PHP is serverside scripting. PHP will install and run on any webserver which supports the common gateway interface (aka most any server except the one I wrote when i was REALLY bored...hehehe)
Heh ! I modified your server a while ago to admit QBasic CGIs Tongue

When it was asked to serve a .BAS file, it ran Qbasic with the BAS file, redirected everything to OUT.HTML and served that file. In QB you just had to output the HTML code using PRINT, for example, a counter:

Code:
PRINT "<html><head><title>QBasic generated page</title></head>"
PRINT "<body>"
OPEN "COUNTER.DAT" FOR BINARY AS #1
GET #1,,counter&
CLOSE #1
counter& = counter& + 1
OPEN "COUNTER.DAT" FOR BINARY AS #1
PUT #1,,counter&
CLOSE #1
PRINT "<b>This page has been visited "; counter&; " times.</b>"
PRINT "</body></html>"

It was slow, insecure and problematic, but it worked.

It was so cool Big Grin
hahaha! freaky Big Grin didn't know anyone actually did anything neat with that old hunk o junk web server wanabe Big Grin
Yeah, JQB45 once made a forum with QB CGI. He figured out how to get environment variables and everything...
I think Logic Lord and Pasco both fiddled with it too, many years ago.
Well, yeah, it's more of a gimmick than anything. QB is not the most text-parsing friendly language around, nor is dos the multitasking of operating systems Big Grin

As for asking whether to do it in php or html, that's like asking whether you should ride a car or a car-making machine. PHP and HTML are nowhere NEAR close to the same thing.
I imagine it wouldn't be too difficult to modify my webserver to use the php.exe module Smile I just find it funny about QB being used to parse web scripts Big Grin hrm...maybe I'll take another stab at my server...someday...
Pages: 1 2 3 4