ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Interesting find/replace problem with db dump

July 21, 2010 3:34pm

Subscribe [1]
  • #1 / Jul 21, 2010 3:34pm

    carvingCode

    380 posts

    Related to a previous post...

    I successfully replaced the funky added text that Plesk is adding to a db dump using find/replace in NotePad++.  BTW: Not only was there a ‘?phpmyadmin=....’ version, there was also another version, ‘&phpmyadmin;=....’.  Over 300 affected items total in my db dump.

    After the find/replace, I imported the db dump using phpmyadmin (on local dev PC).  Logged into control panel just fine.  Links worked properly.  All looked well.

    Then I noticed that content editors had hard-coded URLs (?!) into too many entries to edit manually (> 280)  (Moving website to new located; those hard-coded URLs will break).  So, decided to use the find/replace routine on that as well.

    Problem: After replacing the hard-coded URLs with references to the new site’s URL I could not log into the control panel.  Login form returns, ‘can’t find that user’.

    I looked carefully at the raw db dump file and the user is in the ‘exp_members’ table.  I double-checked my find/replace text strings - all OK.

    Have been scratching my head on this on all afternoon.  Have redone the procedure several times with the same result.  Even did the URL replace by itself and couldn’t log in.

    If I only replace the funky ‘..phpmyadmin=’ text, I can log in.

    Any clues as to what may be happening?

    TIA

  • #2 / Jul 21, 2010 3:41pm

    Lisa Wess

    20502 posts

    Moved to technical support; made a guess at version. 50/50 chance. Let me know if I’m wrong.

    Did your find and replace touch exp_sites?  If so you’ve corrupted that table and need to restore it; it is a serialized array and you have to be very careful about modifications to it or you will break your site.

  • #3 / Jul 21, 2010 3:50pm

    carvingCode

    380 posts

    Did your find and replace touch exp_sites?  If so you’ve corrupted that table and need to restore it; it is a serialized array and you have to be very careful about modifications to it or you will break your site.

    Just checked.  Yes, the find/replace would have affected several items in its data.

    I guess I could do the find/replace on everything but that table… Where is that data created/edited?  In the CP, I assume?

  • #4 / Jul 21, 2010 3:54pm

    Ingmar

    29245 posts

    Yes, exp_sites can’t be edited directly, certain configuration settings of the CP are written there by EE.

  • #5 / Jul 21, 2010 4:07pm

    carvingCode

    380 posts

    Yes, exp_sites can’t be edited directly, certain configuration settings of the CP are written there by EE.

    OK.  I did what I mentioned above; made changes everywhere but in the ‘exp_sites’ table.  All is beautiful!  (This is really going to save me a lot of time…)

    Much appreciate the quick response from Lisa and Ingmar.

    Thanks!

  • #6 / Jul 21, 2010 4:14pm

    Ingmar

    29245 posts

    Very glad to hear it 😊 please post again in case there’s anything else.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases