Site Harbour?
Moderador: Moderadores
- JoséQuintas
- Administrador

- Mensagens: 20267
- Registrado em: 26 Fev 2007 11:59
- Localização: São Paulo-SP
Site Harbour?
Tanta coisa pra usar Harbour na internet..... mas...
Uma coisa diferente:
parte 1
Editar/cadastrar pelo Harbour
Uma coisa diferente:
parte 1
Editar/cadastrar pelo Harbour
José M. C. Quintas
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
- JoséQuintas
- Administrador

- Mensagens: 20267
- Registrado em: 26 Fev 2007 11:59
- Localização: São Paulo-SP
Site Harbour?
Parte 2:
No site usar o MySQL
No site usar o MySQL
José M. C. Quintas
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
- JoséQuintas
- Administrador

- Mensagens: 20267
- Registrado em: 26 Fev 2007 11:59
- Localização: São Paulo-SP
Site Harbour?
Parte 3
Se divertir
Nota:
Por causa do Edge Chromium, tive que descobrir como embutir flash no html.
Resolvido assim.
Se divertir
Nota:
Por causa do Edge Chromium, tive que descobrir como embutir flash no html.
Resolvido assim.
José M. C. Quintas
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
- JoséQuintas
- Administrador

- Mensagens: 20267
- Registrado em: 26 Fev 2007 11:59
- Localização: São Paulo-SP
Site Harbour?
O fonte do cadastro.
Apenas pra curiosidade, não vai funcionar porque faltam minhas funções.
Apenas pra curiosidade, não vai funcionar porque faltam minhas funções.
Código: Selecionar todos
/*
PSITEJPA - SITE DA JPA
1997 - José Quintas
*/
#include "inkey.ch"
#include "hbclass.ch"
PROCEDURE pSiteJPA
LOCAL oFrm := JPSITEClass():New()
oFrm:Execute()
oFrm:cnSQL:CloseConnection()
RETURN
CREATE CLASS JPSITEClass INHERIT FrmCadastroClass
VAR cDataTable INIT "WEBSITE"
VAR cDataField INIT "IDSITE"
VAR axKeyValue INIT { 0 }
VAR cnSQL INIT ADOClass():New( AppcnInternet() )
VAR lWriteLog INIT .F.
METHOD Especifico( lExiste )
METHOD TelaDados( lEdit )
METHOD GridSelection()
ENDCLASS
METHOD GridSelection() CLASS JPSITEClass
LOCAL oTBrowse, cnSQL := ADOClass():New( AppcnInternet() )
WITH OBJECT cnSQL
:cSql := "SELECT IDSITE, SITITULO FROM WEBSITE ORDER BY IDSITE"
:Execute()
OTBrowse := { ;
{ "ID", { || Str( :Number( "IDSITE" ), 6 ) } }, ;
{ "TITULO", { || :String( "SITITULO", 100 ) } } }
BrowseADO( cnSQL, oTBrowse, "SITITULO", { || StrZero( :Number( "IDSITE" ), 6 ) } )
:CloseRecordset()
ENDWITH
RETURN NIL
METHOD Especifico( lExiste ) CLASS JPSITEClass
LOCAL GetList := {}, mIdSite
IF ::cOpc == "I"
mIdSite := 0
ELSE
mIdSite := ::axKeyValue[ 1 ]
ENDIF
@ ::RowIni(), 0 SAY ""
@ Row() + 1, 20 GET mIdSite PICTURE "@K 999999" VALID mIdSite > 0 .OR. ( ::cOpc == "I" .AND. mIdSite = 0 )
Mensagem( "Digite código, F9 pesquisa, ESC sai" )
READ
Mensagem()
IF LastKey() == K_ESC .OR. ( mIdSite == 0 .AND. ::cOpc != "I" )
RETURN .F.
ENDIF
::cnSQL:cSql := "SELECT COUNT(*) AS QTD FROM WEBSITE WHERE IDSITE=" + NumberSQL( mIdSite )
IF ! ::EspecificoExiste( lExiste, ::cnSQL:ReturnValueAndClose( "QTD" ) == 0 )
RETURN .F.
ENDIF
::axKeyValue := { mIdSite }
RETURN .T.
METHOD TelaDados( lEdit ) CLASS JPSITEClass
LOCAL GetList := {}
LOCAL msiTitulo := Space(100)
LOCAL msiData := Ctod("")
LOCAL msiTexto := Space(1)
LOCAL msiPriori := "5"
LOCAL msiInfAlt := ""
LOCAL mIdSite
hb_Default( @lEdit, .F. )
mIdSite := ::axKeyValue[ 1 ]
WITH OBJECT ::cnSQL
:Open()
:cSql := "SELECT SITITULO, SIDATA, SITEXTO, SIPRIORIDADE, SIINFALT FROM WEBSITE WHERE IDSITE = " + NumberSQL( mIdSite )
:Execute()
IF ! :Eof()
msiTitulo := :String( "SITITULO", 100 )
msiData := :Date( "SIDATA" )
msiTexto := :String( "SITEXTO" )
msiPriori := :String( "SIPRIORIDADE", 1 )
msiInfAlt := :String( "SIINFALT", 60 )
ENDIF
:CloseRecordset()
ENDWITH
@ ::RowIni(), 0 SAY ""
@ Row() + 1, 1 SAY "Num.Lancto.......:" GET mIdSite PICTURE "999999" WHEN .F.
@ Row() + 2, 1 SAY "Titulo...........:" GET msiTitulo
@ Row() + 1, 1 SAY "Data.............:" GET msiData
@ Row() + 1, 1 SAY "Prioridade.......:" GET msiPriori PICTURE "@K 999999"
KEYBOARD Chr( K_ESC )
MemoEdit( msiTexto, ::RowIni() + 6, 1, MaxRow() - 5, MaxCol(), .F. )
@ MaxRow() - 3, 1 SAY "Inf.Alt..........:" GET msiInfAlt WHEN .F.
//SetPaintGetList( GetList )
IF ! lEdit
CLEAR GETS
RETURN NIL
ENDIF
Mensagem( "Digite campos, F9 Pesquisa, ESC Sai" )
READ
Mensagem()
IF LastKey() == K_ESC
RETURN NIL
ENDIF
msiTexto := MemoEdit( msiTexto, ::RowIni() + 6, 1, MaxRow() - 5, MaxCol(), .T. )
IF LastKey() != K_ESC
WITH OBJECT ::cnSQL
:QueryCreate()
:QueryAdd( "SITITULO", Trim( msiTitulo ) )
:QueryAdd( "SIDATA", msiData )
:QueryAdd( "SITEXTO", Trim( msiTexto ) )
:QueryAdd( "SIPRIORIDADE", msiPriori )
IF ::cOpc == "I"
:QueryAdd( "SIINFINC", LogInfo() )
mIdSite := :QueryExecuteInsert( "WEBSITE" )
ELSE
:QueryAdd( "SIINFALT", LogInfo() )
:QueryExecuteUpdate( "WEBSITE", "IDSITE = " + NumberSql( mIdSite ) )
ENDIF
ENDWITH
ENDIF
::axKeyValue[ 1 ] := mIdSite
RETURN NIL
José M. C. Quintas
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
- JoséQuintas
- Administrador

- Mensagens: 20267
- Registrado em: 26 Fev 2007 11:59
- Localização: São Paulo-SP
Site Harbour?
Também só pra curiosidade, parte do fonte responsável por TODO site, em ASP
Só pra curiosidade.
Meu html é fraco, meu ASP também, mas quebra o galho.
Aí mistura o fonte VB/ASP com html.
ADO e MySQL, igual no aplicativo e no ASP.
Poderia ser Harbour na internet?
Precisaria autorização da hospedagem, e aprender o que já existe no ASP, então.... mais fácil usar ASP mesmo.
Código: Selecionar todos
cSql = "SELECT SIDATA, IDSITE, SITITULO, SITEXTO, SIPRIORIDADE FROM WEBSITE WHERE SITITULO LIKE ... ORDER BY SIPRIORIDADE, SIDATA DESC, IDSITE DESC LIMIT 30;"
oRegistro.Open cSql, oConexao
%>
<table width="100%" border="0" cellpadding="0" cellspacing="5" bordercolor="#000000" bordercolordark="#000000" bordercolorlight="#000000">
<%
DO WHILE NOT oRegistro.Eof
%>
<tr width="100%">
<td width="100%" bgcolor="#A4E1FF"></td>
<table style="border-top: 1 solid #777792; border-left: 1 solid #777792; border-right: 1 solid #777792; border-bottom: 1 solid #777792; width:100%">
<tr>
<td width="3%" bgcolor="#9CB8CF"><img src="/imagem/jpa40x40.jpg" width="32" height="32"></td>
<td width="97%" background="/imagem/bgnews.jpg"><p align="center"><font color="#FFFFFF" size="3">
<%
cTexto = oRegistro.Fields( "SITITULO" ).Value
cTexto1 = ""
cTexto2 = ""
IF InStr( cTexto, ":" ) <> 0 THEN
cTexto1 = mid( cTexto, 1, Instr( cTexto, ":" ) )
cTexto2 = Mid( cTexto, InStr( cTexto, ":" ) + 1 )
ELSE
cTexto1 = ""
cTexto2 = cTexto
END IF
%>
<font class="grande" color="#FFFF00">
<%
Response.Write cTexto1
%>
<font class="grande">
<%
Response.Write cTexto2 & " (" & oregistro.Fields( "SIPRIORIDADE" ).Value & "-" & oregistro.fields( "IDSITE" ).Value & "-" & oregistro.fields( "SIDATA" ).Value & ")"
%>
</font></p>
</td></tr></table></tr>
<tr><td width="100%" bgcolor="#EBECEA" ><p align="center"><font class="normal">
<%
cTexto = oRegistro.Fields( "SITEXTO" ).Value
cTexto = Replace( cTexto, "<a href", " <a href")
cTexto = Replace( cTexto, vbCrLf & "<", "<" )
cTexto = Replace( cTexto, ">" & vbCrLf, ">" )
cTexto = Replace( cTexto, vbCrLf, "<br>" )
cTexto = Replace( cTexto, "<code>", cCodeIni )
cTexto = Replace( cTexto, "</code>", cCodeFim )
response.write cTexto
%>
</font></p>
</td>
</tr>
<%
oRegistro.Movenext
LOOP
%>
</table>
</center>
<%
END FUNCTION
Meu html é fraco, meu ASP também, mas quebra o galho.
Aí mistura o fonte VB/ASP com html.
ADO e MySQL, igual no aplicativo e no ASP.
Poderia ser Harbour na internet?
Precisaria autorização da hospedagem, e aprender o que já existe no ASP, então.... mais fácil usar ASP mesmo.
José M. C. Quintas
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
- JoséQuintas
- Administrador

- Mensagens: 20267
- Registrado em: 26 Fev 2007 11:59
- Localização: São Paulo-SP
Site Harbour?
Ainda nisso....
Considerando quem usa Windows
- Windows tem servidor de internet
- Windows tem IIS/ASP
- Windows tem VBScript
- Windows tem ADO
- Windows tem até compilador VB.NET
Se está tudo na mão... NÃO usar porque?
E com certeza no meu provedor de hospedagem também tem, e faço uso.
Mas... meu site poderia estar até mesmo no meu servidor aqui, pra ser acessado externamente.
Por isso tenho usado essas coisas faz tempo, desde os tempos do Clipper.
No Clipper pra salvar no MySQL, e atualizar on line via internet.
No Harbour... tudo se expandiu.
Considerando quem usa Windows
- Windows tem servidor de internet
- Windows tem IIS/ASP
- Windows tem VBScript
- Windows tem ADO
- Windows tem até compilador VB.NET
Se está tudo na mão... NÃO usar porque?
E com certeza no meu provedor de hospedagem também tem, e faço uso.
Mas... meu site poderia estar até mesmo no meu servidor aqui, pra ser acessado externamente.
Por isso tenho usado essas coisas faz tempo, desde os tempos do Clipper.
No Clipper pra salvar no MySQL, e atualizar on line via internet.
No Harbour... tudo se expandiu.
José M. C. Quintas
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
Site Harbour?
O Toledo me disse que tinha um indiano passando o harbour para funcionar na web. Semelhante ao conceito do react.
Toledo, como anda este projeto?
Toledo, como anda este projeto?
- JoséQuintas
- Administrador

- Mensagens: 20267
- Registrado em: 26 Fev 2007 11:59
- Localização: São Paulo-SP
Site Harbour?
Vi comentários nestes dias sobre HMG Extended pra WEB.
Se considerar que GUI monta a dialog pra ser executada pelo Windows.....
A Web acaba sendo parecido, porque o Harbour montaria a página pro navegador fazer o resto...
Lógico... isso deixaria limitado, mas.... aplicativo funcionar no navegador seria o principal, o resto vém com o tempo.
Se considerar que GUI monta a dialog pra ser executada pelo Windows.....
A Web acaba sendo parecido, porque o Harbour montaria a página pro navegador fazer o resto...
Lógico... isso deixaria limitado, mas.... aplicativo funcionar no navegador seria o principal, o resto vém com o tempo.
José M. C. Quintas
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
- JoséQuintas
- Administrador

- Mensagens: 20267
- Registrado em: 26 Fev 2007 11:59
- Localização: São Paulo-SP
Site Harbour?
De repente um trem doido destes, levando o sistema operacional para o navegador.
http://www.virtualdesktop.org/complete/index.html
http://www.virtualdesktop.org/complete/index.html
José M. C. Quintas
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
Harbour 3.2, mingw, gtwvg mt, fivewin 25.04, multithread, dbfcdx, MySQL, ADOClass, PDFClass, SefazClass, (hwgui mt), (hmg3), (hmg extended), (oohg), PNotepad, ASP, stored procedure, stored function, Linux (Flagship/harbour 3.2)
"The world is full of kings and queens, who blind our eyes and steal our dreams Its Heaven and Hell"
https://github.com/JoseQuintas/
- Toledo
- Administrador

- Mensagens: 3133
- Registrado em: 22 Jul 2003 18:39
- Localização: Araçatuba - SP
- Contato:
Site Harbour?
Toledo - Clipper On Line
toledo@pctoledo.com.br
Harbour 3.2/MiniGui/HwGui
Faça uma doação para o fórum, clique neste link: http://www.pctoledo.com.br/doacao
toledo@pctoledo.com.br
Harbour 3.2/MiniGui/HwGui
Faça uma doação para o fórum, clique neste link: http://www.pctoledo.com.br/doacao
