Images from server / Fotos desde servidor
Moderator: Rathinagiri
- Claudio Ricardo
- Posts: 367
- Joined: Tue Oct 27, 2020 3:38 am
- DBs Used: DBF, MySQL, MariaDB
- Location: Bs. As. - Argentina
Images from server / Fotos desde servidor
Hola...
Comenzaré un sistema para gestión de inmobiliarias, basado en:
Una PC servidor S.O. Centos con MariaDB local (LAN) o remoto en un Hosting (si
la empresa tiene sucursales), y una copia del programa que voy a hacer en cada
computadora terminal, hasta ahí nada fuera de lo habitual, pero....
Cada propiedad deberá llevar asociadas unas fotos (hasta 10 max.) que, para
ser accesibles desde cualquier terminal, y mostrarse junto a los datos de cada
propiedad, deberán estar guardadas en una o dos carpetas en el servidor...
Mi consulta / pedido de ayuda al foro es:
Hay herramientas en Harbour + HMG que me permitan acceder a esas carpetas
en LAN o Hosting via internet, asi como las hay para MySQL o MariaDB ?
En el server deberé montarlo como FTP o hay otro modo ?
Hay algun ejemplo que me sirva de guía ?
También necesitaría cambiar automáticamente la resolución de las fotos
que guarden, para alivianar la comunicación de la red y el espacio que
ocuparán, además la otra carpeta con thumbnails ayudaría, pero algo así
vi hace poco aqui en este foro y lo pondré en práctica.
Desde yá muy agradecido a todos...
English (Goggle trad)
Hello...
I will start a real estate management system, based on:
A PC server S.O. Centos with MariaDB local (LAN) or remote in a Hosting (if
the company has branches), and a copy of the program that I will do in each
terminal computer, so far nothing out of the ordinary, but ...
Each property must have associated photos (up to 10 max.) That, to
be accessible from any terminal, and be displayed next to the data of each
property, they should be stored in one or two folders on the server ...
My question / request for help to the forum is:
There are tools in Harbor + HMG that allow me to access those folders
in LAN or Hosting via internet, as there are for MySQL or MariaDB?
On the server, should I mount it as FTP or is there another way?
Is there an example to guide me?
You would also need to automatically change the resolution of the photos
that they keep, to alleviate the communication of the network and the space that
will occupy, also the other folder with thumbnails would help, but something like that
I saw here recently in this forum and I will put it into practice.
From now on, very grateful to all ...
Comenzaré un sistema para gestión de inmobiliarias, basado en:
Una PC servidor S.O. Centos con MariaDB local (LAN) o remoto en un Hosting (si
la empresa tiene sucursales), y una copia del programa que voy a hacer en cada
computadora terminal, hasta ahí nada fuera de lo habitual, pero....
Cada propiedad deberá llevar asociadas unas fotos (hasta 10 max.) que, para
ser accesibles desde cualquier terminal, y mostrarse junto a los datos de cada
propiedad, deberán estar guardadas en una o dos carpetas en el servidor...
Mi consulta / pedido de ayuda al foro es:
Hay herramientas en Harbour + HMG que me permitan acceder a esas carpetas
en LAN o Hosting via internet, asi como las hay para MySQL o MariaDB ?
En el server deberé montarlo como FTP o hay otro modo ?
Hay algun ejemplo que me sirva de guía ?
También necesitaría cambiar automáticamente la resolución de las fotos
que guarden, para alivianar la comunicación de la red y el espacio que
ocuparán, además la otra carpeta con thumbnails ayudaría, pero algo así
vi hace poco aqui en este foro y lo pondré en práctica.
Desde yá muy agradecido a todos...
English (Goggle trad)
Hello...
I will start a real estate management system, based on:
A PC server S.O. Centos with MariaDB local (LAN) or remote in a Hosting (if
the company has branches), and a copy of the program that I will do in each
terminal computer, so far nothing out of the ordinary, but ...
Each property must have associated photos (up to 10 max.) That, to
be accessible from any terminal, and be displayed next to the data of each
property, they should be stored in one or two folders on the server ...
My question / request for help to the forum is:
There are tools in Harbor + HMG that allow me to access those folders
in LAN or Hosting via internet, as there are for MySQL or MariaDB?
On the server, should I mount it as FTP or is there another way?
Is there an example to guide me?
You would also need to automatically change the resolution of the photos
that they keep, to alleviate the communication of the network and the space that
will occupy, also the other folder with thumbnails would help, but something like that
I saw here recently in this forum and I will put it into practice.
From now on, very grateful to all ...
Corrige al sabio y lo harás más sabio, Corrige al necio y lo harás tu enemigo.
WhatsApp / Telegram: +54 911-63016162
WhatsApp / Telegram: +54 911-63016162
Re: Images from server / Fotos desde servidor
viewtopic.php?f=5&t=3167&hilit=thumbnails&start=10
viewtopic.php?f=5&t=6383&p=61397&hilit= ... ils#p61397
viewtopic.php?f=5&t=2517&p=22169&hilit= ... ils#p22169
viewtopic.php?f=5&t=6383&p=61397&hilit= ... ils#p61397
viewtopic.php?f=5&t=2517&p=22169&hilit= ... ils#p22169
Andrés González López
Desde Guadalajara, Jalisco. México.
Desde Guadalajara, Jalisco. México.
- Claudio Ricardo
- Posts: 367
- Joined: Tue Oct 27, 2020 3:38 am
- DBs Used: DBF, MySQL, MariaDB
- Location: Bs. As. - Argentina
Re: Images from server / Fotos desde servidor
GRACIAS Andy !!!
Yo buscando cómo acceder a carpetas remotas no pensé claro...
Una imagen es un archivo, compuesto por bits... si la decompongo
puedo guardar esos bits en un campo de la DB... en este caso 10 campos
y luego recomponerla para mostrarla en un control image.
Necesitaré reducirlas a unos 100 o 150 Kb. y listo !!
Sólo espero que un par de miles de registros así (más el resto de datos)
no enlentezcan mucho la red o un servicio de internet.
Yo buscando cómo acceder a carpetas remotas no pensé claro...
Una imagen es un archivo, compuesto por bits... si la decompongo
puedo guardar esos bits en un campo de la DB... en este caso 10 campos
y luego recomponerla para mostrarla en un control image.
Necesitaré reducirlas a unos 100 o 150 Kb. y listo !!
Sólo espero que un par de miles de registros así (más el resto de datos)
no enlentezcan mucho la red o un servicio de internet.
Corrige al sabio y lo harás más sabio, Corrige al necio y lo harás tu enemigo.
WhatsApp / Telegram: +54 911-63016162
WhatsApp / Telegram: +54 911-63016162
- danielmaximiliano
- Posts: 2625
- Joined: Fri Apr 09, 2010 4:53 pm
- Location: Argentina
- Contact:
Re: Images from server / Fotos desde servidor
Hola Claudio: puedes guargarlas en un campo BLOB en tamaño minimo.. debes tener tambien la ruta asociada a esa imagen asi que si quieres verlas en tamaño original cuando hagar click en VER solo descarga esa imagen en tamaño real y no recargas la red.
*´¨)
¸.·´¸.·*´¨) ¸.·*¨)
(¸.·´. (¸.·` *
.·`. Harbour/HMG : It's magic !
(¸.·``··*
Saludos / Regards
DaNiElMaXiMiLiAnO
Whatsapp. := +54901169026142
Telegram Name := DaNiElMaXiMiLiAnO
¸.·´¸.·*´¨) ¸.·*¨)
(¸.·´. (¸.·` *
.·`. Harbour/HMG : It's magic !
(¸.·``··*
Saludos / Regards
DaNiElMaXiMiLiAnO
Whatsapp. := +54901169026142
Telegram Name := DaNiElMaXiMiLiAnO
- Claudio Ricardo
- Posts: 367
- Joined: Tue Oct 27, 2020 3:38 am
- DBs Used: DBF, MySQL, MariaDB
- Location: Bs. As. - Argentina
Re: Images from server / Fotos desde servidor
Hola Daniel...
Gracias por tu respuesta, el programa aún no lo inicio, probaré tu sugerencia y posteo el resultado.
Sólo me faltaría una función que reduzca el tamaño de las fotos (seguramente tomadas con celular)
de 3 - 5 Mb. a unos 100 - 150 Kb. Probaré una que postearon aqui hace unos días.
Gracias por tu respuesta, el programa aún no lo inicio, probaré tu sugerencia y posteo el resultado.
Sólo me faltaría una función que reduzca el tamaño de las fotos (seguramente tomadas con celular)
de 3 - 5 Mb. a unos 100 - 150 Kb. Probaré una que postearon aqui hace unos días.
Corrige al sabio y lo harás más sabio, Corrige al necio y lo harás tu enemigo.
WhatsApp / Telegram: +54 911-63016162
WhatsApp / Telegram: +54 911-63016162
Re: Images from server / Fotos desde servidor
Hola Claudio, aquí hay algo...
*----------------------------------------------
Hi Claudio, here's something ...
*----------------------------------------------
Hi Claudio, here's something ...
viewtopic.php?f=9&t=6668&start=30by franco » Wed Jan 20, 2021 6:03 pm
Do you think I could take a 2249 kb jpg and resize to 200 kb and still be clear inside hmg this way to redo my internal camera files before
copying and saving them.
Andrés González López
Desde Guadalajara, Jalisco. México.
Desde Guadalajara, Jalisco. México.
- Claudio Ricardo
- Posts: 367
- Joined: Tue Oct 27, 2020 3:38 am
- DBs Used: DBF, MySQL, MariaDB
- Location: Bs. As. - Argentina
Re: Images from server / Fotos desde servidor
Gracias Andy...
La idea es usar la función GetFile () para que el usuario seleccione (desde el Celular / Tablet via USB
o de una carpeta local) y mostrar la foto en una ventana con botones, aceptar / cancelar / cargar otra...
Y la función de Jimmy, que propone Marek en el post que vos me señalás, me viene justa para eso !
La idea es usar la función GetFile () para que el usuario seleccione (desde el Celular / Tablet via USB
o de una carpeta local) y mostrar la foto en una ventana con botones, aceptar / cancelar / cargar otra...
Y la función de Jimmy, que propone Marek en el post que vos me señalás, me viene justa para eso !
Corrige al sabio y lo harás más sabio, Corrige al necio y lo harás tu enemigo.
WhatsApp / Telegram: +54 911-63016162
WhatsApp / Telegram: +54 911-63016162
Re: Images from server / Fotos desde servidor
olá Claudio use: HB_Base64EncodeFile ( ) e HB_Base64DecodeFile ( )
BLOBDIRECTEXPORT() Export the contents of a binary large object (BLOB) pointer to a file
BLOBDIRECTGET() Retrieve data stored in a BLOB file without referencing a specific field
BLOBDIRECTIMPORT() Import a file into a BLOB file and return a pointer to the data
BLOBDIRECTPUT() Put data in a BLOB file without referencing a specific field
BLOBEXPORT() Copy the contents of a BLOB, identified by its memo field number, to a file
BLOBGET() Get the contents of a BLOB, identified by its memo field number
BLOBIMPORT() Read the contents of a file as a BLOB, identified by a memo field number
BLOBROOTGET() Retrieve the data from the root area of a BLOB file
BLOBROOTLOCK() Obtain a lock on the root area of a BLOB file
BLOBROOTPUT() Store data in the root area of a BLOB file
BLOBROOTUNLOCK() Release the lock on a BLOB file's root area
https://harbour.github.io/doc/
https://harbour.github.io/doc/clc53.htm ... rectimport
https://harbour.github.io/doc/clc53.html#blobdirectget
https://harbour.github.io/doc/clc53.htm ... rectexport
https://harbour.github.io/doc/clc53.html#blobdirectput
https://harbour.github.io/doc/clc53.html#blobexport
https://harbour.github.io/doc/clc53.html#blobget
https://harbour.github.io/doc/clc53.html#blobimport
BLOBDIRECTEXPORT() Export the contents of a binary large object (BLOB) pointer to a file
BLOBDIRECTGET() Retrieve data stored in a BLOB file without referencing a specific field
BLOBDIRECTIMPORT() Import a file into a BLOB file and return a pointer to the data
BLOBDIRECTPUT() Put data in a BLOB file without referencing a specific field
BLOBEXPORT() Copy the contents of a BLOB, identified by its memo field number, to a file
BLOBGET() Get the contents of a BLOB, identified by its memo field number
BLOBIMPORT() Read the contents of a file as a BLOB, identified by a memo field number
BLOBROOTGET() Retrieve the data from the root area of a BLOB file
BLOBROOTLOCK() Obtain a lock on the root area of a BLOB file
BLOBROOTPUT() Store data in the root area of a BLOB file
BLOBROOTUNLOCK() Release the lock on a BLOB file's root area
https://harbour.github.io/doc/
https://harbour.github.io/doc/clc53.htm ... rectimport
https://harbour.github.io/doc/clc53.html#blobdirectget
https://harbour.github.io/doc/clc53.htm ... rectexport
https://harbour.github.io/doc/clc53.html#blobdirectput
https://harbour.github.io/doc/clc53.html#blobexport
https://harbour.github.io/doc/clc53.html#blobget
https://harbour.github.io/doc/clc53.html#blobimport
- Claudio Ricardo
- Posts: 367
- Joined: Tue Oct 27, 2020 3:38 am
- DBs Used: DBF, MySQL, MariaDB
- Location: Bs. As. - Argentina
Re: Images from server / Fotos desde servidor
Gracias Jair...
Pensaba usar estas dos funciones posteadas por Rathinagiri en un
post que me sugirió Andy
viewtopic.php?f=5&t=3167&hilit=thumbnails&start=10
Estudiaré detenidamente las funciones que me propones (también Daniel las sugirió)
y veré cuál se adapta mejor a lo que necesito.
Nuevamente, Muchas Gracias a todos por la ayuda prestada.
Pensaba usar estas dos funciones posteadas por Rathinagiri en un
post que me sugirió Andy
viewtopic.php?f=5&t=3167&hilit=thumbnails&start=10
Code: Select all
function file2str( cFileName )
local oEncoder := TIPEncoderBase64():New()
local hInput
local cData := ''
local cBuffer := Space( 1024 )
IF hb_FileExists( cFileName )
hInput := FOpen( cFileName )
nLen := FRead( hInput, @cBuffer, 1024 )
DO WHILE nLen > 0
IF nLen < 1024
cData += hb_BLeft( cBuffer, nLen )
ELSE
cData += cBuffer
ENDIF
nLen := FRead( hInput, @cBuffer, 1024 )
ENDDO
FClose( hInput )
cData := oEncoder:Encode( cData )
return cData
ENDIF
return cData
//---------------------------------------------------------------------------
function str2file( cStr, cFileName )
local oEncoder := TIPEncoderBase64():New()
local hOutput
cStr := oEncoder:Decode( cStr )
hOutput := FCreate( cFileName )
FWrite( hOutput, cStr )
FClose( hOutput )
return nil
y veré cuál se adapta mejor a lo que necesito.
Nuevamente, Muchas Gracias a todos por la ayuda prestada.
Corrige al sabio y lo harás más sabio, Corrige al necio y lo harás tu enemigo.
WhatsApp / Telegram: +54 911-63016162
WhatsApp / Telegram: +54 911-63016162
Re: Images from server / Fotos desde servidor
Here`s my thought.
Thanks to
Andres, Jimmy an Mol
With this demo you can size jpg files from 3MB to 54KB or more depending on what you need.
Thanks to
Andres, Jimmy an Mol
With this demo you can size jpg files from 3MB to 54KB or more depending on what you need.
- Attachments
-
- mycam.rar
- (6.62 MiB) Downloaded 153 times