vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Forum Display Query? (Vb2 help) (https://vborg.vbsupport.ru/showthread.php?t=102858)

Poethik 12-13-2005 08:18 AM

Forum Display Query? (Vb2 help)
 
Is there a query I can run to fix my forumdisplay and showthread.
I was trying to install a hack it messed that part of my database up.

Thanks!

Zachery 12-13-2005 08:19 AM

Without knowing the original query, there ain't much we can do.

Poethik 12-13-2005 08:27 AM

1 Attachment(s)
this is what happened

// ###################### Start install db #######################
if ($action=="db") {

echo "<p>Resetting TABLE BBcode ...";
echo "<p>Templates and Files imported correctly!</p>";
doformheader("$installer","changetemp");
$DB_site->query("DROP TABLE IF EXISTS bbcode");
$DB_site->query("CREATE TABLE bbcode (
bbcodeid smallint(5) unsigned DEFAULT '0' NOT NULL auto_increment,
bbcodetag varchar(200) NOT NULL,
bbcodereplacement varchar(200) NOT NULL,
bbcodeexample varchar(200) NOT NULL,
bbcodeexplanation mediumtext NOT NULL,
twoparams smallint(6) DEFAULT '0' NOT NULL,
PRIMARY KEY (bbcodeid)
)");

$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'b', '<b>\\\\4</b>', 'Bold', 'The [b] tag allows you to write text bold', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'i', '<i>\\\\4</i>', 'Italics', 'The [i] tag allows you to write text in italics', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'email', '<a href=\"mailto:\\\\4\">\\\\4</a>', 'support@hisquad.net', 'The [email] tag allows you to include email addresses.', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'email', '<a href=\"mailto:\\\\5\">\\\\7</a>', 'HiSquad Support', 'This email tag allows you to include your own text in an email field.', 1)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'fl', '<embed src=\"\\\\5\" \\\\7 type=application/x-shockwave-flash></embed>', '[fl=http://www.hisquad.net/banner/hisquad.swf] width=\"330\" height=\"50\" [/fl]', 'flash', 1)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'size', '<font size=\"\\\\5\">\\\\7</font>', 'Size 1', 'The [size] tag allows you to control the size of the font.', 1)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'quote', '<blockquote><smallfont>quote:</smallfont><hr>\\\\4<hr></blockquote>', '
Quote:

This is a quote
', 'The quote tag is used to denote a quote from another post', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'u', '<u>\\\\4</u>', 'Underline', 'The [u] tag allows you to underline text.', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'color', '<font color=\"\\\\5\">\\\\7</font>', 'Red!', 'The [color] tag allows you to specify the font color.', 1)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'font', '<font face=\"\\\\5\">\\\\7</font>', 'Test', 'You can change the font of your text.', 1)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'glow', '<font style=\"filter:glow(color=\\\\5\,strength=4);heigh t=1px\">\\\\7</font>','[glow=red]Glow[/glow]', 'glow', 1)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'shadow', '<font style=\"filter:shadow(color=\\\\5\,direction=225); height=1px\">\\\\7</font>','[shadow=red]Shadow[/shadow]', 'shadow', 1)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'blur', '<table style=\"filter:blur(add=0,dirction=45,strength=3)\ ">\\\\4</table>', '[blur]Blur[/blur]', 'blur', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'hide', '<span style=\"background-color:#293952\"><font color=\"#293952\">\\\\4</span></font>', '[hide]Hide Text[/hide]', 'hide', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'web', '<iframe width=550 height=400 src=\"\\\\4\"></iframe>', '[web]http://www.hisquad.net[/web] ', 'web', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'icq', '<font size=1 color=#003366>ICQ:<a href=\"http://wwp.icq.com/scripts/search.dll?to=\\\\4\">\\\\4<img src=\"http://wwp.icq.com/scripts/online.dll?icq={param}&img=5\" border=0></a></font>', '[icq]102832316[/icq]', 'ICQ', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'waver', '<bgsound src=\"\\\\4\" loop=\"infinite\">', '[waver]http://www.hisquad.net/hoopstar/001.wav[/waver]', 'waver', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'moved', '<marquee direction=\"down\" scrollamount=\"3\">\\\\4</marquee>', '[moved] To down[/moved]', '',0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'moveup', '<marquee direction=\"up\" scrollamount=\"3\">\\\\4</marquee>', '[moveup]To Up[/moveup]', '',0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'movel', '<marquee direction=\"left\">\\\\4</marquee>', '[movel] To Left[/movel]', '',0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'mover', '<marquee direction=\"right\">\\\\4</marquee>', '[mover]To Right [/mover]', '', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'j', '<p align=\"justify\">\\\\4</p>', '[j] Justify [/j]', 'Justify', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'r', '<p align=\"right\">\\\\4</p>', '[r] Right [/r]', 'Right', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'c', '<p align=\"center\">\\\\4</p>', '[c] center[/c]', 'center', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'l', '<p align=\"left\">\\\\4</p>', '[l] Lift [/l]', 'Lift', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'sound', '<param name=\"BACKGROUNDCOLOR\" <br /><embed src=\"\\\\4\" align=\"baseline\" border=\"0\" width=\"275\" height=\"40\" type=\"audio/x-pn-realaudio-plugin\" console=\"Clip1\" controls=\"ControlPanel\" autostart=\"true\">\n<b', '[sound]http://media.islamway.com/arabic/images/quran/khayyat/001.ram[/sound]', 'sound', 0)");
$DB_site->query("INSERT INTO bbcode VALUES ( NULL, 'video', '<div align=\"center\"><embed src=\"\\\\5\" \\\\7></div> ', '[video=http://www.hisquad.net/HiSquad.mpag] width=\"400\" height=\"400\" [/video] ', 'video', 1)");


$path="./vbcode_buttons.style";
$stylefile = $path;
$styletext=readfromfile($stylefile);
@unlink($stylefile);
$stylebits=explode("|||",$styletext);
list($devnul,$styleversion)=each($stylebits);
list($devnul,$style[title])=each($stylebits);
list($devnul,$replacementset[title])=each($stylebits);
list($devnul,$templateset[title])=each($stylebits);
$style[styleid]=-1;
$style[userselect]=0;
$style[replacementsetid]=-1;
$style[templatesetid]=-1;
list($devnull,$numtemplates)=each($stylebits);
$counter=0;
while ($counter++<$numtemplates) {
list($devnull,$title)=each($stylebits);
list($devnull,$template)=each($stylebits);
if (trim($title)!="") {
$DB_site->query("DELETE FROM template WHERE title= '$title' ");
$DB_site->query("INSERT INTO template (templatesetid,title,template) VALUES ($style[templatesetid],'".addslashes($title)."','".addslashes($template) ."')");
}
}

doformfooter("Next Step =>","");

}

I tried to intall a toolbar

Thanks for checking this out!!

it seems like my newreply has been affected too

this is the error I get

Database error in vBulletin 2.3.5:

Invalid SQL: SELECT bbcodetag,bbcodereplacement,twoparams FROM bbcode
mysql error: Table 'kocontent.bbcode' doesn't exist

mysql error number: 1146

Date: Tuesday 13th of December 2005 03:21:37 AM
Script: http://rapchoice.com/forums/forums/s...&threadid=3478
Referer: http://www.rapchoice.com/forums/foru...s=&forumid=161
Repair Report: This type of error cannot be automatically repaired.

..........................
I tried to create the bbcode table and this is what I got

SQL query:

CREATE TABLE bbcode(

bbcodeid smallint( 5 ) unsigned DEFAULT '0' NOT NULL AUTO_INCREMENT ,
bbcodetag varchar( 200 ) NOT NULL ,
bbcodereplacement varchar( 200 ) NOT NULL ,
bbcodeexample varchar( 200 ) NOT NULL ,
bbcodeexplanation mediumtext NOT NULL ,
twoparams smallint( 6 ) DEFAULT '0' NOT NULL ,
PRIMARY KEY ( bbcodeid )
)

MySQL said:

#1067 - Invalid default value for 'bbcodeid'
------------
What default value will work for this?

-------------
CREATE TABLE bbcode (
bbcodeid smallint(5) unsigned DEFAULT '0' NOT NULL auto_increment,
bbcodetag varchar(200) NOT NULL,
bbcodereplacement varchar(200) NOT NULL,
bbcodeexample varchar(200) NOT NULL,
bbcodeexplanation mediumtext NOT NULL,
twoparams smallint(6) DEFAULT '0' NOT NULL,
PRIMARY KEY (bbcodeid)
)
----------------

from the orginal installation I found this ^^ query


All times are GMT. The time now is 03:27 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.01133 seconds
  • Memory Usage 1,744KB
  • 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_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete