Has anybody created the server side for JSON with Harbour/xHarbour and Fivewin?
Is this possible?
Any examples of communicating with any JSON service from a Harbour/xHarbour and Fivewin application?
I have tried this quite a bit using oHttp, but as of yet to succeed.
Byron ...
JSON Server Side with FiveWin
-
- Posts: 388
- Joined: Sun Nov 06, 2005 3:55 pm
- Location: Southern California, USA
- Contact:
-
- Posts: 989
- Joined: Thu Nov 24, 2005 3:01 pm
- Location: Madrid, España
Re: JSON Server Side with FiveWin
Hi Byron,
AFAIK, two choices for the server side comes to mind: writing a CGI program and use it together with Apache or another web server, or using Harbour's Httpd and build the whole server by yourself.
Depending on the requirements, you should use one of another. Using CGI is easier, you don't have to deal with the issues related to the http protocol that is up to the webserver, and you just write the specific code to produce the JSON response.
On the other hand, Harbour's httpd may be a little bit more complex but it will be faster, and you can have full control of the whole thing.
I have no examples for JSON in Harbour, i've used it only in php apps.
From the client's POV, you can 'consume' any kind of services including XML, JSON or whatever, using the TIP library from Harbour's project, or using libCurl. I'm currently using libCurl with great success, connecting to AEAT services (the spanish IRS).
JSON processing should be easy, there are function already written in the Harbour Project to deal with it.
May be you can tell a little bit more about your project so having a closer idea may help to be more specific in the answer.
AFAIK, two choices for the server side comes to mind: writing a CGI program and use it together with Apache or another web server, or using Harbour's Httpd and build the whole server by yourself.
Depending on the requirements, you should use one of another. Using CGI is easier, you don't have to deal with the issues related to the http protocol that is up to the webserver, and you just write the specific code to produce the JSON response.
On the other hand, Harbour's httpd may be a little bit more complex but it will be faster, and you can have full control of the whole thing.
I have no examples for JSON in Harbour, i've used it only in php apps.
From the client's POV, you can 'consume' any kind of services including XML, JSON or whatever, using the TIP library from Harbour's project, or using libCurl. I'm currently using libCurl with great success, connecting to AEAT services (the spanish IRS).
JSON processing should be easy, there are function already written in the Harbour Project to deal with it.
May be you can tell a little bit more about your project so having a closer idea may help to be more specific in the answer.
Saludos
Carlos Mora
http://harbouradvisor.blogspot.com/
StackOverflow http://stackoverflow.com/users/549761/carlos-mora
“If you think education is expensive, try ignorance"
Carlos Mora
http://harbouradvisor.blogspot.com/
StackOverflow http://stackoverflow.com/users/549761/carlos-mora
“If you think education is expensive, try ignorance"
-
- Posts: 388
- Joined: Sun Nov 06, 2005 3:55 pm
- Location: Southern California, USA
- Contact:
Re: JSON Server Side with FiveWin
I'm currently using xHarbour, where can I get a copy of the Tip Library, and a listing of its contents (classes, methods, and functions). I never heard of this.
Thanks,
Thanks,
Thanks,
Byron Hopp
Matrix Computer Services
Byron Hopp
Matrix Computer Services
-
- Posts: 388
- Joined: Sun Nov 06, 2005 3:55 pm
- Location: Southern California, USA
- Contact:
Re: JSON Server Side with FiveWin
To better describe my project. I was hoping to build a generic JSON interface to work with MS Sql. In my case I was describing the data with a little more detail to enable the creation of a recordset on the remote side and I would fill the disconnected recordset with the json data. I started with just reading data from an incremental search we were working with. The speed was suprisingly fast. Ran into some problems with special characters, never solved.
I have used SOAP in other occasions but because Microsoft stopped supporting the SOAP Toolkit some of my customers show concern.
I never liked having to install the toolkit, I always wanted to use vanilla Harbour / xHarbour / Fivewin when utilizing SOAP, or JSON.
I have used SOAP in other occasions but because Microsoft stopped supporting the SOAP Toolkit some of my customers show concern.
I never liked having to install the toolkit, I always wanted to use vanilla Harbour / xHarbour / Fivewin when utilizing SOAP, or JSON.
Thanks,
Byron Hopp
Matrix Computer Services
Byron Hopp
Matrix Computer Services
-
- Posts: 989
- Joined: Thu Nov 24, 2005 3:01 pm
- Location: Madrid, España
Re: JSON Server Side with FiveWin
Hi Byron,
I think TIP library started being part of xHarbour Contribs and then it moved to Harbour. Since then it improved a *lot*.
You can checkout the SVN/GIT Harbour repository, in the contrib directory you will find great pieces of brilliant code, I _DO_ recommend you to take a look.
In order to your concepts about a JSON client to a MsSQL server, I have in mind more or less the same, but based in MySQL.
I built my own classes to simplyfy the access to a local server, and the next step will be (in a not so near future) to rewrite the connection part using a php counterpart on the server side, so i can use the benefits of ssl and https in the connection.
byron.hopp wrote:I'm currently using xHarbour, where can I get a copy of the Tip Library, and a listing of its contents (classes, methods, and functions). I never heard of this.
Thanks,
I think TIP library started being part of xHarbour Contribs and then it moved to Harbour. Since then it improved a *lot*.
You can checkout the SVN/GIT Harbour repository, in the contrib directory you will find great pieces of brilliant code, I _DO_ recommend you to take a look.
In order to your concepts about a JSON client to a MsSQL server, I have in mind more or less the same, but based in MySQL.
I built my own classes to simplyfy the access to a local server, and the next step will be (in a not so near future) to rewrite the connection part using a php counterpart on the server side, so i can use the benefits of ssl and https in the connection.
Saludos
Carlos Mora
http://harbouradvisor.blogspot.com/
StackOverflow http://stackoverflow.com/users/549761/carlos-mora
“If you think education is expensive, try ignorance"
Carlos Mora
http://harbouradvisor.blogspot.com/
StackOverflow http://stackoverflow.com/users/549761/carlos-mora
“If you think education is expensive, try ignorance"
- Enrico Maria Giordano
- Posts: 8753
- Joined: Thu Oct 06, 2005 8:17 pm
- Location: Roma - Italia
- Has thanked: 1 time
- Been thanked: 4 times
- Contact:
Re: JSON Server Side with FiveWin
Byron,
The lib is tip.lib.
EMG
byron.hopp wrote:I'm currently using xHarbour, where can I get a copy of the Tip Library, and a listing of its contents (classes, methods, and functions). I never heard of this.
The lib is tip.lib.
EMG