interconnectit / Search-Replace-DB

This script was made to aid the process of migrating PHP and MySQL based websites. Works with most common CMSes.
https://interconnectit.com/products/search-and-replace-for-wordpress-databases/
GNU General Public License v3.0
4k stars 851 forks source link

Unnecessary changes in database. #388

Open htmldiz opened 2 weeks ago

htmldiz commented 2 weeks ago

Hi. I came across issues that cut my eyes for Example: Before: a:14:{s:13:"system_colors";a:4:{i:0;a:3:{s:3:"_id";s:7:"primary";s:5:"title";s:7:"Primary";s:5:"color";s:7:"#B29547";}i:1;a:3:{s:3:"_id";s:9:"secondary";s:5:"title";s:9:"Secondary";s:5:"color";s:7:"#768467";}i:2;a:3:{s:3:"_id";s:4:"text";s:5:"title";s:4:"Text";s:5:"color";s:7:"#000000";}i:3;a:3:{s:3:"_id";s:6:"accent";s:5:"title";s:6:"Accent";s:5:"color";s:7:"#AA7088";}}s:13:"custom_colors";a:6:{i:0;a:3:{s:3:"_id";s:7:"69ec943";s:5:"title";s:5:"White";s:5:"color";s:7:"#FFFFFF";}i:1;a:3:{s:3:"_id";s:7:"0f917bc";s:5:"title";s:6:"Purple";s:5:"color";s:7:"#B43D83";}i:2;a:3:{s:3:"_id";s:7:"24d82a8";s:5:"title";s:4:"Pink";s:5:"color";s:7:"#DA568F";}i:3;a:3:{s:3:"_id";s:7:"d0e069f";s:5:"title";s:10:"Light Pink";s:5:"color";s:7:"#F4809C";}i:4;a:3:{s:3:"_id";s:7:"d5807f1";s:5:"title";s:15:"Background Pink";s:5:"color";s:7:"#FBDEDB";}i:5;a:3:{s:3:"_id";s:7:"3addf1b";s:5:"title";s:8:"BG Peach";s:5:"color";s:7:"#FCEDEB";}}s:17:"system_typography";a:4:{i:0;a:9:{s:3:"_id";s:7:"primary";s:5:"title";s:7:"Primary";s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:7:"Frunchy";s:22:"typography_font_weight";s:3:"400";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:75;s:5:"sizes";a:0:{}}s:22:"typography_line_height";a:3:{s:4:"unit";s:2:"em";s:4:"size";d:0.8;s:5:"sizes";a:0:{}}s:27:"typography_font_size_mobile";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:55;s:5:"sizes";a:0:{}}s:29:"typography_line_height_mobile";a:3:{s:4:"unit";s:2:"em";s:4:"size";i:1;s:5:"sizes";a:0:{}}}i:1;a:8:{s:3:"_id";s:9:"secondary";s:5:"title";s:9:"Secondary";s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:7:"Frunchy";s:22:"typography_font_weight";s:3:"400";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:55;s:5:"sizes";a:0:{}}s:22:"typography_line_height";a:3:{s:4:"unit";s:2:"em";s:4:"size";d:0.8;s:5:"sizes";a:0:{}}s:27:"typography_font_size_mobile";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:40;s:5:"sizes";a:0:{}}}i:2;a:7:{s:3:"_id";s:4:"text";s:5:"title";s:4:"Text";s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:7:"Poppins";s:22:"typography_font_weight";s:3:"400";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:16;s:5:"sizes";a:0:{}}s:27:"typography_font_size_mobile";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:14;s:5:"sizes";a:0:{}}}i:3;a:8:{s:3:"_id";s:6:"accent";s:5:"title";s:6:"Accent";s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:15:"Blacker Display";s:22:"typography_font_weight";s:3:"400";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:18;s:5:"sizes";a:0:{}}s:25:"typography_letter_spacing";a:3:{s:4:"unit";s:2:"em";s:4:"size";d:0.05;s:5:"sizes";a:0:{}}s:27:"typography_font_size_mobile";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:16;s:5:"sizes";a:0:{}}}}s:17:"custom_typography";a:1:{i:0;a:8:{s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:15:"Blacker Display";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:21;s:5:"sizes";a:0:{}}s:22:"typography_font_weight";s:3:"400";s:22:"typography_line_height";a:3:{s:4:"unit";s:2:"em";s:4:"size";s:0:"";s:5:"sizes";a:0:{}}s:29:"typography_line_height_mobile";a:3:{s:4:"unit";s:2:"em";s:4:"size";i:1;s:5:"sizes";a:0:{}}s:3:"_id";s:7:"ee6282a";s:5:"title";s:13:"2nd Secondary";}}s:21:"default_generic_fonts";s:10:"Sans-serif";s:9:"site_name";s:13:"Shira Francis";s:19:"page_title_selector";s:14:"h1.entry-title";s:15:"activeItemIndex";i:1;s:11:"viewport_md";i:768;s:11:"viewport_lg";i:1025;s:18:"active_breakpoints";a:3:{i:0;s:15:"viewport_mobile";i:1;s:15:"viewport_tablet";i:2;s:15:"viewport_laptop";}s:15:"viewport_laptop";i:1440;s:16:"site_description";s:71:"Enriching Jewish Marriages WITH EXPERT GUIDANCE ROOTED IN DA’AS TORAH";s:15:"container_width";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:1440;s:5:"sizes";a:0:{}}} After: a:14:{s:13:"system_colors";a:4:{i:0;a:3:{s:3:"_id";s:7:"primary";s:5:"title";s:7:"Primary";s:5:"color";s:7:"#B29547";}i:1;a:3:{s:3:"_id";s:9:"secondary";s:5:"title";s:9:"Secondary";s:5:"color";s:7:"#768467";}i:2;a:3:{s:3:"_id";s:4:"text";s:5:"title";s:4:"Text";s:5:"color";s:7:"#000000";}i:3;a:3:{s:3:"_id";s:6:"accent";s:5:"title";s:6:"Accent";s:5:"color";s:7:"#AA7088";}}s:13:"custom_colors";a:6:{i:0;a:3:{s:3:"_id";s:7:"69ec943";s:5:"title";s:5:"White";s:5:"color";s:7:"#FFFFFF";}i:1;a:3:{s:3:"_id";s:7:"0f917bc";s:5:"title";s:6:"Purple";s:5:"color";s:7:"#B43D83";}i:2;a:3:{s:3:"_id";s:7:"24d82a8";s:5:"title";s:4:"Pink";s:5:"color";s:7:"#DA568F";}i:3;a:3:{s:3:"_id";s:7:"d0e069f";s:5:"title";s:10:"Light Pink";s:5:"color";s:7:"#F4809C";}i:4;a:3:{s:3:"_id";s:7:"d5807f1";s:5:"title";s:15:"Background Pink";s:5:"color";s:7:"#FBDEDB";}i:5;a:3:{s:3:"_id";s:7:"3addf1b";s:5:"title";s:8:"BG Peach";s:5:"color";s:7:"#FCEDEB";}}s:17:"system_typography";a:4:{i:0;a:9:{s:3:"_id";s:7:"primary";s:5:"title";s:7:"Primary";s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:7:"Frunchy";s:22:"typography_font_weight";s:3:"400";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:75;s:5:"sizes";a:0:{}}s:22:"typography_line_height";a:3:{s:4:"unit";s:2:"em";s:4:"size";d:0.80000000000000004;s:5:"sizes";a:0:{}}s:27:"typography_font_size_mobile";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:55;s:5:"sizes";a:0:{}}s:29:"typography_line_height_mobile";a:3:{s:4:"unit";s:2:"em";s:4:"size";i:1;s:5:"sizes";a:0:{}}}i:1;a:8:{s:3:"_id";s:9:"secondary";s:5:"title";s:9:"Secondary";s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:7:"Frunchy";s:22:"typography_font_weight";s:3:"400";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:55;s:5:"sizes";a:0:{}}s:22:"typography_line_height";a:3:{s:4:"unit";s:2:"em";s:4:"size";d:0.80000000000000004;s:5:"sizes";a:0:{}}s:27:"typography_font_size_mobile";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:40;s:5:"sizes";a:0:{}}}i:2;a:7:{s:3:"_id";s:4:"text";s:5:"title";s:4:"Text";s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:7:"Poppins";s:22:"typography_font_weight";s:3:"400";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:16;s:5:"sizes";a:0:{}}s:27:"typography_font_size_mobile";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:14;s:5:"sizes";a:0:{}}}i:3;a:8:{s:3:"_id";s:6:"accent";s:5:"title";s:6:"Accent";s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:15:"Blacker Display";s:22:"typography_font_weight";s:3:"400";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:18;s:5:"sizes";a:0:{}}s:25:"typography_letter_spacing";a:3:{s:4:"unit";s:2:"em";s:4:"size";d:0.050000000000000003;s:5:"sizes";a:0:{}}s:27:"typography_font_size_mobile";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:16;s:5:"sizes";a:0:{}}}}s:17:"custom_typography";a:1:{i:0;a:8:{s:21:"typography_typography";s:6:"custom";s:22:"typography_font_family";s:15:"Blacker Display";s:20:"typography_font_size";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:21;s:5:"sizes";a:0:{}}s:22:"typography_font_weight";s:3:"400";s:22:"typography_line_height";a:3:{s:4:"unit";s:2:"em";s:4:"size";s:0:"";s:5:"sizes";a:0:{}}s:29:"typography_line_height_mobile";a:3:{s:4:"unit";s:2:"em";s:4:"size";i:1;s:5:"sizes";a:0:{}}s:3:"_id";s:7:"ee6282a";s:5:"title";s:13:"2nd Secondary";}}s:21:"default_generic_fonts";s:10:"Sans-serif";s:9:"site_name";s:13:"Shira Francis";s:19:"page_title_selector";s:14:"h1.entry-title";s:15:"activeItemIndex";i:1;s:11:"viewport_md";i:768;s:11:"viewport_lg";i:1025;s:18:"active_breakpoints";a:3:{i:0;s:15:"viewport_mobile";i:1;s:15:"viewport_tablet";i:2;s:15:"viewport_laptop";}s:15:"viewport_laptop";i:1440;s:16:"site_description";s:71:"Enriching Jewish Marriages WITH EXPERT GUIDANCE ROOTED IN DA’AS TORAH";s:15:"container_width";a:3:{s:4:"unit";s:2:"px";s:4:"size";i:1440;s:5:"sizes";a:0:{}}}

htmldiz commented 2 weeks ago

Why d: is changed?

htmldiz commented 2 weeks ago

Another issue: Before: s:915:"O:59:"Gravity_Forms\Gravity_Forms\License\GF_License_API_Response":5:{s:4:"data";a:1:{i:0;a:19:{s:15:"license_key_md5";s:32:"a532566f7ae76809b436fb024371d56b";s:12:"date_created";s:19:"2014-08-15 17:41:32";s:12:"date_expires";s:19:"2025-10-16 16:00:00";s:12:"renewal_date";s:19:"2025-09-16 16:00:00";s:9:"is_active";s:1:"1";s:24:"is_subscription_canceled";s:1:"0";s:12:"product_code";s:5:"GFDEV";s:12:"product_name";s:31:"Gravity Forms Developer License";s:18:"is_near_expiration";b:0;s:14:"days_to_expire";i:385;s:10:"is_expired";b:0;s:8:"is_valid";b:1;s:22:"is_past_renewal_period";b:0;s:9:"is_legacy";b:1;s:12:"is_perpetual";b:0;s:9:"max_sites";s:9:"unlimited";s:12:"active_sites";i:83;s:15:"remaining_seats";s:9:"unlimited";s:20:"is_multisite_allowed";b:1;}}s:6:"errors";a:0:{}s:6:"status";s:9:"valid_key";s:4:"meta";a:0:{}s:5:"strat";O:63:"Gravity_Forms\Gravity_Forms\Transients\GF_WP_Transient_Strategy":0:{}}"; After: O:59:"Gravity_Forms\Gravity_Forms\License\GF_License_API_Response":5:{s:4:"data";a:1:{i:0;a:19:{s:15:"license_key_md5";s:32:"a532566f7ae76809b436fb024371d56b";s:12:"date_created";s:19:"2014-08-15 17:41:32";s:12:"date_expires";s:19:"2025-10-16 16:00:00";s:12:"renewal_date";s:19:"2025-09-16 16:00:00";s:9:"is_active";s:1:"1";s:24:"is_subscription_canceled";s:1:"0";s:12:"product_code";s:5:"GFDEV";s:12:"product_name";s:31:"Gravity Forms Developer License";s:18:"is_near_expiration";b:0;s:14:"days_to_expire";i:385;s:10:"is_expired";b:0;s:8:"is_valid";b:1;s:22:"is_past_renewal_period";b:0;s:9:"is_legacy";b:1;s:12:"is_perpetual";b:0;s:9:"max_sites";s:9:"unlimited";s:12:"active_sites";i:83;s:15:"remaining_seats";s:9:"unlimited";s:20:"is_multisite_allowed";b:1;}}s:6:"errors";a:0:{}s:6:"status";s:9:"valid_key";s:4:"meta";a:0:{}s:5:"strat";O:63:"Gravity_Forms\Gravity_Forms\Transients\GF_WP_Transient_Strategy":0:{}}

It was string. Why it's not string anymore?