CN106095883B - Method and device for importing browser data - Google Patents

Method and device for importing browser data Download PDF

Info

Publication number
CN106095883B
CN106095883B CN201610396741.5A CN201610396741A CN106095883B CN 106095883 B CN106095883 B CN 106095883B CN 201610396741 A CN201610396741 A CN 201610396741A CN 106095883 B CN106095883 B CN 106095883B
Authority
CN
China
Prior art keywords
browser
browser application
database file
file
recently used
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201610396741.5A
Other languages
Chinese (zh)
Other versions
CN106095883A (en
Inventor
张洋平
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Yayue Technology Co ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201610396741.5A priority Critical patent/CN106095883B/en
Publication of CN106095883A publication Critical patent/CN106095883A/en
Application granted granted Critical
Publication of CN106095883B publication Critical patent/CN106095883B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
    • G06F16/972Access to data in other repository systems, e.g. legacy data or dynamic Web page generation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/955Retrieval from the web using information identifiers, e.g. uniform resource locators [URL]

Abstract

The embodiment of the invention discloses a method for importing browser data, which comprises the following steps: detecting an installed browser application, and acquiring the type of the installed browser application and a database file of a historical record corresponding to the type; determining a recently used browser application according to the database file; acquiring a user configuration storage address corresponding to the type of the recently used browser; reading and analyzing user configuration according to the user configuration storage address, and configuring a target browser according to a value under a preset attribute item obtained through analysis; and extracting historical record data items according to the historical record database file of the recently used browser, and storing the historical record data items into the historical record database file of the target browser. By adopting the method and the device, the user can be prevented from repeatedly setting the browser, and the convenience of operation is improved.

Description

Method and device for importing browser data
Technical Field
The invention relates to the technical field of computers, in particular to a method and a device for importing browser data.
Background
In the conventional technology, after a user uses one browser for a long time, the user has many customized configurations for the browser, such as settings of a tab page creating position, a bookmark opening position, a double click on a closed tab and the like, and also has many history information, when the user newly installs another browser, the default configuration of the newly installed browser is probably different from the previous customary configuration of the user, and the previous history is lost. At this time, the user is required to manually reset the newly installed browser, which causes repeated operations by the user, resulting in insufficient convenience of operation.
Disclosure of Invention
Therefore, in order to solve the technical problem that when a new browser is installed in the prior art, user habits need to be set on the browser again, so that the user needs to operate repeatedly, and the operation convenience is not enough, a method for importing browser data is provided.
A method of importing browser data, comprising:
detecting an installed browser application, and acquiring the type of the installed browser application and a database file of a historical record corresponding to the type;
determining a recently used browser application according to the database file;
acquiring a user configuration storage address corresponding to the type of the recently used browser;
reading and analyzing user configuration according to the user configuration storage address, and configuring a target browser according to a value under a preset attribute item obtained through analysis;
and extracting historical record data items according to the historical record database file of the recently used browser, and storing the historical record data items into the historical record database file of the target browser.
In one embodiment, the determining the most recently used browser application from the database file is: and detecting the modification time in the file attribute of the database file, and determining the installed browser corresponding to the database file with the latest modification time as the latest used browser application.
In one embodiment, the preset attribute items include: and newly building a tab page position, opening the front and the back of a link by clicking, closing the tab page by double clicking, closing the tab page by right key, reminding when closing a multi-tab page, opening the front and the back of a bookmark by clicking, and opening the front and the back of an address bar during input.
In one embodiment, the extracting the data items of the history records according to the database file of the history records of the recently used browser comprises: and extracting a preset number of historical data items according to the database file of the historical records of the recently used browser from near to far according to the time sequence.
In one embodiment, the step of obtaining the user configuration storage address corresponding to the type of the most recently used browser includes: and acquiring a preset file path corresponding to the type of the recently used browser, or acquiring a preset registry key corresponding to the type of the recently used browser, and acquiring a file path corresponding to the registry key.
In one embodiment, the step of extracting the historical data items according to the historical database file of the recently used browser comprises: and accessing the database file of the history record of the recently used browser through an SQL interface function, and extracting the data items of the history record stored in the database file by executing a preset SQL statement corresponding to the type of the recently used browser.
In one embodiment, the method further comprises: after the target browser is started for the first time, receiving keywords input in an address bar or a search bar of the target browser; searching a historical record matched with the keyword in a database file of the historical record of the target browser, wherein the historical record of the target browser is the historical record extracted according to the database file of the historical record of the most recently used browser; displaying the history records matched with the keywords in an information prompt box corresponding to the address bar or the search bar; and when the history record which is displayed in the information prompt box and matched with the keyword is selected, skipping to a webpage link corresponding to the selected history record.
In addition, in order to solve the technical problem that when a new browser is installed in the prior art, user habits need to be set on the browser again, so that the user needs to operate repeatedly, and the operation convenience is not sufficient, a device for importing browser data is provided.
An apparatus for importing browser data, comprising:
the installed browser detection module is used for detecting the installed browser application and acquiring the type of the installed browser application and a database file of a historical record corresponding to the type;
the latest browser determining module is used for determining the latest browser application according to the database file;
a user configuration storage address acquisition module, configured to acquire a user configuration storage address corresponding to the type of the recently used browser;
the user configuration importing module is used for reading and analyzing user configuration according to the user configuration storage address and configuring a target browser according to a value under a preset attribute item obtained through analysis;
and the history record importing module is used for extracting data items of the history record according to the database file of the history record of the recently used browser and storing the data items into the database file of the history record of the target browser.
In one embodiment, the latest browser determining module is further configured to detect modification time in file attributes of the database file, and determine an installed browser corresponding to the database file with the latest modification time as a latest browser application.
In one embodiment, the preset attribute items include: and newly building a tab page position, opening the front and the back of a link by clicking, closing the tab page by double clicking, closing the tab page by right key, reminding when closing a multi-tab page, opening the front and the back of a bookmark by clicking, and opening the front and the back of an address bar during input.
In one embodiment, the history importing module is further configured to extract a preset number of data items of the history according to a database file of the history of the most recently used browser in a time order from near to far.
In one embodiment, the user configuration storage address obtaining module is further configured to obtain a preset file path corresponding to the type of the recently-used browser, or obtain a preset registry key corresponding to the type of the recently-used browser, and obtain a file path corresponding to the registry key.
In one embodiment, the history import module is further configured to access a database file of the history of the recently used browser through an SQL interface function, and extract data items of the history stored in the database file by executing a preset SQL statement corresponding to the type of the recently used browser.
In one embodiment, the apparatus further includes an address autocomplete module, configured to receive a keyword input in an address bar or a search bar of the target browser after the target browser is initially started; searching a historical record matched with the keyword in a database file of the historical record of the target browser, wherein the historical record of the target browser is the historical record extracted according to the database file of the historical record of the most recently used browser; displaying the history records matched with the keywords in an information prompt box corresponding to the address bar or the search bar; and when the history record which is displayed in the information prompt box and matched with the keyword is selected, skipping to a webpage link corresponding to the selected history record.
The embodiment of the invention has the following beneficial effects:
after the method and the device for importing the browser data are adopted, a user can not perceive the configuration and the history of the commonly used browser when installing a new browser, so that the user does not feel strange when using a newly installed target browser.
Meanwhile, due to the fact that the historical records of other browsers are introduced, a user can conveniently check the past historical records of the newly installed target browser, and product experience of the new user is improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Wherein:
FIG. 1 is a flowchart illustrating a method for importing browser data according to an embodiment;
FIG. 2 is an interface diagram of a user configuration settings interface in one embodiment;
FIG. 3 is a flow diagram illustrating an address autocomplete process in one embodiment;
FIG. 4 is a diagram illustrating an interface for an address bar link address autocomplete process in one embodiment;
FIG. 5 is a diagram illustrating an exemplary architecture of an apparatus for importing browser data according to an embodiment;
fig. 6 is a schematic structural diagram of a computer device for executing the method for importing browser data in one embodiment.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In order to solve the technical problem that when a new browser is installed in the prior art, user habits need to be set on the browser again, so that the user needs to repeatedly operate, and the operation convenience is not sufficient, in one embodiment, a method for importing browser data is particularly provided. The method may be implemented in dependence of a computer program which is executable on a computer system based on the von neumann architecture, which may be a browser application on a mobile terminal or a personal computer, or a browser plug-in developed based on the browser application. The computer system can be terminal equipment such as a smart phone, a tablet computer and a notebook computer.
The method can be automatically executed after the user newly installs the browser, and can also be manually triggered to execute by the user through inputting instructions. After the method is executed, the browser which is used by the user recently in the installed browsers of the computer is automatically detected, then browsing data of the browser which is used by the user recently, including user configuration and history records, is automatically imported into the newly installed browser, and when the user uses the newly installed browser to surf the internet, the user can use the user habit configured on other installed browsers to surf the internet, so that the convenience of operation is improved.
Specifically, as shown in fig. 1, a method for importing browser data includes:
step S102: and detecting the installed browser application, and acquiring the type of the installed browser application and a database file of a history record corresponding to the type.
A user needs to use a browser application when using a terminal to surf the internet, and since there are many manufacturers that make the browser application and the browser applications of the manufacturers have features (for example, the browser is compatible with other social software of the manufacturer, etc.), the user often tries to use multiple browsers. Common browsers such as QQ browser, dog browser, cheetah browser, and 360 browser, etc.
The method can be executed in the application scene when the user finishes installing the browser and performs initial setting on the newly installed browser. For example, if a dog browser, a cheetah browser, and a 360 browser have been installed on a user's computer, the browsers are used on a daily basis. After the user downloads the installation file of the QQ browser for installation for better functions, when the installation is finished, the installation interface of the QQ browser prompts the user that the installation of the QQ browser is finished and prompts the user to set the newly installed QQ browser.
The newly installed QQ browser can detect the browser application already installed in the operating system, and in the above example, can detect that the dog browser, cheetah browser, and 360 browser have already been installed in the operating system. In this embodiment, the installed browser application may be viewed by viewing the application list in the operating system, that is, the installed browser may be acquired by calling an interface function of the application list in the operating system. In another embodiment, the installed browser may also be located by searching for a preset keyword in a registry of the operating system (e.g., windows system). The type of the installed browser application is identification information for distinguishing multiple browsers of different manufacturers or different versions of the same manufacturer. For example, the type of dog browser may be souguo, the type of cheetah browser may be liebao, and the type of 360 browser may be 360.
The history of the browser is an access record of a user accessing the internet by using the browser, and a history usually includes a url link and summary information of a webpage corresponding to the url link. The history data of the browser is typically stored in a database. An SQLite database or other SQL-based database module is usually integrated in an existing browser, daily browsing data of a user is usually stored in a database file at a corresponding position on a disk by the browser through a database program integrated in the browser, and the position of each type of browser storing the database file is fixed. By obtaining the type of the installed browser, the database file storage path corresponding to the corresponding type can be obtained, and therefore the corresponding database file is obtained.
Step S104: the most recently used browser application is determined from the database file.
In this embodiment, the terminal may determine, by detecting modification time in the file attribute of the database file, an installed browser corresponding to the database file with the latest modification time as a most recently used browser application.
In the above example, if the newly installed browser is a QQ browser and the found installed browsers are a dog search browser, a leopard browser and a 360 browser, the database files of the history records of the three browsers can be respectively obtained, and then the last modification time of the files is obtained by using a Windows system API function GetFileAttribute, which is used by the user for the last time is determined according to the last modification time.
In another embodiment, the data items in the history record in the database file can also be read to check the writing time of the latest data item, and the browser with the writing time of the latest data item being closer is the most recently used browser application.
For example, if the history of the dog search browser is read, url1 is the latest data item of the dog search browser, and the time is 3 months and 12 days 2015; in the history of the cheetah browser, url2 is the latest data item of the cheetah browser, and the time is 2015, 8 months and 2 days; in the history of 360 browsers, url3 is the most recent data item of 360 browsers, and the time is 1 month and 6 days 2014, url2 is the most recent data item of all browsers, so that it can be determined that the cheetah browser is the most recently used browser.
Step S106: and acquiring a user configuration storage address corresponding to the type of the browser used recently.
Step S108: and reading and analyzing the user configuration according to the user configuration storage address, and configuring the target browser according to the value under the preset attribute item obtained by analysis.
Step S110: and extracting historical record data items according to the historical record database file of the recently used browser, and storing the historical record data items into the historical record database file of the target browser.
The habits of a user using a browser are typically stored in a user profile of the browser, where various user-configured attributes are typically stored in the form of name-value pairs. In the present embodiment, as shown in fig. 2, the habit of the user to use the browser can be defined by the following seven attribute items: the method comprises the steps of building a new tab page position, opening a front background and a back background before clicking a link, closing a tab page by double clicking, closing the tab page by a right key, reminding when closing a multi-tab page, opening the front background and the back background before clicking a bookmark, and opening the front background and the back background when inputting an address bar.
In this embodiment, the terminal may obtain, according to the type of the browser, a location where the user configuration file is stored by the browser of the corresponding type, so as to obtain a value under the preset attribute item through analysis, and then configure the value to the newly installed target browser. And then accessing the historical database file of the recently used browser through an SQL interface function, and extracting the historical data items stored in the database file by executing a preset SQL statement corresponding to the type of the recently used browser.
In addition, after the browser is installed, the user can open the setting interface of the browser to set the use habits on the interface shown in fig. 2.
Specifically, the following describes the process of reading the user configuration by taking a newly installed browser as a QQ browser, an installed browser as a dog search browser, a cheetah browser, and a 360 browser as examples.
The user configuration of the safe browsers for dog searching, leopard hunting and 360 is stored in a plaintext file form, the historical record information is stored in a sqlite database form, and the data can be read according to a specified format by finding the configuration files of the browsers and the database files of the historical records.
Searching a dog browser: the user configuration of the dog search browser and the database file of the history are stored in the directory of% appdata% \ Roaming \ SogouExplorer of an operating system (windows), the xml file is the user configuration file, the data in the user configuration file is stored in the form of xml, and the comparison relationship between the fields of the configuration file and the QQ browser import configuration is shown in table 1:
TABLE 1
Figure BDA0001009578610000071
Figure BDA0001009578610000081
Db is a database file used by a dog search browser for storing history records, wherein a tb _ URL history table in the database stores access time, title of an accessed website and id of the accessed website, and a urlinfo table stores id of the accessed website and URL of the accessed website, and two tables are required to be related and inquired according to URL. The history can be queried in chronological order using select (time-string ('% s', '1601-01-01')) 1000000as time, title, url from tb _ url, tb _ url where tb _ url, url as tbjurl _ url. The time of historical record storage of the dog searching browser is seconds from 1970-01-01 zero, and the time of historical record storage of the QQ browser is microseconds from 1 month 1 day zero of 1601, so that the sql statement needs to be subjected to next time conversion.
The configuration and history record file of the login user is a folder which is started by a letter f and named by mixing numbers and letters under the subfile of the SogouExplorer directory, wherein all data of the login user are stored, and the configuration and history record of the login user can be obtained by using the method.
Cheetah browser: user data of the cheetah browser is stored in a preference file under a% appdata% \ Loacl \ leibao \ directory, the file is stored in a json format, wherein the key of each item corresponds to a setting item, and the corresponding relation between the fields in the configuration file and the QQ browser import configuration is shown in a table 2:
TABLE 2
User habit attributes for QQ browser User-configured attribute items for cheetah browsers
Close multi-tab reminder mul_tab_close_tip
Right key closed label page click_mouse_right_close_tab
Click link foreground and background open newtab_postion_on_translink_clicked
Foreground opening of click bookmark new_tab_Open_bookmark
Position of new label page open_link_make_new_tab_active
Front and back stage opening during address bar input new_tab_open_url
Double click closed label page Double_click_close
History is a History database file, wherein a URL table stores user History, the table includes time, a title and a URL of a visited website, the History time of a cheetah browser stores microseconds FROM 1 st 1601, the number of microseconds FROM the zero point is the same as the time format in the QQ browser, and the History sorted according to time sequence can be inquired by using SELECT last _ visit _ time as time, URL, title FROM where time >0order by last _ visit _ time desc).
For a login user, a cheetah browser has configuration in a 1 dex.ini file under a leibao directory, reads an autologic field in the file, if the autologic field is 1, the browser is in an automatic login state, then reads a passport field, the value of the field is the private directory of the login user, and the configuration and the history of the login user are stored under the directory. The configuration and the history of the cheetah login user can be obtained by using the method.
360 secure browser: the storage position of USER Data of the 360-degree secure browser is not fixed, a code _ install _ path or an old _ version _ path key value under a registry HKEY _ CURRENT _ USER \ \ Software \ \360se6\ \ Chrome needs to be read to obtain an installation path, and a configuration file of a USER is stored under a 360se6\ \ USER Data \ \ Default directory under the installation path directory. That is, the file path corresponding to the registry key may be obtained by obtaining a preset registry key corresponding to the type of the most recently used browser.
Like the cheetah browser, the user profile is Preferences, which is also stored in json format, and the mapping relationship between the configuration fields therein and the QQ browser imported configuration is shown in table 3:
TABLE 3
User habit attributes for QQ browser User-configured attribute items for cheetah browsers
Close multi-tab reminder mul_tab_close_tip
Right key closed label page click_mouse_right_close_tab
Click link foreground and background open newtab_postion_on_translink_clicked
Foreground opening of click bookmark new_tab_Open_bookmark
Position of new label page open_link_make_new_tab_active
Front and back stage opening during address bar input new_tab_open_url
Double click closed label page Double_click_close
The database file of the user's History record is a History file, which is also a database in sqlite format, the time storage mode is the same as that of the QQ browser, and the History record can be inquired by using an sql statement (select _ view _ time as time, url, title FROM url >0order by _ view _ time desc).
The information of the login user is in a file% appdata% \ \360se6\ apps \ data \ \ users \ \ login.ini, the configuration of [ nowLogin ] is read, when isLogin is 1, the browser is in a login state, AppUSerDataPath is a directory where the configuration of the corresponding login user is located, the configuration and the history of the login user are in the corresponding file under the directory, and the configuration and the history of the login user can be obtained by the method.
In this embodiment, when extracting the data items of the history based on the database file of the history of the most recently used browser, a preset number of data items of the history may be extracted in order of time from near to far based on the database file of the history of the most recently used browser. Preferably, the preset number is 200 items.
Further, after the user configuration and the history are imported, the newly installed browser may further implement an automatic completion function of the address bar or the search bar according to the newly imported history, specifically, as shown in fig. 3, including:
step S202: and after the target browser is started for the first time, receiving keywords input in an address bar or a search bar of the target browser.
Step S204: and searching a historical record matched with the keyword in a database file of the historical record of the target browser, wherein the historical record of the target browser is the historical record extracted from the database file of the historical record of the most recently used browser.
Step S206: and displaying the history records matched with the keywords in an information prompt box corresponding to the address bar or the search bar.
Step S208: and when the history record which is displayed in the information prompt box and matched with the keyword is selected, skipping to the webpage link corresponding to the selected history record.
Referring to fig. 4, the user can also see the history of the last browser used by the user in the history, and when a common website is entered in the address bar or the search bar, the history is searched and url is automatically matched. In fig. 4, after the installation of the newly installed QQ browser is completed, the history of another browser is automatically imported, and when the user inputs "ji" in the address bar, the browser matches the website having "ji" in the URL, based on the website of the history accessed by the browser. Therefore, browsing habits and browsing histories of users on other browsers are automatically transplanted, and convenience in operation is improved.
In order to solve the technical problem that the user habit needs to be set on the browser again when a new browser is installed in the prior art, so that the user needs to repeatedly operate and the operation convenience is not sufficient, in one embodiment, a device for importing browser data is particularly provided. As shown in fig. 5, the apparatus for importing browser data includes an installed browser detecting module 102, a recent browser determining module 104, a user configuration storage address obtaining module 106, a user configuration importing module 108, and a history importing module 110, where:
an installed browser detection module 102, configured to detect an installed browser application, and acquire a type of the installed browser application and a database file of a history corresponding to the type;
a recent browser determining module 104, configured to determine a recently used browser application according to the database file;
a user configuration storage address obtaining module 106, configured to obtain a user configuration storage address corresponding to the type of the recently used browser;
the user configuration importing module 108 is configured to read and analyze user configuration according to the user configuration storage address, and configure a target browser according to a value obtained through analysis under a preset attribute item;
and the history record importing module 110 is configured to extract data items of a history record according to the database file of the history record of the most recently used browser, and store the data items in the database file of the history record of the target browser.
Optionally, in one embodiment, the latest browser determining module 104 is further configured to detect a modification time in a file attribute of the database file, and determine an installed browser corresponding to the database file with the latest modification time as the latest browser application.
Optionally, in one embodiment, the preset attribute items include: and newly building a tab page position, opening the front and the back of a link by clicking, closing the tab page by double clicking, closing the tab page by right key, reminding when closing a multi-tab page, opening the front and the back of a bookmark by clicking, and opening the front and the back of an address bar during input.
Optionally, in one embodiment, the history importing module 110 is further configured to extract a preset number of data items of the history record according to the database file of the history record of the most recently used browser in the order from near to far according to time.
Optionally, in an embodiment, the user configuration storage address obtaining module 106 is further configured to obtain a preset file path corresponding to the type of the recently-used browser, or obtain a preset registry key corresponding to the type of the recently-used browser, and obtain a file path corresponding to the registry key.
Optionally, in one embodiment, the history importing module 110 is further configured to access a database file of the history of the recently-used browser through an SQL interface function, and extract data items of the history stored in the database file by executing a preset SQL statement corresponding to the type of the recently-used browser.
Optionally, in an embodiment, as shown in fig. 5, the apparatus further includes an address autocomplete module 112, configured to receive a keyword input in an address bar or a search bar of the target browser after the target browser is initially started; searching a historical record matched with the keyword in a database file of the historical record of the target browser, wherein the historical record of the target browser is the historical record extracted according to the database file of the historical record of the most recently used browser; displaying the history records matched with the keywords in an information prompt box corresponding to the address bar or the search bar; and when the history record which is displayed in the information prompt box and matched with the keyword is selected, skipping to a webpage link corresponding to the selected history record.
The embodiment of the invention has the following beneficial effects:
after the method and the device for importing the browser data are adopted, a user can not perceive the configuration and the history of the commonly used browser when installing a new browser, so that the user does not feel strange when using a newly installed target browser.
Meanwhile, due to the fact that the historical records of other browsers are introduced, a user can conveniently check the past historical records of the newly installed target browser, and product experience of the new user is improved.
In one embodiment, as shown in FIG. 6, FIG. 6 illustrates a terminal 10 of a von Neumann architecture based computer system that runs the above-described method of importing browser data. The computer system can be terminal equipment such as a smart phone, a tablet computer, a palm computer, a notebook computer or a personal computer. Specifically, an external input interface 1001, a processor 1002, a memory 1003, and an output interface 1004 connected through a system bus may be included. The external input interface 1001 may optionally include at least a network interface 10012. Memory 1003 can include external memory 10032 (e.g., a hard disk, optical or floppy disk, etc.) and internal memory 10034. The output interface 1004 may include at least a display 10042 or the like.
In the present embodiment, the method is executed based on a computer program, program files of which are stored in the external memory 10032 of the computer system 10 based on the von neumann architecture, loaded into the internal memory 10034 at the time of execution, and then compiled into machine code and then transferred to the processor 1002 for execution, so that the logically installed browser detection module 102, the latest browser determination module 104, the user configuration storage address acquisition module 106, the user configuration import module 108, and the history import module 110 are formed in the computer system 10 based on the von neumann architecture. In the execution process of the method for importing browser data, the input parameters are all received through the external input interface 1001, and are transferred to the memory 1003 for caching, and then are input into the processor 1002 for processing, and the processed result data is cached in the memory 1003 for subsequent processing, or is transferred to the output interface 1004 for outputting.
The above disclosure is only for the purpose of illustrating the preferred embodiments of the present invention, and it is therefore to be understood that the invention is not limited by the scope of the appended claims.

Claims (16)

1. A method for importing browser data, comprising:
detecting an installed browser application, and acquiring the type of the installed browser application and a database file of a historical record corresponding to the type;
determining a recently used browser application according to the database file;
acquiring a user configuration storage address corresponding to the type of the recently used browser application;
reading and analyzing user configuration according to the user configuration storage address, and configuring a target browser application according to a value under a preset attribute item obtained through analysis;
extracting historical record data items according to the historical record database file of the recently used browser application, and storing the historical record data items into the historical record database file of the target browser application;
the user configuration of the installed browser application is stored in a plaintext file form, historical record information is stored in an SQLite database form, and after the configuration file of the installed browser application and the historical record database file are determined, a preset SQL statement corresponding to the type of the recently used browser is executed to extract the historical record data item stored in the database file; and reading data of the configuration file of the installed browser application according to a specified format according to the imported configuration contrast relation between the configuration file of the installed browser application and the target browser application.
2. The method for importing browser data according to claim 1, wherein the determining of the most recently used browser application from the database file is:
and detecting the modification time in the file attribute of the database file, and determining the installed browser application corresponding to the database file with the latest modification time as the latest used browser application.
3. The method for importing browser data according to claim 1, wherein the preset attribute items include: and newly building a tab page position, opening the front and the back of a link by clicking, closing the tab page by double clicking, closing the tab page by right key, reminding when closing a multi-tab page, opening the front and the back of a bookmark by clicking, and opening the front and the back of an address bar during input.
4. The method for importing browser data according to claim 1, wherein the extracting historical data items from the historical database file of the most recently used browser application comprises:
and extracting a preset number of historical data items according to the database file of the historical records of the recently used browser application from near to far according to the time sequence.
5. The method for importing browser data according to claim 1, wherein the step of obtaining the user configuration storage address corresponding to the type of the most recently used browser application includes:
and acquiring a preset file path corresponding to the type of the recently used browser application, or acquiring a preset registry key corresponding to the type of the recently used browser application, and acquiring a file path corresponding to the registry key.
6. The method for importing browser data according to claim 1, wherein the step of extracting historical data items from the historical database file of the most recently used browser application comprises:
and accessing the database file of the history record of the recently used browser application through an SQL interface function, and extracting the data items of the history record stored in the database file by executing a preset SQL statement corresponding to the type of the recently used browser application.
7. The method for importing browser data according to claim 1, wherein the method further comprises:
after the target browser application is started for the first time, receiving keywords input in an address bar or a search bar of the target browser application;
searching a historical record matched with the keyword in a database file of the historical record of the target browser application, wherein the historical record of the target browser application is the historical record extracted from the database file of the historical record of the recently used browser application;
displaying the history records matched with the keywords in an information prompt box corresponding to the address bar or the search bar;
and when the history record which is displayed in the information prompt box and matched with the keyword is selected, skipping to a webpage link corresponding to the selected history record.
8. An apparatus for importing browser data, comprising:
the installed browser detection module is used for detecting the installed browser application and acquiring the type of the installed browser application and a database file of a historical record corresponding to the type;
the latest browser determining module is used for determining the latest browser application according to the database file;
a user configuration storage address acquisition module, configured to acquire a user configuration storage address corresponding to the type of the recently used browser application;
the user configuration importing module is used for reading and analyzing user configuration according to the user configuration storage address and configuring target browser application according to values under preset attribute items obtained through analysis;
the history record importing module is used for extracting data items of history records according to the database file of the history record of the recently used browser application and storing the data items into the database file of the history record of the target browser application;
the user configuration of the installed browser application is stored in a plaintext file form, historical record information is stored in an SQLite database form, and after the configuration file of the installed browser application and the historical record database file are determined, a preset SQL statement corresponding to the type of the recently used browser is executed to extract the historical record data item stored in the database file; and reading data of the configuration file of the installed browser application according to a specified format according to the imported configuration contrast relation between the configuration file of the installed browser application and the target browser application.
9. The apparatus for importing browser data according to claim 8, wherein the latest browser determining module is further configured to detect a modification time in a file attribute of the database file, and determine an installed browser application corresponding to the database file with the latest modification time as the latest browser application.
10. The apparatus for importing browser data according to claim 8, wherein the preset attribute items include: and newly building a tab page position, opening the front and the back of a link by clicking, closing the tab page by double clicking, closing the tab page by right key, reminding when closing a multi-tab page, opening the front and the back of a bookmark by clicking, and opening the front and the back of an address bar during input.
11. The apparatus for importing browser data according to claim 8, wherein the history import module is further configured to extract a preset number of history data items from a database file of the history of the most recently used browser application in a time order from near to far.
12. The apparatus for importing browser data according to claim 8, wherein the user configuration storage address obtaining module is further configured to obtain a preset file path corresponding to the type of the most recently used browser application, or obtain a preset registry key corresponding to the type of the most recently used browser application, and obtain the file path corresponding to the registry key.
13. The apparatus for importing browser data according to claim 8, wherein the history import module is further configured to access a database file of the history of the most recently used browser application through an SQL interface function, and extract the data items of the history stored in the database file by executing a preset SQL statement corresponding to the type of the most recently used browser application.
14. The apparatus for importing browser data according to claim 8, wherein the apparatus further comprises an address autocomplete module, configured to receive a keyword input in an address bar or a search bar of the target browser application after the target browser application is initially started; searching a historical record matched with the keyword in a database file of the historical record of the target browser application, wherein the historical record of the target browser application is the historical record extracted from the database file of the historical record of the recently used browser application; displaying the history records matched with the keywords in an information prompt box corresponding to the address bar or the search bar; and when the history record which is displayed in the information prompt box and matched with the keyword is selected, skipping to a webpage link corresponding to the selected history record.
15. A computer device comprising a processor, an input interface, an output interface, and a memory, the processor, the input interface, the output interface, and the memory being interconnected, wherein the memory is configured to store a computer program comprising program instructions, the processor being configured to invoke the program instructions to perform the method of any of claims 1-7.
16. A computer-readable storage medium, characterized in that the computer-readable storage medium has stored therein program instructions for executing the method according to any one of claims 1-7.
CN201610396741.5A 2016-06-03 2016-06-03 Method and device for importing browser data Active CN106095883B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610396741.5A CN106095883B (en) 2016-06-03 2016-06-03 Method and device for importing browser data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610396741.5A CN106095883B (en) 2016-06-03 2016-06-03 Method and device for importing browser data

Publications (2)

Publication Number Publication Date
CN106095883A CN106095883A (en) 2016-11-09
CN106095883B true CN106095883B (en) 2021-01-15

Family

ID=57448533

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610396741.5A Active CN106095883B (en) 2016-06-03 2016-06-03 Method and device for importing browser data

Country Status (1)

Country Link
CN (1) CN106095883B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112905934B (en) * 2021-02-07 2022-10-28 龙芯中科(合肥)技术有限公司 Data import method and device, electronic equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1968261A (en) * 2005-11-14 2007-05-23 联想(北京)有限公司 Method for resource sharing in WLAN
CN101291304A (en) * 2008-06-13 2008-10-22 清华大学 Transplantable network information sharing method
CN101882074A (en) * 2010-03-15 2010-11-10 浪潮集团山东通用软件有限公司 Method and system for graphic user interface combination and layout
CN104182493A (en) * 2014-08-12 2014-12-03 可牛网络技术(北京)有限公司 Data synchronization method and device as well as terminal
CN104901835A (en) * 2015-05-22 2015-09-09 杭州华三通信技术有限公司 Method and device for configuring map-server in locator identity separation protocol network

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060195494A1 (en) * 2005-02-09 2006-08-31 Process Path, Inc. Compiler, system and method for defining, assigning, executing and monitoring processes and tasks in process management applications
US9798822B2 (en) * 2010-06-29 2017-10-24 Apple Inc. Location based grouping of browsing histories

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1968261A (en) * 2005-11-14 2007-05-23 联想(北京)有限公司 Method for resource sharing in WLAN
CN101291304A (en) * 2008-06-13 2008-10-22 清华大学 Transplantable network information sharing method
CN101882074A (en) * 2010-03-15 2010-11-10 浪潮集团山东通用软件有限公司 Method and system for graphic user interface combination and layout
CN104182493A (en) * 2014-08-12 2014-12-03 可牛网络技术(北京)有限公司 Data synchronization method and device as well as terminal
CN104901835A (en) * 2015-05-22 2015-09-09 杭州华三通信技术有限公司 Method and device for configuring map-server in locator identity separation protocol network

Also Published As

Publication number Publication date
CN106095883A (en) 2016-11-09

Similar Documents

Publication Publication Date Title
US7831609B1 (en) System and method for searching, formulating, distributing and monitoring usage of predefined internet search queries
US9239884B2 (en) Electronic document processing with automatic generation of links to cited references
US8386955B1 (en) User-optimized content for web browsing windows
US9916390B2 (en) Managing web browser cache for offline browsing
US20100318422A1 (en) Method for recommending information of goods and system for executing the method
CN103366002B (en) Personalized method for vertical search and device
CN102930057A (en) Search implementation method and device
CN102930058A (en) Method and device for realizing search in address field of browser
US20100306237A1 (en) Hiding search box based on search provider settings
US20150242470A1 (en) Systems and methods for recommending software applications
TWI417751B (en) Information providing device, information providing method, information application program, and information recording medium
CN106033433B (en) Information searching method and device
CN113360753A (en) Information recommendation method, device, equipment and medium based on user historical behaviors
TWI399657B (en) A provider, a method of providing information, a program, and an information recording medium
CN106095883B (en) Method and device for importing browser data
CN107783983B (en) Information display method and device
CN105243073A (en) Bookmark access method and device and terminal
CN111723210A (en) Method and device for storing data table, computer equipment and readable storage medium
CN109684156B (en) Monitoring method, device, terminal and storage medium based on mixed mode application
EP3446236A1 (en) Method and system for providing additional information relating to primary information
US20220027419A1 (en) Smart search and recommendation method for content, storage medium, and terminal
CN112416500B (en) Information processing method and electronic equipment
CN110515618B (en) Page information input optimization method, equipment, storage medium and device
CN109948034B (en) Method and device for extracting page information based on filtering session
CN113656737B (en) Webpage content display method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20221118

Address after: 1402, Floor 14, Block A, Haina Baichuan Headquarters Building, No. 6, Baoxing Road, Haibin Community, Xin'an Street, Bao'an District, Shenzhen, Guangdong 518133

Patentee after: Shenzhen Yayue Technology Co.,Ltd.

Address before: 2, 518000, East 403 room, SEG science and Technology Park, Zhenxing Road, Shenzhen, Guangdong, Futian District

Patentee before: TENCENT TECHNOLOGY (SHENZHEN) Co.,Ltd.