vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   IPB Snapback Removal (https://vborg.vbsupport.ru/showthread.php?t=74091)

HuangA 01-08-2005 10:00 PM

IPB Snapback Removal
 
Hi all;
First hack release, so excited :D
Ok... Anyways, so I imported from IPB 2.0 a few months back only to notice that it carried over the ugly [snapback]###[/snapback] from IPB. Since VB doesn't have such code built in, it's an eyesore to have it there and I finally decided to code a mini hack to remove it.

What this hack does is basically it goes through the list of posts in your database, checks for (unfortunetly only) the instance of [snapback]###[/snapback] appended at the end of each quote. I don't think it will remove multiple instance of it if someone did multi quote, but you can fix that by running this multiple times.

So, anyways, here's the hack and a short blurp on how to install it :)

Files to Upload: 1
Files to Edit: 1
Supported Version: UNHACKED VB3.0.5
Support Location: This thread

DO NOT FORGET TO BACK UP YOUR DATABASE BEFORE YOU USE THIS SCRIPT. ALL CHANGES MADE ARE UNREVERSABLE AND I WILL NOT BE HELD RESPONSIBLE FOR ANY SCRIPT FAILURES.

Brent H 01-09-2005 09:31 PM

Great idea :D

I've been preparing to help an IPB2 board switch to vB and I always just made a custom bbcode to replace that with just a space. This seems much cleaner though.

Erwin 01-09-2005 09:45 PM

At least you have seen the light and converted to the right program. ;)

HuangA 01-09-2005 09:52 PM

I think this can also be used to strip other bb codes that you may have previously installed but does not get carried over. If I have time, I may be interested to see if I can also code it in such a way so it searches for [bbcode=BLAH] type of bbcode...

Erwin, I've been eyeing VB since forever; IPB had always been the free escape ;)

Thanks for the input guys, greatly appreciate it. It'd be great if you click the install button if you install it :)

Jerry 01-10-2005 09:52 AM

cleaner.php can take out static bbcode, I can parse snap back to the correct vB post id, though I need a IPB database with snapback in it to be able to dev it.

HuangA 01-11-2005 02:35 PM

Jerry, what I tried to do with this script is to remove it from the quoted posts because the current vb doesn't have [snapback] as a default bbcode. Is it possible for you to modify the importer to remove it while importing? Currently it imports as such
Code:

[quote]blah blah blah, this text is quoted from a previous message
[right][snapback]_pid_of_quoted_message[/snapback][/right][/quote]
Blah blah blah, this is the replied text

I do believe I have my old IPB database still archived on the server; can you please PM me a way to drop the database file dump (.sql? .csv?) to you so you can look into updating the ImpEx?

Cheers.

Jerry 01-11-2005 02:45 PM

PM sent.

Also you can use [ post ] tags

HuangA 01-12-2005 04:11 AM

Quote:

Originally Posted by Jerry
PM sent.

Also you can use [ post ] tags

last reply
https://vborg.vbsupport.ru/showthread.php?p=593515
(testing)

Edit:
Ah... I see... I don't know if I can update the current script to reflect it accordingly... Are postid's retained during the transfer? As far as I know (I may be wrong) the postid is an auto_increment value, which means if certain posts in between were deleted, the ladder ones will be one (or more) postid's off, right?

IE:
IPB Postid 1 / VB Postid 1: Hi blah blah blah
IPB Postid 2 / VB Postid 2: Hello, replying to postid1
IPB Postid 3 / -----------: @$%^ this board is @$% (Admin DELETE)
IPB Postid 4 / VB Postid 3: hey, I like this board
IPB Postid 5 / VB Postid 4: quote + snapback to (IPB) 4 I'll second that comment!

If you do a [post] for that one, would it not snap back to 4, which becomes itself?

Brent H 01-12-2005 08:14 AM

Quote:

Originally Posted by Erwin
At least you have seen the light and converted to the right program. ;)

LOL my INITIAL forum choice was vB ;) I'm helping others see the light. Wooot.

Jerry 01-13-2005 01:04 AM

Quote:

Originally Posted by HuangA
......which means if certain posts in between were deleted, the ladder ones will be one (or more) postid's off, right?........

ImpEx imports the import post id so this can be sorted out even if posts are deleted or moved as its linked to the imported post and not the counters.

Have a look at the post table for the id and the importpostid.

Its a 1-2-1 mapping from ImpExDatabase::get_posts_ids() to swap them out.


All times are GMT. The time now is 10:00 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01281 seconds
  • Memory Usage 1,736KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete