Announcement

Collapse
No announcement yet.

cleaner.php Config for UBB Threads

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • cleaner.php Config for UBB Threads

    I've just imported from UBB Threads, and am preparing to run cleaner.php. Are there any thorough and well-tested examples of the $replacer settings to run against a UBB Threads import?

    As I begin to build my $replacer array, I see that this is going to be very tedious. I'm not the first to do this.

    PHP Code:
    $replacer = array(
                
    "[ QUOTE ]"        => "[QUOTE]",
                
    "[ /QUOTE ]"    => "[/QUOTE]",
                
    "[img]/ubbthreads/images/graemlins/cool.gif[/img]"    => ":cool:",
                
    "<font color="    => "[COLOR=",
                
    ""    => ""
    ); 
    I've searched the forums and found only bits and pieces... If there are any "templates" out there that anyone can offer, I'd be most appreciative.

    Thank you in advance for you help.

    - Justin

  • #2
    I have not yet seen members share their cleaner.php settings with us yet either.

    Comment


    • #3
      cleaner.php settings are normaly very specific to issues a customer had during the import, there are no 'tried and true' settings.
      Best Regards
      Colin Frei

      Please don't contact me per PM.

      Comment


      • #4
        That's disappointing, but thank you for responding.

        I will post my settings when I'm done, and maybe it will help someone out.

        - Justin

        Comment


        • #5
          UBB Threads Settings for cleaner.php

          As promised, the following $replacer array worked well for my UBB Threads 6.5 conversion. It's far from "complete" for all scenarios, but it was complete for my board. Please note that I made it remove color tags, because my regular expression knowledge is weak.

          PHP Code:
          $replacer = array(
          "[ QUOTE ]"        => "[QUOTE]",
          "[ /QUOTE ]"    => "[/QUOTE]",
          "[/ QUOTE ]"    => "[/QUOTE]",
          "&amp;"            => "&",
          "[img]/ubbthreads/images/graemlins/ooo.gif[/img]"        => "",
          "[img]/ubbthreads/images/graemlins/mad.gif[/img]"        => ":mad:",
          "[img]/ubbthreads/images/graemlins/cool.gif[/img]"        => ":cool:",
          "[img]/ubbthreads/images/graemlins/smile.gif[/img]"        => ":)",
          "[img]/ubbthreads/images/graemlins/frown.gif[/img]"        => ":(",
          "[img]/ubbthreads/images/graemlins/blush.gif[/img]"        => ":o",
          "[img]/ubbthreads/images/graemlins/crazy.gif[/img]"        => "",
          "[img]/ubbthreads/images/graemlins/laugh.gif[/img]"        => ":D",
          "[img]/ubbthreads/images/graemlins/shocked.gif[/img]"    => ":eek:",
          "[img]/ubbthreads/images/graemlins/smirk.gif[/img]"        => ":rolleyes:",
          "[img]/ubbthreads/images/graemlins/confused.gif[/img]"    => ":D",
          "[img]/ubbthreads/images/graemlins/grin.gif[/img]"        => ":D",
          "[img]/ubbthreads/images/graemlins/wink.gif[/img]"        => ";)",
          "[img]/ubbthreads/images/graemlins/tounge.gif[/img]"    => ":p",
          "[img]/ubbthreads/images/graemlins/yum.gif[/img]"        => "",
          "[img]/ubbthreads/images/graemlins/coffee.gif[/img]"    => "",
          "\'"                => "'",
          "<!--color-->"        => "",
          "<hr />"            => "",
          '<ul type="square">'=> "[LIST]",
          "</font>"            => "",
          '<font class="post">'    => "",
          '<font class="small">'    => "",
          '<font color="#666666">'    => "",
          '<font color="black">'    => "",
          '<font color="blue">'    => "",
          '<font color="green">'    => "",
          '<font color="purple">'    => "",
          '<font color="red">'    => "",
          '<font color="white">'    => ""
          ); 

          Comment


          • #6
            Using regular expressions in cleaner.php

            It's pretty straightforward to add regular expressions in cleaner.php, but it requires some coding. I just posted it in my personal UBB.Threads migration experience thread.

            Update: I created an issue in the ImpEx tracker asking for adding regular expression search & replace to cleaner.php: Feature request: Providing regex support in cleaner.php. Feel free to vote on it if you deem it relevant.
            Last edited by shutterfreak; Thu 16 Sep '10, 12:07am.

            Comment


            • #7
              How to avoid having to run cleaner.php...

              FWIW in certain circumstances you can avoid having to run cleaner.php, if you edit the ImpEx importer itself so it correctly imports the data.

              See this post for details on how to do this for e.g. UBB.Threads (same principle for any ImpEx importer).

              Comment

              widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
              Working...
              X