configure and use gambas web programs

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

configure and use gambas web programs

PICCORO McKAY Lenz
hi benoit i'm back! again with gambas web, and amnesia!

2017-02-15 22:33 GMT-04:00 Benoît Minisini <[hidden email]>:

> Example with the configuration file of lighttpd:
>
> ...
> # This tells that all and executable files are cgi scripts,
> # and just them
> cgi.execute-x-only = "enable"
> cgi.assign = ( "" => "" )
>

that's its necesary to run any cgi gambas generated code? if yes why in
past doesn not mentioned in the gambas wiki explicy!?


> ...
> # This tell that the "/manager" URL is associated with the CGI script
> alias.url = ( "/manager" => "/path/to/MyCgiScript.gambas" )
>
>
its necesary associated a path with the app gambas path with the
excecutable?
there's a way to assing a arbitrary path to gambas cgi?

i mean just like php does, i put the exce and server runs!?


> Regards,
>
> --
> Benoît Minisini


the gambas tutorial in the wiki are not found by me or its not made yet,
the only info i got are the jbsan minimal tutorial.. very great .. but its
too minimal.

Lenz McKAY Gerardo (PICCORO)
http://qgqlochekone.blogspot.com
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

Re: configure and use gambas web programs

Benoît Minisini
Le 13/03/2017 à 16:29, PICCORO McKAY Lenz a écrit :

> hi benoit i'm back! again with gambas web, and amnesia!
>
> 2017-02-15 22:33 GMT-04:00 Benoît Minisini <[hidden email]>:
>
>> Example with the configuration file of lighttpd:
>>
>> ...
>> # This tells that all and executable files are cgi scripts,
>> # and just them
>> cgi.execute-x-only = "enable"
>> cgi.assign = ( "" => "" )
>>
>
> that's its necesary to run any cgi gambas generated code? if yes why in
> past doesn not mentioned in the gambas wiki explicy!?
>
>
>> ...
>> # This tell that the "/manager" URL is associated with the CGI script
>> alias.url = ( "/manager" => "/path/to/MyCgiScript.gambas" )
>>
>>
> its necesary associated a path with the app gambas path with the
> excecutable?
> there's a way to assing a arbitrary path to gambas cgi?
>
> i mean just like php does, i put the exce and server runs!?
>
>

This is lighttpd specific configuration syntax. I don't know what the
syntax is in Apache or other web servers.

But the principles should be the same:

- A way to associate an URL path to a disk path.
- Something to tell the web server which files are CGI scripts.

Then your CGI script file should always be an executable, whatever
webserver you use.

Configuring the execution of a CGI script has nothing to do with Gambas,
it's purely a specific web server configuration thing.

Regards,

--
Benoît Minisini

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

Re: configure and use gambas web programs

PICCORO McKAY Lenz
2017-03-13 11:36 GMT-04:00 Benoît Minisini <[hidden email]>:

> Configuring the execution of a CGI script has nothing to do with Gambas,
> it's purely a specific web server configuration thing.
>
> again in same place, starting from zero! and reading the cgi principes!
arrrgggg!

does any body know how to configure the gambasforge[1] project in webserver?

[1] http://www.gambasforge.org/forge.html
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

Re: configure and use gambas web programs

Fabien Bodard-4
Maybe me 😀 as I have writted it with Adrien and also because I'm the
administrator of the site. Well a bad administrator but the site run for
years now without crash.

If you are a kind man I can open a door for you to see the site from the
inside. Can I have confidence to you ?
Write me in private.


Le 13 mars 2017 17:08, "PICCORO McKAY Lenz" <[hidden email]> a
écrit :

> 2017-03-13 11:36 GMT-04:00 Benoît Minisini <[hidden email]>:
>
> > Configuring the execution of a CGI script has nothing to do with Gambas,
> > it's purely a specific web server configuration thing.
> >
> > again in same place, starting from zero! and reading the cgi principes!
> arrrgggg!
>
> does any body know how to configure the gambasforge[1] project in
> webserver?
>
> [1] http://www.gambasforge.org/forge.html
> ------------------------------------------------------------
> ------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Gambas-user mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gambas-user
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

Re: configure and use gambas web programs

Fabien Bodard-4
I have a problems with the physical server since days now... need to wait

Le 13 mars 2017 22:06, "Fabien Bodard" <[hidden email]> a écrit :

> Maybe me 😀 as I have writted it with Adrien and also because I'm the
> administrator of the site. Well a bad administrator but the site run for
> years now without crash.
>
> If you are a kind man I can open a door for you to see the site from the
> inside. Can I have confidence to you ?
> Write me in private.
>
>
> Le 13 mars 2017 17:08, "PICCORO McKAY Lenz" <[hidden email]> a
> écrit :
>
>> 2017-03-13 11:36 GMT-04:00 Benoît Minisini <[hidden email]>
>> :
>>
>> > Configuring the execution of a CGI script has nothing to do with Gambas,
>> > it's purely a specific web server configuration thing.
>> >
>> > again in same place, starting from zero! and reading the cgi principes!
>> arrrgggg!
>>
>> does any body know how to configure the gambasforge[1] project in
>> webserver?
>>
>> [1] http://www.gambasforge.org/forge.html
>> ------------------------------------------------------------
>> ------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> Gambas-user mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/gambas-user
>>
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

Re: configure and use gambas web programs

Adrien Prokopowicz-2
In reply to this post by PICCORO McKAY Lenz
Le Mon, 13 Mar 2017 17:06:44 +0100, PICCORO McKAY Lenz  
<[hidden email]> a écrit:

> 2017-03-13 11:36 GMT-04:00 Benoît Minisini  
> <[hidden email]>:
>
>> Configuring the execution of a CGI script has nothing to do with Gambas,
>> it's purely a specific web server configuration thing.
>>
>> again in same place, starting from zero! and reading the cgi principes!
> arrrgggg!
>
> does any body know how to configure the gambasforge[1] project in  
> webserver?
>
> [1] http://www.gambasforge.org/forge.html
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Gambas-user mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gambas-user
Here is an extract of the Apache configuration for the GambasForge website.
It's a bit messy (We were young :) ), but the important parts are the  
"ExecCGI" options, as well as the "AddHandler cgi-script .cgi" extra file  
handlers.

Currently, this configuration only enables the use of the CGI scripts, and  
then we use an .htaccess file with a whole bunch of RewriteRules, so we  
have pretty URLs (such as /forge.html) to point to the main.gambas.cgi  
executable. Here is an extract :

        #forge
        RewriteRule   ^forge\.html$ main.gambas.cgi?section=forge [QSA]
        RewriteRule   ^mail\.html$ main.gambas.cgi?section=forge&action=sendmail  
[QSA]
        RewriteRule    
^categorie\-([0-9]+)(?:\-[a-z0-9\-]+)?(?:\-page\-([0-9]+))\.html$  
main.gambas.cgi?action=categorie&section=forge&id=$1&numpage=1 [QSA]
        RewriteRule    
^code\-([0-9]+)-ajoutercommentaire(?:\-[a-z0-9\-]+)?\.html$  
main.gambas.cgi?section=forge&action=addcomment&id=$1 [QSA]

And then, you can check the section and action parameters in your  
application to show the right page. :)

Hope that answers some of your questions. :)
Regards,
--
Adrien Prokopowicz
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user

gambasforge.conf (660 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: configure and use gambas web programs

PICCORO McKAY Lenz
thanks adrian thanks fabian.. ahhh i can see the trick! that's why the
installer script rename the compiled app and added and extension ".cgi"
right? of course, thanks for the hint! how stupid i feel jajaja now i can
understand benoit was talking about!

so in general, make a gambas program that generate html code, compile and
make a trick to that compiled programs acts as "cgi exec" and then invoke
from webserver path.. in this case, the trick was only interpretation of
any extension "cgi" in the site definition of apache... that's in few
words...

rewrite rules dont care! thanks in any case.. the conf file carified my way
with your words and sein the installe script.. but hey i'll ask more later..

about fabian, i write private and try to help.. due cos i like (as i does
with php and codeigniter) easy made apps for gain path agains guindo apps
in enterprise..

Lenz McKAY Gerardo (PICCORO)
http://qgqlochekone.blogspot.com

2017-03-13 17:23 GMT-04:00 Adrien Prokopowicz <[hidden email]>
:

> Le Mon, 13 Mar 2017 17:06:44 +0100, PICCORO McKAY Lenz <
> [hidden email]> a écrit:
>
> 2017-03-13 11:36 GMT-04:00 Benoît Minisini <[hidden email]>:
>>
>> Configuring the execution of a CGI script has nothing to do with Gambas,
>>> it's purely a specific web server configuration thing.
>>>
>>> again in same place, starting from zero! and reading the cgi principes!
>>>
>> arrrgggg!
>>
>> does any body know how to configure the gambasforge[1] project in
>> webserver?
>>
>> [1] http://www.gambasforge.org/forge.html
>> ------------------------------------------------------------
>> ------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> Gambas-user mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/gambas-user
>>
>
> Here is an extract of the Apache configuration for the GambasForge website.
> It's a bit messy (We were young :) ), but the important parts are the
> "ExecCGI" options, as well as the "AddHandler cgi-script .cgi" extra file
> handlers.
>
> Currently, this configuration only enables the use of the CGI scripts, and
> then we use an .htaccess file with a whole bunch of RewriteRules, so we
> have pretty URLs (such as /forge.html) to point to the main.gambas.cgi
> executable. Here is an extract :
>
>         #forge
>         RewriteRule   ^forge\.html$ main.gambas.cgi?section=forge [QSA]
>         RewriteRule   ^mail\.html$ main.gambas.cgi?section=forge&action=sendmail
> [QSA]
>         RewriteRule   ^categorie\-([0-9]+)(?:\-[a-z
> 0-9\-]+)?(?:\-page\-([0-9]+))\.html$ main.gambas.cgi?action=categor
> ie&section=forge&id=$1&numpage=1 [QSA]
>         RewriteRule   ^code\-([0-9]+)-ajoutercommen
> taire(?:\-[a-z0-9\-]+)?\.html$  main.gambas.cgi?section=forge&action=addcomment&id=$1
> [QSA]
>
> And then, you can check the section and action parameters in your
> application to show the right page. :)
>
> Hope that answers some of your questions. :)
> Regards,
> --
> Adrien Prokopowicz
> ------------------------------------------------------------
> ------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Gambas-user mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gambas-user
>
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

Re: configure and use gambas web programs

PICCORO McKAY Lenz
In reply to this post by Adrien Prokopowicz-2
hi adrian, i can see based on the "extract" that the link in connection
users in gqambas forge  are a rewrite rule?

<a id="inscription" href="inscription.html" rel="nofollow">Pas de compte ?
Incription</a>

but if are a rewrite, what parameters i must parse to the cgi to activate?

and the workflow its quite close to your's have in mind in that moment,
very hard to follow by me.. without a very great explications

2017-03-13 17:23 GMT-04:00 Adrien Prokopowicz <[hidden email]>
:

>         #forge
>         RewriteRule   ^forge\.html$ main.gambas.cgi?section=forge [QSA]
>         RewriteRule   ^mail\.html$ main.gambas.cgi?section=forge&action=sendmail
> [QSA]
>         RewriteRule   ^categorie\-([0-9]+)(?:\-[a-z
> 0-9\-]+)?(?:\-page\-([0-9]+))\.html$ main.gambas.cgi?action=categor
> ie&section=forge&id=$1&numpage=1 [QSA]
>         RewriteRule   ^code\-([0-9]+)-ajoutercommen
> taire(?:\-[a-z0-9\-]+)?\.html$  main.gambas.cgi?section=forge&action=addcomment&id=$1
> [QSA]
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user