Home > Article > WeChat Applet > Detailed steps of WeChat chat history viewer for iOS
[2016.10.14]
Thank you for your love for this software! Recently, it was discovered that the storage method of the iOS WeChat database has changed. The friend data originally stored in the Friend table has now been changed to the friend_meta table, and the fields are completely different. Therefore, the current version of this software cannot view the latest WeChat chat records. , the blogger now has a very urgent task on hand. After it is completed, he will research and develop a new version. This article will be updated and notified at that time. Thank you again for your support!
Is WeChat on iPhone taking up more and more space? Don't want to delete pictures? Don't want to delete the video? Then transfer it to the computer hard drive, use this software to view and search in Windows, and free up space on your mobile phone! This article introduces the usage instructions of the software in detail, introduces the data storage format of WeChat chat records, and provides the download address of the software and source code. Finally, it provides a method to clean up the picture and video data in iPhone chat records.
As the days of using WeChat get longer, WeChat takes up more and more space in the mobile phone, iPhone Storage space is also becoming increasingly scarce, with pictures and videos taking up the largest space. People like me who pursue integrity in everything insist on not deleting any photos or videos. I like to take photos and videos with my mobile phone. , every once in a while, move the photos and videos to the computer for storage and free up the phone. But when I have to free up space every two days, I find that this is not a long-term solution. I looked at WeChat and it has taken up more than 2 gigabytes of space. It is not an option to continue like this. Now Tencent officially does not have chat records for the iOS version of WeChat. Dump hard disk tool (Android seems to have one); even if there is, it requires that it can be viewed on Windows as on a mobile phone; WeChat’s built-in chat history backup and recovery function is designed for dumping to other devices, and chat records can only be stored on the server 7 days, and data as big as 2G needs to be uploaded to Ma Yue in the next year?
Therefore, just write a chat history viewer yourself and move the data to the computer’s large hard drive, so that you can safely delete pictures and videos on your mobile phone. The following are the instructions for using the WeChat chat record viewer developed by me, as well as the chat record data storage format that I analyzed and guessed. However, it is incomplete and can only display the most important data content. Interested friends can analyze and improve it together.
First of all, this software currently only supports WeChat chat history on iPhone. The following is a detailed description of how to use the software.
2.1 Data dump
Use third-party tools such as iTools to export the Documents directory in the WeChat application Save it to the computer hard drive. This directory contains the chat records of all WeChat accounts logged in on this iPhone. You can also export the chat records of only a certain account. The data of each WeChat account is stored in a folder named after the MD5 value of the WeChat ID. For example, the folders with 32-digit names in the Documents directory in Figure 2-1 are different WeChat accounts.
Figure 2-1 Documents directory example
2.2 Select database
The chat record database file is stored in the DB file in the WeChat account folder, and the file name is MM.sqlite. At the end of this article, we will provide an example of a chat record. When the program is running, you will be prompted to select a database file. Just select the following file: 06af9525a11ebb4f49ec72be6d165d10\DB\MM.sqlite.
2.3 Main interface
Start the software and select the database. After loading is complete, the main interface of the program is shown in Figure 2-2. On the left is the friend list of the WeChat account, sorted by the first letter of Pinyin, and on the right is the specific chat record. content. The friend list is divided into 3 tabs, namely "Friends", "Group", and "Others". As the name suggests, individual friends are on the "Friends" tab, group chats are on the "Group" tab, and the remaining subscription accounts and services No. and so on in the "Others" tab. You can search for friends above the friend list, and search for text above the chat content. Click on a friend in the friend list, and the chat content window on the right will load the specific content of the chat with the friend.
Since this program uses the trial version of the EO.WebBrowser control (the blogger is poor~ ), every time the program is started, the purchase license will appear on the lower side of the chat content window. Tip, just close it and it will not affect subsequent reading.
Figure 2-2 WeChat chat record viewer main interface
2.4 Data type
2.4.1 The text
is displayed in bubble style as shown on the mobile phone, as shown in Figure 2-3.
Figure 2-3 Data type example: text
2.4.2 Expression
can display the small emoji expressions that come with WeChat, as shown in Figure 2-4. See Figure 2-5 for all emoji expressions that can be displayed.
Figure 2-4 Data type example: emoji expression
Figure 2-5 All emoji that can be displayed
In addition to emoji, WeChat’s official animated emoticons can also be displayed, as shown in Figure 2-6.
Figure 2-6 Data type example: animated expression
Except these two In addition to emoticons, WeChat users often see many unofficial emoticons. If you want to display them in this software, you need to perform additional data export work, which is not complicated: still use iTools to open this directory of WeChat App: /Library/WechatPrivate/ emoticon1, copy this folder to the installation directory of this software, and overwrite the original emoticon1 folder.
2.4.3 Picture
The picture in the chat history is shown in Figure 2-7. Clicking on the picture will call the default *.jpg files are associated with a program to view large Detailed steps of WeChat chat history viewer for iOSs. The default program is Windows Photo Viewer.
Figure 2-7 Data type example: picture
2.4.4 Video & Short Video
The video and short video in the chat history are shown in Figure 2-8. Clicking on the video will call the default *.mp4 files associated with the program to watch videos.
Figure 2-8 Data type example: video & short video
2.4.5 Voice
The voice in the chat record is shown in Figure 2-9. Clicking it will play the voice content.
Figure 2-9 Example of data type: Voice
2.4.6 Sharing link
The sharing link in the chat history is shown in Figure 2-10. Clicking the link will call the browser to view the original web page.
Figure 2-10 Data type example: sharing link
2.4.7 Location information
The location in the chat record is shown in Figure 2-11. Clicking the link will call the browser to view specific map information, as shown in Figure 2-12.
Figure 2-11 Data type example: location information
Figure 2-12 Browser to view specific location information
2.4.8 Business Card
The business card message in the chat history is shown in Figure 2-13.
Figure 2-13 Data type example: business card
2.4.9 Voice and video calls
Voice and video in chat records The phone can only give information such as the duration of the call at that time (it is impossible for WeChat to record your call content D), as shown in Figure 2-14.
Figure 2-14 Example of data type: voice, video call
2.5 Search for friends
When there is a lot of friend data, enter the friend’s keyword in the search bar above the friend list on the left. It can be in Chinese or Pinyin, but the current version cannot be in Pinyin. For example, if you search for "Zhang San", you can enter "Zhang", "三", "zhangsan" or "zhangs", etc., but you cannot enter "zs". When entering content, the search results window will appear immediately, and friends that match the keyword will be listed, as shown in Figure 2-15. The friend who clicks on the search result will automatically load the content of the chat with him.
Figure 2-15 Example of searching for friends
2.6 Searching for chat content
The search for chat content is divided into "Search current friends" and "Search all friends", which can be selected from the drop-down box above the chat content window. Enter keywords in the search bar and press Enter to search. After the search is completed, the search results list will be displayed. After clicking on a record, the chat content window will display and highlight the keywords, as shown in Figure 2-16. Tip here: Searching all friends will take a long time.
Figure 2-16 Example of search chat content
2.7 Page jump
Chat content In the upper right corner of the window are navigation buttons for turning pages. If there are too many pages, you can directly click the page number, and the input window for jumping to the page will pop up. After entering the page number you want to view, you will jump to the page, as shown in Figure 2-17.
Figure 2-17 Page jump example
The root directory of the chat history is a folder named after the MD5 hash value of the user's WeChat ID username (not necessarily WeChat ID, see below). The following assumes that root is the root directory. The main content of the chat record is a SQLite-type database file MM.sqlite, and the path is root\DB\MM.sqlite. The following are the results of my analysis of the content format of this database.
3.1 Data table
Here are two data tables used by this software, namely the Friend table Table with Chat_XXX, XXX represents the MD5 value of the friend’s WeChat ID.
3.1.1 Friend table
This table stores all contacts, in addition to friends, it also includes non-friends, subscription accounts, Service number, etc.
(1) Field: type
This field can classify the types of friends, since this software is only divided into friends, groups, Others and other 3 categories, so you can refer to the following table as it is not used in the code of this software.
Table 1-1 Friend data table type field description (guess)
Value | Value (binary) | Description |
1 | ##0000 0000 0001 | Friends& Others |
2 | 0000 0000 0010 | Chat group&Deleted service account&Others |
3 | 0000 0000 0011 | Friends & Others |
0000 0000 0 | 100 | This friend is in the group chat, but no friend has been added|
0000 0000 0 | 101##Friends&Others | |
##0000 0000 011 | 0Non-Friends | ##7 |
111 | Friends&Others | ##67 |
00 0011 | Voice reminder | ##257000 |
1 | Friends who have been blocked in Moments | 710000 0 |
111 | Collect and star friends##2119 | 1 |
00 0111 | Pinned friends | |
259 | ##0001 0000 0011 | Friends who have been blocked in Moments |
263 | 0001 0000 0111 | Friends who have been blocked in Moments |
The above is the detailed content of Detailed steps of WeChat chat history viewer for iOS. For more information, please follow other related articles on the PHP Chinese website!