Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-28 Thread silvioprog
2014-02-27 4:53 GMT-03:00 Giuseppe glpu...@gmail.com:
[...]

 /
 Open \brookframework\demos\simple\entity project
 Build.
 Copy to cg1.bf to cgi-bin folder
 http://localhost:8080/cgi-bin/cgi1.bf returns HTTP method not allowed
 for the requested resource.
 Didn't worked (with BrookFCLCGIBroker, either with BrookFCLHttpAppBroker)


Well, see:

  TMyAction = class(specialize TBrookEntityActionTMyType)
  public
procedure Post; override;  POST
  end;

ie, you can't open it directly in the URL of Chrome (GET), you need to call
it via POST method (using rest client).


 //
 Created postgres database with table person.
 Open brookframework/demos/db/dopf/cgi1.lpi
 Changed db configuration from dbutils.pas pointing to my database
 Copied all postgres dll from postgres/bin folder to project folder.
 http://localhost returns HTTP method not allowed for the requested
 resource.


Oh, you can't open it directly in the URL of Chrome too calling only
localhost. Compile your project using CGI broker, copy your executable to
the cgi-bin folder, copy form.html to the htdocs folder, after, call: 
http://localhost/form.html;. Using this form it will do a request using
POST method.

-- 
Silvio Clécio
My public projects - github.com/silvioprog
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread Giuseppe

El 26/02/2014 4:57, silvioprog escribió:
2014-02-25 18:22 GMT-03:00 Giuseppe glpu...@gmail.com 
mailto:glpu...@gmail.com:


Hi all,

I'm trying demos on Brook 3 (from github), and simple demos works
fine, but with DB demos I get the error:
Error 405
HTTP method not allowed for the requested resource.

Some idea?

Regards.


Oh, is you Giu of Lazarus forum? Sorry, I could only see it now hehe...

Please delete all old files, like .ppu etc. These examples are working 
fine, I tested it on Windows and Linux.


If problem persists, please say step by step how you are doing the 
test as well as your environment.




Yes, I am.
Lazarus 1.2RC2, FPC 2.6.2 rev.43696, 32 bits.
brookframework downloaded from github.
Opened brookex and brookrt lpk and compiled.
dopf downloaded from github, opened and compiled.

Open brookframework\demos\simple\helloworld\cgi project
Build.
Copy to cgi-bin folder
http://localhost:8080/cgi-bin/cgi1.bf returns Hello World!

Open brookframework\demos\simple\static project
Build.
Execute test.exe
http://localhost:8000/index returns static page opening a dialog as 
expected.


Open \brookframework\demos\simple\entity project
Build.
Copy to cg1.bf to cgi-bin folder
http://localhost:8080/cgi-bin/cgi1.bf returns HTTP method not allowed 
for the requested resource.



Created postgres database with table person.
Open brookframework/demos/db/dopf/cgi1.lpi
Changed db configuration from dbutils.pas pointing to my database
Copied all postgres dll from postgres/bin folder to project folder.
Changed on Brokers.pas BrookFCLCGIBroker - BrookFCLHttpAppBroker
http://localhost returns HTTP method not allowed for the requested 
resource.


Shell:
D:\DevAux\LazComp\brookframework\demos\db\dopfcgi1.exe
exception at 0043A79E:
Missing HTTP protocol version in request.










--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread Michael Van Canneyt



On Wed, 26 Feb 2014, Giuseppe wrote:


El 26/02/2014 4:57, silvioprog escribió:
  2014-02-25 18:22 GMT-03:00 Giuseppe glpu...@gmail.com:
Hi all,

I'm trying demos on Brook 3 (from github), and simple demos works 
fine, but
with DB demos I get the error:
Error 405
HTTP method not allowed for the requested resource.

Some idea?

Regards.


Oh, is you Giu of Lazarus forum? Sorry, I could only see it now hehe...

Please delete all old files, like .ppu etc. These examples are working fine, I 
tested it on
Windows and Linux.

If problem persists, please say step by step how you are doing the test as well 
as your
environment.


Yes, I am.
Lazarus 1.2RC2, FPC 2.6.2 rev.43696, 32 bits.


It is a known bug in FPC 2.6.2; 
you must use FPC 2.6.4 (building has started for this version) or FPC trunk.


Michael.--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread Giuseppe

El 26/02/2014 10:44, Michael Van Canneyt escribió:



On Wed, 26 Feb 2014, Giuseppe wrote:


El 26/02/2014 4:57, silvioprog escribió:
  2014-02-25 18:22 GMT-03:00 Giuseppe glpu...@gmail.com:
Hi all,

I'm trying demos on Brook 3 (from github), and simple 
demos works fine, but

with DB demos I get the error:
Error 405
HTTP method not allowed for the requested resource.

Some idea?

Regards.


Oh, is you Giu of Lazarus forum? Sorry, I could only see it now hehe...

Please delete all old files, like .ppu etc. These examples are 
working fine, I tested it on

Windows and Linux.

If problem persists, please say step by step how you are doing the 
test as well as your

environment.


Yes, I am.
Lazarus 1.2RC2, FPC 2.6.2 rev.43696, 32 bits.


It is a known bug in FPC 2.6.2; you must use FPC 2.6.4 (building has 
started for this version) or FPC trunk.


Michael.


Hi Michael,

I downloaded 2.7.x source (I didn't found 2.6.4 builds), builded and 
pointed my Laz to this FPC (I think I did it ok).
Lazarus then rebuilded again project and dependants (brook, ...) but 
getting same error.


Now I tried to build 2.6.4, but getting an error :(

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread silvioprog
2014-02-26 6:31 GMT-03:00 Giuseppe glpu...@gmail.com:

  El 26/02/2014 4:57, silvioprog escribió:

  2014-02-25 18:22 GMT-03:00 Giuseppe glpu...@gmail.com:

  Hi all,

 I'm trying demos on Brook 3 (from github), and simple demos works fine,
 but with DB demos I get the error:
 Error 405
 HTTP method not allowed for the requested resource.

 Some idea?

 Regards.


  Oh, is you Giu of Lazarus forum? Sorry, I could only see it now hehe...

  Please delete all old files, like .ppu etc. These examples are working
 fine, I tested it on Windows and Linux.

  If problem persists, please say step by step how you are doing the test
 as well as your environment.

 Yes, I am.
 Lazarus 1.2RC2, FPC 2.6.2 rev.43696, 32 bits.
 brookframework downloaded from github.
 Opened brookex and brookrt lpk and compiled.
 dopf downloaded from github, opened and compiled.

 Open brookframework\demos\simple\helloworld\cgi project
 Build.
 Copy to cgi-bin folder
 http://localhost:8080/cgi-bin/cgi1.bf returns Hello World!

 Open brookframework\demos\simple\static project
 Build.
 Execute test.exe
 http://localhost:8000/index returns static page opening a dialog as
 expected.

 Open \brookframework\demos\simple\entity project
 Build.
 Copy to cg1.bf to cgi-bin folder
 http://localhost:8080/cgi-bin/cgi1.bf returns HTTP method not allowed
 for the requested resource.

 Created postgres database with table person.
 Open brookframework/demos/db/dopf/cgi1.lpi
 Changed db configuration from dbutils.pas pointing to my database
 Copied all postgres dll from postgres/bin folder to project folder.
 Changed on Brokers.pas BrookFCLCGIBroker - BrookFCLHttpAppBroker
 http://localhost returns HTTP method not allowed for the requested
 resource.

 Shell:
 D:\DevAux\LazComp\brookframework\demos\db\dopfcgi1.exe
 exception at 0043A79E:
 Missing HTTP protocol version in request.


Exactly how Canneyt said: It is a known bug in FPC 2.6.2.

RESTful uses all HTTP methods (GET/POST/PUT/DELETE), and old FCL-web does
not supports it, but it is fixed in new FCL-web.

Try it now in a new environment, I'll show my environment to you:

0. use a stable release of Lazarus/FPC: Lazarus 1.0.14 r43446 FPC 2.6.2
i386-win32-win32/win64 (http://sourceforge.net/projects/lazarus);
1. install Apache server in your system (
http://archive.apache.org/dist/httpd/binaries/win32/httpd-2.2.22-win32-x86-openssl-0.9.8t.msi),
choosing the c:\websrv folder instead of default Apache folder in
Program Files, after install, you will have the c:\websrv\cgi-bin
folder;
2. undo all changes in your Brook demos (in SmartGIT, I select all files
and use Revert button), and keep using BrookFCLCGIBroker instead of
BrookFCLHTTPAppBroker broker that you changed;
3. install the best browser in your system: Google Chrome;
4. install a complete REST client plugin in your Chrome:
https://chrome.google.com/webstore/detail/advanced-rest-client/hgmloofddffdnphfgcellkdfbfbjeloo
;
5. with your database and person table already created, open the project
C:\repository\git\brookframework\demos\db\rest\cgi1.lpi and, in your
project options (Ctrl+Shift+F11), set c:\websrv\cgi-bin\cgi1.bf in
Compiler Options  Paths  Target file name, and uncheck the Apply
conventions option;
6. compile your project (Ctrl+F9);
7. configure your REST plugin to: http://imagebin.org/295955;
8. enjoy;

-- 
Silvio Clécio
My public projects - github.com/silvioprog
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread Giuseppe
Thanks Silvio, 

I Will try but, why you don't get error using FPC 2.6.2? Don't understand :/

Enviado desde mi iPad

/Giuseppe

 El 26/02/2014, a las 15:04, silvioprog silviop...@gmail.com escribió:
 
 2014-02-26 6:31 GMT-03:00 Giuseppe glpu...@gmail.com:
 El 26/02/2014 4:57, silvioprog escribió:
 2014-02-25 18:22 GMT-03:00 Giuseppe glpu...@gmail.com:
 Hi all,
 
 I'm trying demos on Brook 3 (from github), and simple demos works fine, 
 but with DB demos I get the error:
 Error 405
 HTTP method not allowed for the requested resource.
 
 Some idea?
 
 Regards.
 
 
 Oh, is you Giu of Lazarus forum? Sorry, I could only see it now hehe...
 
 Please delete all old files, like .ppu etc. These examples are working 
 fine, I tested it on Windows and Linux.
 
 If problem persists, please say step by step how you are doing the test as 
 well as your environment.
 Yes, I am.
 Lazarus 1.2RC2, FPC 2.6.2 rev.43696, 32 bits.
 brookframework downloaded from github.
 Opened brookex and brookrt lpk and compiled.
 dopf downloaded from github, opened and compiled.
 
 Open brookframework\demos\simple\helloworld\cgi project
 Build.
 Copy to cgi-bin folder
 http://localhost:8080/cgi-bin/cgi1.bf returns Hello World!
 
 Open brookframework\demos\simple\static project
 Build.
 Execute test.exe
 http://localhost:8000/index returns static page opening a dialog as expected.
 
 Open \brookframework\demos\simple\entity project
 Build.
 Copy to cg1.bf to cgi-bin folder
 http://localhost:8080/cgi-bin/cgi1.bf returns HTTP method not allowed for 
 the requested resource.
 
 Created postgres database with table person.
 Open brookframework/demos/db/dopf/cgi1.lpi
 Changed db configuration from dbutils.pas pointing to my database
 Copied all postgres dll from postgres/bin folder to project folder.
 Changed on Brokers.pas BrookFCLCGIBroker - BrookFCLHttpAppBroker
 http://localhost returns HTTP method not allowed for the requested 
 resource.
 
 Shell:
 D:\DevAux\LazComp\brookframework\demos\db\dopfcgi1.exe
 exception at 0043A79E:
 Missing HTTP protocol version in request.
 
 
 Exactly how Canneyt said: It is a known bug in FPC 2.6.2.
 
 RESTful uses all HTTP methods (GET/POST/PUT/DELETE), and old FCL-web does not 
 supports it, but it is fixed in new FCL-web.
 
 Try it now in a new environment, I'll show my environment to you:
 
 0. use a stable release of Lazarus/FPC: Lazarus 1.0.14 r43446 FPC 2.6.2 
 i386-win32-win32/win64 (http://sourceforge.net/projects/lazarus);
 1. install Apache server in your system 
 (http://archive.apache.org/dist/httpd/binaries/win32/httpd-2.2.22-win32-x86-openssl-0.9.8t.msi),
  choosing the c:\websrv folder instead of default Apache folder in Program 
 Files, after install, you will have the c:\websrv\cgi-bin folder;
 2. undo all changes in your Brook demos (in SmartGIT, I select all files and 
 use Revert button), and keep using BrookFCLCGIBroker instead of 
 BrookFCLHTTPAppBroker broker that you changed;
 3. install the best browser in your system: Google Chrome;
 4. install a complete REST client plugin in your Chrome: 
 https://chrome.google.com/webstore/detail/advanced-rest-client/hgmloofddffdnphfgcellkdfbfbjeloo;
 5. with your database and person table already created, open the project 
 C:\repository\git\brookframework\demos\db\rest\cgi1.lpi and, in your 
 project options (Ctrl+Shift+F11), set c:\websrv\cgi-bin\cgi1.bf in 
 Compiler Options  Paths  Target file name, and uncheck the Apply 
 conventions option;
 6. compile your project (Ctrl+F9);
 7. configure your REST plugin to: http://imagebin.org/295955;
 8. enjoy;
 
 -- 
 Silvio Clécio
 My public projects - github.com/silvioprog
 --
 ___
 Lazarus mailing list
 Lazarus@lists.lazarus.freepascal.org
 http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread silvioprog
2014-02-26 11:16 GMT-03:00 Giuseppe glpu...@gmail.com:

 Thanks Silvio,

 I Will try but, why you don't get error using FPC 2.6.2? Don't understand
 :/

 Enviado desde mi iPad

 /Giuseppe


Simple, because I need to use HTTPS in my personal projects, then I'm using
[Fast]CGI instead of embedded server in FPC 2.6.2. Currently, I'm using
embedded server only to debug my projects, but, in future, I'll use
embedded server in production too.

-- 
Silvio Clécio
My public projects - github.com/silvioprog
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread Giuseppe



Exactly how Canneyt said: It is a known bug in FPC 2.6.2.

RESTful uses all HTTP methods (GET/POST/PUT/DELETE), and old FCL-web 
does not supports it, but it is fixed in new FCL-web.


Try it now in a new environment, I'll show my environment to you:

0. use a stable release of Lazarus/FPC: Lazarus 1.0.14 r43446 FPC 
2.6.2 i386-win32-win32/win64 (http://sourceforge.net/projects/lazarus);
1. install Apache server in your system 
(http://archive.apache.org/dist/httpd/binaries/win32/httpd-2.2.22-win32-x86-openssl-0.9.8t.msi), 
choosing the c:\websrv folder instead of default Apache folder in 
Program Files, after install, you will have the c:\websrv\cgi-bin 
folder;
2. undo all changes in your Brook demos (in SmartGIT, I select all 
files and use Revert button), and keep using BrookFCLCGIBroker 
instead of BrookFCLHTTPAppBroker broker that you changed;

3. install the best browser in your system: Google Chrome;
4. install a complete REST client plugin in your Chrome: 
https://chrome.google.com/webstore/detail/advanced-rest-client/hgmloofddffdnphfgcellkdfbfbjeloo;
5. with your database and person table already created, open the 
project C:\repository\git\brookframework\demos\db\rest\cgi1.lpi and, 
in your project options (Ctrl+Shift+F11), set 
c:\websrv\cgi-bin\cgi1.bf http://cgi1.bf in Compiler Options  
Paths  Target file name, and uncheck the Apply conventions option;

6. compile your project (Ctrl+F9);
7. configure your REST plugin to: http://imagebin.org/295955;
8. enjoy;

Yes this works.

Then, to build dinamic sites like Anderson do in his videos, I have to 
wait to 2.6.4 to get Brook working again as before. True? Meanwhile, I 
can use it just as REST server.
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread silvioprog
2014-02-26 13:27 GMT-03:00 Giuseppe glpu...@gmail.com:
[...]

 Yes this works.

 Then, to build dinamic sites like Anderson do in his videos, I have to
 wait to 2.6.4 to get Brook working again as before. True? Meanwhile, I can
 use it just as REST server.


With Anderson's videos you will have a basic knowledge of Brook 2.6. I
believe that he will have to make updated videos, if he want to use new
Brook features.

No. Currently Brook compile and works fine with FPC 2.6.2+. A bit
limitation is only in embedded server, because it does not support all HTTP
methods in this version, but it is already fixed in new FPC.

I use new Brook with FPC 2.6.2 and FastCGI in my projects, and it works
fine.

-- 
Silvio Clécio
My public projects - github.com/silvioprog
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread Giuseppe


 El 26/02/2014, a las 20:47, silvioprog silviop...@gmail.com escribió:
 
 2014-02-26 13:27 GMT-03:00 Giuseppe glpu...@gmail.com:
 [...]
 Yes this works.
 
 Then, to build dinamic sites like Anderson do in his videos, I have to wait 
 to 2.6.4 to get Brook working again as before. True? Meanwhile, I can use it 
 just as REST server.
 
 With Anderson's videos you will have a basic knowledge of Brook 2.6. I 
 believe that he will have to make updated videos, if he want to use new Brook 
 features.
 
 No. Currently Brook compile and works fine with FPC 2.6.2+. A bit limitation 
 is only in embedded server, because it does not support all HTTP methods in 
 this version, but it is already fixed in new FPC.
 
 I use new Brook with FPC 2.6.2 and FastCGI in my projects, and it works fine.


But I get the error of the topic deploying the CGI, with dopf and sqldb demos.

Regards.
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread silvioprog
2014-02-26 17:52 GMT-03:00 Giuseppe glpu...@gmail.com:

 El 26/02/2014, a las 20:47, silvioprog silviop...@gmail.com escribió:

 2014-02-26 13:27 GMT-03:00 Giuseppe glpu...@gmail.com:
 [...]

 Yes this works.

 Then, to build dinamic sites like Anderson do in his videos, I have to
 wait to 2.6.4 to get Brook working again as before. True? Meanwhile, I can
 use it just as REST server.


 With Anderson's videos you will have a basic knowledge of Brook 2.6. I
 believe that he will have to make updated videos, if he want to use new
 Brook features.

 No. Currently Brook compile and works fine with FPC 2.6.2+. A bit
 limitation is only in embedded server, because it does not support all HTTP
 methods in this version, but it is already fixed in new FPC.

 I use new Brook with FPC 2.6.2 and FastCGI in my projects, and it works
 fine.

 But I get the error of the topic deploying the CGI, with dopf and sqldb
 demos.

 Regards.


Using FPC 2.6.2 you get the invalid request method error only in embedded
mode, in (Fast)CGI it is OK. Again: your db erros is not related with
FCL-Web and/or Brook, it is related with your 32/64 mixed confusion
architecture, ie, your architecture is 64 but your DLL is 32 etc.

-- 
Silvio Clécio
My public projects - github.com/silvioprog
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread Giuseppe

 El 26/02/2014, a las 22:26, silvioprog silviop...@gmail.com escribió:
 
 2014-02-26 17:52 GMT-03:00 Giuseppe glpu...@gmail.com:
 
 El 26/02/2014, a las 20:47, silvioprog silviop...@gmail.com escribió:
 
 2014-02-26 13:27 GMT-03:00 Giuseppe glpu...@gmail.com:
 [...]
 Yes this works.
 
 Then, to build dinamic sites like Anderson do in his videos, I have to 
 wait to 2.6.4 to get Brook working again as before. True? Meanwhile, I can 
 use it just as REST server.
 
 With Anderson's videos you will have a basic knowledge of Brook 2.6. I 
 believe that he will have to make updated videos, if he want to use new 
 Brook features.
 
 No. Currently Brook compile and works fine with FPC 2.6.2+. A bit 
 limitation is only in embedded server, because it does not support all HTTP 
 methods in this version, but it is already fixed in new FPC.
 
 I use new Brook with FPC 2.6.2 and FastCGI in my projects, and it works 
 fine.
 But I get the error of the topic deploying the CGI, with dopf and sqldb 
 demos.
 
 Regards.
 
 
 Using FPC 2.6.2 you get the invalid request method error only in embedded 
 mode, in (Fast)CGI it is OK. Again: your db erros is not related with FCL-Web 
 and/or Brook, it is related with your 32/64 mixed confusion architecture, 
 ie, your architecture is 64 but your DLL is 32 etc.

No, dll error was solved. I get this error method not allowed with embedded 
and as cgi too. Don't know howto build and deploy a fcgi --
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread silvioprog
2014-02-26 18:36 GMT-03:00 Giuseppe glpu...@gmail.com:

 El 26/02/2014, a las 22:26, silvioprog silviop...@gmail.com escribió:

 2014-02-26 17:52 GMT-03:00 Giuseppe glpu...@gmail.com:

 El 26/02/2014, a las 20:47, silvioprog silviop...@gmail.com escribió:

 2014-02-26 13:27 GMT-03:00 Giuseppe glpu...@gmail.com:
 [...]

 Yes this works.

 Then, to build dinamic sites like Anderson do in his videos, I have to
 wait to 2.6.4 to get Brook working again as before. True? Meanwhile, I can
 use it just as REST server.


 With Anderson's videos you will have a basic knowledge of Brook 2.6. I
 believe that he will have to make updated videos, if he want to use new
 Brook features.

 No. Currently Brook compile and works fine with FPC 2.6.2+. A bit
 limitation is only in embedded server, because it does not support all HTTP
 methods in this version, but it is already fixed in new FPC.

 I use new Brook with FPC 2.6.2 and FastCGI in my projects, and it works
 fine.

 But I get the error of the topic deploying the CGI, with dopf and sqldb
 demos.

 Regards.


 Using FPC 2.6.2 you get the invalid request method error only in
 embedded mode, in (Fast)CGI it is OK. Again: your db erros is not related
 with FCL-Web and/or Brook, it is related with your 32/64 mixed confusion
 architecture, ie, your architecture is 64 but your DLL is 32 etc.


 No, dll error was solved. I get this error method not allowed with
 embedded and as cgi too. Don't know howto build and deploy a fcgi.


I don't know if our environment is similar to reproduce it. My environment
is:

Windows 8, 64 bit.
Lazarus 1.0.14 r43446 FPC 2.6.2 i386-win32-win32/win64.
Brook via trunk.
PostgreSQL 8.4, 32 bit.
Apache/2.2.22 (Win32), Server built:   Jan 28 2012 11:16:39.

Are you executing the demo using correct Url/HTTP request methods?

-- 
Silvio Clécio
My public projects - github.com/silvioprog
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-26 Thread Giuseppe

 I don't know if our environment is similar to reproduce it. My environment is:
 
 Windows 8, 64 bit.
 Lazarus 1.0.14 r43446 FPC 2.6.2 i386-win32-win32/win64.
 Brook via trunk.
 PostgreSQL 8.4, 32 bit.
 Apache/2.2.22 (Win32), Server built:   Jan 28 2012 11:16:39.
 
 Are you executing the demo using correct Url/HTTP request methods?

It's similar, just Laz version different. As I mentioned on previous mail...

Lazarus 1.2RC2, FPC 2.6.2 rev.43696, 32 bits.
brookframework downloaded from github.
Opened brookex and brookrt lpk and compiled.
dopf downloaded from github, opened and compiled.


Open brookframework\demos\simple\helloworld\cgi project
Build.
Copy to cgi-bin folder
http://localhost:8080/cgi-bin/cgi1.bf returns Hello World!
This works

/
Open brookframework\demos\simple\static project
Build.
Execute test.exe
http://localhost:8000/index returns static page opening a dialog as expected.
This works

/
Open \brookframework\demos\simple\entity project
Build.
Copy to cg1.bf to cgi-bin folder
http://localhost:8080/cgi-bin/cgi1.bf returns HTTP method not allowed for the 
requested resource.
Didn't worked (with BrookFCLCGIBroker, either with BrookFCLHttpAppBroker)

//
Created postgres database with table person.
Open brookframework/demos/db/dopf/cgi1.lpi
Changed db configuration from dbutils.pas pointing to my database
Copied all postgres dll from postgres/bin folder to project folder.
http://localhost returns HTTP method not allowed for the requested resource.

Shell:
D:\DevAux\LazComp\brookframework\demos\db\dopfcgi1.exe
exception at 0043A79E:
Missing HTTP protocol version in request.

Didn't worked (with BrookFCLCGIBroker, either with BrookFCLHttpAppBroker)

//
Open brookframework\demos\db\rest project
Build.
Copy to rest.bf to cgi-bin folder
http://localhost:8080/cgi-bin/rest.bf returns data as expected. 
Works from advanced rest client on chrome too
This works as embbebed too AFAIR.

Regards.


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-25 Thread Giuseppe

Hi all,

I'm trying demos on Brook 3 (from github), and simple demos works fine, 
but with DB demos I get the error:

Error 405
HTTP method not allowed for the requested resource.

Some idea?

Regards.
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] [Brook] HTTP method not allowed for the requested resource

2014-02-25 Thread silvioprog
2014-02-25 18:22 GMT-03:00 Giuseppe glpu...@gmail.com:

  Hi all,

 I'm trying demos on Brook 3 (from github), and simple demos works fine,
 but with DB demos I get the error:
 Error 405
 HTTP method not allowed for the requested resource.

 Some idea?

 Regards.


Oh, is you Giu of Lazarus forum? Sorry, I could only see it now hehe...

Please delete all old files, like .ppu etc. These examples are working
fine, I tested it on Windows and Linux.

If problem persists, please say step by step how you are doing the test as
well as your environment.

-- 
Silvio Clécio
My public projects - github.com/silvioprog
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus