The CGI path: can anyone shine a light?
-
- Addict
- Posts: 1264
- Joined: Wed Feb 28, 2007 9:13 am
- Location: London
It's in their KnowledgeBase:
http://faq.oneandone.co.uk/scripting/se ... les/3.html
Observe the URL. "Self programmed executable files". What does that suggest? I think it suggests exe's quite specifically.
But at that URL is the following:
"Can I compile and install any program I want on my 1&1 server?
You can install virtually any application on your web space so long as you do not require root access for the installation.
Please see the 1&1 Terms and Conditions for more information about installation allowances and restrictions."
And if you go to the Terms & Conditions, it's a monolithic set of documents in which there is no mention of "CGI" let alone "executable".
http://faq.oneandone.co.uk/scripting/se ... les/3.html
Observe the URL. "Self programmed executable files". What does that suggest? I think it suggests exe's quite specifically.
But at that URL is the following:
"Can I compile and install any program I want on my 1&1 server?
You can install virtually any application on your web space so long as you do not require root access for the installation.
Please see the 1&1 Terms and Conditions for more information about installation allowances and restrictions."
And if you go to the Terms & Conditions, it's a monolithic set of documents in which there is no mention of "CGI" let alone "executable".
Ah, unlucky. Notice how they sell server packages and web hosting packages. This question applies when you purchase a server package. Although I agree, it's misleading when the answer mentions web space."Can I compile and install any program I want on my 1&1 server?
As you can see here, they tell you which languages are supported under which web hosting packages:
http://faq.oneandone.co.uk/scripting/cgi_options/1.html
-
- Addict
- Posts: 1264
- Joined: Wed Feb 28, 2007 9:13 am
- Location: London
Well well!
I've just received an invoice from 1&1. There was no text explaining what was going on; no "human" verbiage at all - just an invoice.
They've terminated the contract!
Strangely they've also cancelled my contract for a domain name that I'd registered with them. I actually didn't want the domain cancelled, but it's probably better than being lumbered with a useless 17-month contract!
So, a speedy and total response!
@BlueZNL... if you do add a CGI section to the Survival Guide (which I think would be a good idea as CGI is quite daunting for the beginner) please include a statement telling people categorically to phone up prospective web hosts and ask if they allow CGI executables. Don't go by what they say on their sites, as you may get the wrong idea, like I did!
I've just received an invoice from 1&1. There was no text explaining what was going on; no "human" verbiage at all - just an invoice.
They've terminated the contract!
Strangely they've also cancelled my contract for a domain name that I'd registered with them. I actually didn't want the domain cancelled, but it's probably better than being lumbered with a useless 17-month contract!
So, a speedy and total response!
@BlueZNL... if you do add a CGI section to the Survival Guide (which I think would be a good idea as CGI is quite daunting for the beginner) please include a statement telling people categorically to phone up prospective web hosts and ask if they allow CGI executables. Don't go by what they say on their sites, as you may get the wrong idea, like I did!
- greyhoundcode
- Enthusiast
- Posts: 112
- Joined: Sun Dec 30, 2007 7:24 pm
PureBasic and .htaccess
Realise this is an old thread, however I do a lot of work in PHP and have been thinking about porting a project over to PB, primarily for the potential speed benefits. Anyway ... an earlier post mentioned the anomaly of having files ending in .exe, and another poster suggested .htaccess as a solution.
I just wanted to elaborate upon this and suggest the following as a potential (though untested) .htaccess template for anyone else going down this road.
The idea being that webapp.exe would receive the path in variable $q: so if someone accessed http://www.domain.com/app_directory/sho ... ting_story then showpage/65/an_interesting_story would be placed inside $q, accessible to the app as get data, as demonstrated in links to other threads already provided.
It is an approach I use all the time with PHP (tweaked appropriately for the server environment, needless to say) and indeed the above is an adaptation of the suggested rewrite rules for the Kohana and Codeigniter frameworks - it would be interesting to hear feedback from a PB developer who has used a similar approach, or knows of pitfalls relating to it.
I just wanted to elaborate upon this and suggest the following as a potential (though untested) .htaccess template for anyone else going down this road.
Code: Select all
# Ensure that mod_rewrite is on
RewriteEngine On
# Directory in which executable resides:
RewriteBase /app_directory/
# Allow direct access to existing files
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
# Provide executable with request via Get Data
RewriteRule ^(.*)$ webapp.exe?q=$1 [PT,L]
It is an approach I use all the time with PHP (tweaked appropriately for the server environment, needless to say) and indeed the above is an adaptation of the suggested rewrite rules for the Kohana and Codeigniter frameworks - it would be interesting to hear feedback from a PB developer who has used a similar approach, or knows of pitfalls relating to it.
Re: The CGI path: can anyone shine a light?
Would it be interesting for all to add a page to the Survival Guide? I'd need some help with that though...
Edit: (Ah, just noticed I posted that question before
)
Edit: (Ah, just noticed I posted that question before

Last edited by blueznl on Mon Dec 07, 2009 4:51 pm, edited 1 time in total.
( PB6.00 LTS Win11 x64 Asrock AB350 Pro4 Ryzen 5 3600 32GB GTX1060 6GB)
( The path to enlightenment and the PureBasic Survival Guide right here... )
( The path to enlightenment and the PureBasic Survival Guide right here... )
- greyhoundcode
- Enthusiast
- Posts: 112
- Joined: Sun Dec 30, 2007 7:24 pm
Re: The CGI path: can anyone shine a light?
I think that could be a good idea: might also serve as an intro to web app development for those who primarily generate GUI programs.
Re: The CGI path: can anyone shine a light?
I don't want to hijack this thread, so I've opened a new one regarding CGI here:
http://www.purebasic.fr/english/viewtop ... 24#p308324
... unless the devs want to move it elsewhere...
http://www.purebasic.fr/english/viewtop ... 24#p308324
... unless the devs want to move it elsewhere...
( PB6.00 LTS Win11 x64 Asrock AB350 Pro4 Ryzen 5 3600 32GB GTX1060 6GB)
( The path to enlightenment and the PureBasic Survival Guide right here... )
( The path to enlightenment and the PureBasic Survival Guide right here... )
Re: The CGI path: can anyone shine a light?
I'm glad that Seymour got his money back. For future reference there is an alternative solution. The internet and neworks being the monolithic interconected beasts that they are. Allow for things to be placed anywhere on the network as long as it's connected. So in a stuation like Seymour's, you could host your executables from any machine anywhere. All you have to do is point to it as if you were pointing to a file. They don't even need to have the same OS.
In another scenario.. If you were building a site that was graphics intensive but your home IP doesn't have enough bandwidth to properly host this site. You could split the load and have the "professionally hosted" website handle the graphics while you run your executables from the kitchen table. Of course that machine would need to be up all the time, but the possibilties for PB.cgi are endless..
Jack
In another scenario.. If you were building a site that was graphics intensive but your home IP doesn't have enough bandwidth to properly host this site. You could split the load and have the "professionally hosted" website handle the graphics while you run your executables from the kitchen table. Of course that machine would need to be up all the time, but the possibilties for PB.cgi are endless..
Jack
Make everything as simple as possible, but not simpler. ~Albert Einstein