use Firefox bookmarks-YYYY-MM-DD.json
Posted: Fri Aug 20, 2021 5:00 am
hi,
did somebody have Code to "read" Firefox *.JSON Backup File
did somebody have Code to "read" Firefox *.JSON Backup File
Exclusive forum for HMG, a Free / Open Source xBase WIN32/64 Bits / GUI Development System
http://mail.hmgforum.com/
Opening JSON Files with Notepad++
Download and install Notepad++.
Open Notepad++, click the Plugins button at the top and select Plugins Admin.
In the Plugins Admin window, search JSON Viewer and install the JSON Viewer plugin.
When prompted, click Yes. Notepad++ will exit and then restart after the plugin has finished installing.
Now, navigate to File > Open or press the CTRL + O buttons and select the JSON file you want to open.
Once the file is opened, go to Plugins > JSON Viewer and select Format JSON. Then again go to Plugins > JSON Viewer and select Show JSON Viewer.
You can now view and edit the contents of the JSON file.
Yes i have "think" about "read" SQlite Table "direct" ... but it need to "learn" how it work under HMGRathinagiri wrote: ↑Sat Aug 21, 2021 4:34 am If you want to read it from HMG, use SQLite library!
Yes! SQLite can convert JSON to tables!
Code: Select all
cSeek := "{"+CHR(34)+"guid"+CHR(34)+":"Code: Select all
nEnde := hb_AT( "}", cBuffer , nPosi)Code: Select all
cSeek := CHR(34)+"uri"+CHR(34)+":"so URI will not fit into Type "C", ornMaxTXT : 142
nMaxURI : 650
Code: Select all
#include "hbclass.ch"
/*
Clase que define los methods que seran necesarios sobrecargar
para darle funcionalidad */
CLASS BaseService
// La data uValue inicialmente es un array. Lo he dejado de esta manera
// pensando más en devolver una lista que un objeto JSON.
DATA uValue
DATA lError INIT .F.
METHOD New() CONSTRUCTOR
METHOD getError() INLINE ::lError
METHOD GetJSON()
METHOD getBydId()
METHOD findAll()
METHOD DeleteBydId()
METHOD Create()
METHOD Modify()
END CLASS
METHOD New() CLASS BaseService
::uValue := {}
RETURN Self
/*
Por defecto, los methods , si no estan sobreescritos, el valor de retorno
dará un error 501 Not Implemented
*/
METHOD getBydId() CLASS BaseService
RETURN ( ::lError := .T., USetStatusCode( 501 ) )
METHOD findAll() CLASS BaseService
RETURN ( ::lError := .T., USetStatusCode( 501 ) )
METHOD DeleteBydId() CLASS BaseService
RETURN ( ::lError := .T., USetStatusCode( 501 ) )
METHOD Create() CLASS BaseService
RETURN ( ::lError := .T., USetStatusCode( 501 ) )
METHOD Modify() CLASS BaseService
RETURN ( ::lError := .T., USetStatusCode( 501 ) )
METHOD GetJSON() CLASS BaseService
RETURN if( ::uValue != NIL, hb_jsonEncode( ::uValue, .T. ), NIL )