Comments (13)
Fixed (45df610). Please test it. Thank you! :)
from brookframework.
Sorry for the late reply, just remembered about this issue. The charset problem is fixed, but action already exists and binary execution problem is still there. The problem is still exactly as above. Moreover, by default, the project is not runnable even though I choose FastCGI. Is this intended?
from brookframework.
Closed by mistake
from brookframework.
No problem friend. These days I was away partying the Christmas. :)
Finally, the problem in action editor is solved (e3f5567). Now, I'm using the "Index" instead "Data" property.
About the "error 88", what's your environment (Linux, Windows, Apache ...)? I'm using Apache (32/64bit) on Linux and Windows, and it works fine with CGI and/or FastCGI.
The intended is to disable the "Run" button. You could to run a CGI inside the IDE? I've never tried it, because the CGI/FCGI depend of environment variables to work.
from brookframework.
OK, I'll pull again.
About error 88, I'm using Nginx on 32-bit Linux. Nginx doesn't manage the FastCGI binary by itself and we have to start the binary ourselves. Moreover, I'll need to run from IDE in order to debug. That's what I did with my fpweb projects.
from brookframework.
If the error in the action editor occurs again, we will solve it.
I have the Linux Mint (64bit), I'll try to install Nginx to reproduce the problem with error 88.
So, by default, fpWeb keeps the Run button enabled? If yes, I may change the brookex to maintain compatibility with fpWeb.
from brookframework.
Yes, even it's enabled for CGI, though it's relevant only in FastCGI.
from brookframework.
Hm... so it would be interesting to let enabled for CGI and FastCGI?
from brookframework.
[I'm downloading the Nginx for Windows to reproduce the error 88: http://nginx.org/en/docs/windows.html]
from brookframework.
I'd say let it enabled for FastCGI only.
You don't need to download any webserver, since the error happens immediately after starting the binary.
from brookframework.
Now the Run button is enabled for FastCGI applications (a8e0cfc). Thank you!
Yes, after starting the binary, I got:
C:\Users\silvioprog\Desktop\fcgi>cgi1.exe
Exception at 00434BAC: Exception:
Failed to open input-handle passed from server. Socket Error: 6.
But...
For FastCGI applications, maybe you must be specify the port. Please test this demo, I specified a port (2015) to it:
http://www.sendspace.com/file/mwm0ct
In two pictures below, see FastCGI working:
1 - http://imagebin.org/240843
2 - http://imagebin.org/240844
I think that it will work now for you. :)
from brookframework.
YES!!! IT WORKS!!! I'll keep exploring the framework, it's damn big.
Now that you know FastCGI requires Port to be set, would you modify the generated project? IMO, it's better to put the Port initialization in the .lpr, but if you want to put it in Brokers (I don't really know what's this unit's job actually, request broker?), that's fine.
from brookframework.
Nice job guy! 👍
The Port is necessary when you use FastCGI manually (starting the executable via terminal). Using automatically (for example, in Apache) the Port used is the default.
In Brokers unit you configure any part of your application. The idea is exactly have a central point for you find everything related to initializations and settings. :)
E.g (pseudo example):
unit Brokers;
{$mode objfpc}{$H+}
interface
uses
BrookApplication, BrookFCLCGIBroker, BrookSQLdbBroker, SQLite3Conn,
BrookUtils, Classes, SysUtils;
implementation
var
App: TBrookCGIApplication;
EnvVars: TStringList;
initialization
EnvVars := TStringList.Create;
App := TBrookCGIApplication(BrookApp.Instance);
App.GetCGIVarList(EnvVars);
App.Email := 'webmaster@localhost';
App.ApplicationURL := 'http://localhost';
App.RedirectOnError := True;
App.RedirectOnErrorURL := 'http://localhost/500.html';
BrookSettings.Configuration := 'db.cfg';
BrookSettings.Page404 :=
'<html><head><title>Page not found</title></head><body>' +
'<h1>404 - Page not found</h1></body></html>';
finalization
FreeAndNil(EnvVars);
end.
from brookframework.
Related Issues (20)
- Why plugins projects on github to brookframework is closing? HOT 4
- Telegram plugin for brookframework HOT 15
- i18n HOT 4
- Version 4 ? HOT 14
- libbrook.pas in Source HOT 3
- tardigrade demos throwing errors in libbrook HOT 4
- Server requirements? HOT 4
- dopf & LastInsertID HOT 4
- httprouter.lpr throwing error HOT 2
- How am I supposed to free worker thread in brook daemon? HOT 9
- Use legacy application with tardigrade HOT 19
- CPU Activity is high for tardigrade projects BROOK4 HOT 4
- More documentation HOT 1
- Can't get POST request data HOT 13
- Brookframework with sagui (legacy) HOT 11
- HTTP Client HOT 1
- Where did the captcha plugin for 4.0 go? HOT 1
- Some suggestion about JTemplate? HOT 3
- [IDEA] New repository HOT 1
- EBrookHTTPServer: Failed to send data in request for HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from brookframework.