[ Index ] |
PHP Cross Reference of MyBB |
[Summary view] [Print] [Text view]
1 <?php 2 /** 3 * MyBB 1.6 4 * Copyright 2010 MyBB Group, All Rights Reserved 5 * 6 * Website: http://mybb.com 7 * License: http://mybb.com/about/license 8 * 9 * $Id$ 10 */ 11 12 $tables[] = "CREATE TABLE mybb_adminlog ( 13 uid int unsigned NOT NULL default '0', 14 ipaddress varchar(50) NOT NULL default '', 15 dateline bigint(30) NOT NULL default '0', 16 module varchar(50) NOT NULL default '', 17 action varchar(50) NOT NULL default '', 18 data text NOT NULL, 19 KEY module (module, action) 20 ) ENGINE=MyISAM;"; 21 22 $tables[] = "CREATE TABLE mybb_adminoptions ( 23 uid int NOT NULL default '0', 24 cpstyle varchar(50) NOT NULL default '', 25 codepress int(1) NOT NULL default '1', 26 notes text NOT NULL, 27 permissions text NOT NULL, 28 defaultviews text NOT NULL, 29 loginattempts int unsigned NOT NULL default '0', 30 loginlockoutexpiry int unsigned NOT NULL default '0', 31 PRIMARY KEY (uid) 32 ) ENGINE=MyISAM;"; 33 34 $tables[] = "CREATE TABLE mybb_adminsessions ( 35 sid varchar(32) NOT NULL default '', 36 uid int unsigned NOT NULL default '0', 37 loginkey varchar(50) NOT NULL default '', 38 ip varchar(40) NOT NULL default '', 39 dateline bigint(30) NOT NULL default '0', 40 lastactive bigint(30) NOT NULL default '0', 41 data TEXT NOT NULL 42 ) ENGINE=MyISAM;"; 43 44 $tables[] = "CREATE TABLE mybb_adminviews ( 45 vid int unsigned NOT NULL auto_increment, 46 uid int unsigned NOT NULL default '0', 47 title varchar(100) NOT NULL default '', 48 type varchar(6) NOT NULL default '', 49 visibility int(1) NOT NULL default '0', 50 `fields` text NOT NULL, 51 conditions text NOT NULL, 52 custom_profile_fields text NOT NULL, 53 sortby varchar(20) NOT NULL default '', 54 sortorder varchar(4) NOT NULL default '', 55 perpage int(4) NOT NULL default '0', 56 view_type varchar(6) NOT NULL default '', 57 PRIMARY KEY(vid) 58 ) ENGINE=MyISAM;"; 59 60 $tables[] = "CREATE TABLE mybb_announcements ( 61 aid int unsigned NOT NULL auto_increment, 62 fid int(10) NOT NULL default '0', 63 uid int unsigned NOT NULL default '0', 64 subject varchar(120) NOT NULL default '', 65 message text NOT NULL, 66 startdate bigint(30) NOT NULL default '0', 67 enddate bigint(30) NOT NULL default '0', 68 allowhtml int(1) NOT NULL default '0', 69 allowmycode int(1) NOT NULL default '0', 70 allowsmilies int(1) NOT NULL default '0', 71 KEY fid (fid), 72 PRIMARY KEY (aid) 73 ) ENGINE=MyISAM;"; 74 75 $tables[] = "CREATE TABLE mybb_attachments ( 76 aid int unsigned NOT NULL auto_increment, 77 pid int(10) NOT NULL default '0', 78 posthash varchar(50) NOT NULL default '', 79 uid int unsigned NOT NULL default '0', 80 filename varchar(120) NOT NULL default '', 81 filetype varchar(120) NOT NULL default '', 82 filesize int(10) NOT NULL default '0', 83 attachname varchar(120) NOT NULL default '', 84 downloads int unsigned NOT NULL default '0', 85 dateuploaded bigint(30) NOT NULL default '0', 86 visible int(1) NOT NULL default '0', 87 thumbnail varchar(120) NOT NULL default '', 88 KEY posthash (posthash), 89 KEY pid (pid, visible), 90 KEY uid (uid), 91 PRIMARY KEY (aid) 92 ) ENGINE=MyISAM;"; 93 94 $tables[] = "CREATE TABLE mybb_attachtypes ( 95 atid int unsigned NOT NULL auto_increment, 96 name varchar(120) NOT NULL default '', 97 mimetype varchar(120) NOT NULL default '', 98 extension varchar(10) NOT NULL default '', 99 maxsize int(15) NOT NULL default '0', 100 icon varchar(100) NOT NULL default '', 101 PRIMARY KEY (atid) 102 ) ENGINE=MyISAM;"; 103 104 $tables[] = "CREATE TABLE mybb_awaitingactivation ( 105 aid int unsigned NOT NULL auto_increment, 106 uid int unsigned NOT NULL default '0', 107 dateline bigint(30) NOT NULL default '0', 108 code varchar(100) NOT NULL default '', 109 type char(1) NOT NULL default '', 110 oldgroup bigint(30) NOT NULL default '0', 111 misc varchar(255) NOT NULL default '', 112 PRIMARY KEY (aid) 113 ) ENGINE=MyISAM;"; 114 115 $tables[] = "CREATE TABLE mybb_badwords ( 116 bid int unsigned NOT NULL auto_increment, 117 badword varchar(100) NOT NULL default '', 118 replacement varchar(100) NOT NULL default '', 119 PRIMARY KEY (bid) 120 ) ENGINE=MyISAM;"; 121 122 $tables[] = "CREATE TABLE mybb_banfilters ( 123 fid int unsigned NOT NULL auto_increment, 124 filter varchar(200) NOT NULL default '', 125 type int(1) NOT NULL default '0', 126 lastuse bigint(30) NOT NULL default '0', 127 dateline bigint(30) NOT NULL default '0', 128 PRIMARY KEY (fid) 129 ) ENGINE=MyISAM;"; 130 131 $tables[] = "CREATE TABLE mybb_banned ( 132 uid int unsigned NOT NULL default '0', 133 gid int unsigned NOT NULL default '0', 134 oldgroup int unsigned NOT NULL default '0', 135 oldadditionalgroups text NOT NULL, 136 olddisplaygroup int NOT NULL default '0', 137 admin int unsigned NOT NULL default '0', 138 dateline bigint(30) NOT NULL default '0', 139 bantime varchar(50) NOT NULL default '', 140 lifted bigint(30) NOT NULL default '0', 141 reason varchar(255) NOT NULL default '', 142 KEY uid (uid), 143 KEY dateline (dateline) 144 ) ENGINE=MyISAM;"; 145 146 $tables[] = "CREATE TABLE mybb_calendars ( 147 cid int unsigned NOT NULL auto_increment, 148 name varchar(100) NOT NULL default '', 149 disporder int unsigned NOT NULL default '0', 150 startofweek int(1) NOT NULL default '0', 151 showbirthdays int(1) NOT NULL default '0', 152 eventlimit int(3) NOT NULL default '0', 153 moderation int(1) NOT NULL default '0', 154 allowhtml int(1) NOT NULL default '0', 155 allowmycode int(1) NOT NULL default '0', 156 allowimgcode int(1) NOT NULL default '0', 157 allowvideocode int(1) NOT NULL default '0', 158 allowsmilies int(1) NOT NULL default '0', 159 PRIMARY KEY(cid) 160 ) ENGINE=MyISAM;"; 161 162 $tables[] = "CREATE TABLE mybb_calendarpermissions ( 163 cid int unsigned NOT NULL default '0', 164 gid int unsigned NOT NULL default '0', 165 canviewcalendar int(1) NOT NULL default '0', 166 canaddevents int(1) NOT NULL default '0', 167 canbypasseventmod int(1) NOT NULL default '0', 168 canmoderateevents int(1) NOT NULL default '0' 169 ) ENGINE=MyISAM;"; 170 171 $tables[] = "CREATE TABLE mybb_captcha ( 172 imagehash varchar(32) NOT NULL default '', 173 imagestring varchar(8) NOT NULL default '', 174 dateline bigint(30) NOT NULL default '0', 175 KEY imagehash (imagehash), 176 KEY dateline (dateline) 177 ) ENGINE=MyISAM;"; 178 179 $tables[] = "CREATE TABLE mybb_datacache ( 180 title varchar(50) NOT NULL default '', 181 cache mediumtext NOT NULL, 182 PRIMARY KEY(title) 183 ) ENGINE=MyISAM;"; 184 185 $tables[] = "CREATE TABLE mybb_delayedmoderation ( 186 did int unsigned NOT NULL auto_increment, 187 type varchar(30) NOT NULL default '', 188 delaydateline bigint(30) NOT NULL default '0', 189 uid int(10) unsigned NOT NULL default '0', 190 fid smallint(5) unsigned NOT NULL default '0', 191 tids text NOT NULL, 192 dateline bigint(30) NOT NULL default '0', 193 inputs text NOT NULL, 194 PRIMARY KEY (did) 195 ) ENGINE=MyISAM;"; 196 197 $tables[] = "CREATE TABLE mybb_events ( 198 eid int unsigned NOT NULL auto_increment, 199 cid int unsigned NOT NULL default '0', 200 uid int unsigned NOT NULL default '0', 201 name varchar(120) NOT NULL default '', 202 description text NOT NULL, 203 visible int(1) NOT NULL default '0', 204 private int(1) NOT NULL default '0', 205 dateline int(10) unsigned NOT NULL default '0', 206 starttime int(10) unsigned NOT NULL default '0', 207 endtime int(10) unsigned NOT NULL default '0', 208 timezone varchar(4) NOT NULL default '0', 209 ignoretimezone int(1) NOT NULL default '0', 210 usingtime int(1) NOT NULL default '0', 211 repeats text NOT NULL, 212 KEY daterange (starttime, endtime), 213 KEY private (private), 214 PRIMARY KEY (eid) 215 ) ENGINE=MyISAM;"; 216 217 $tables[] = "CREATE TABLE mybb_forumpermissions ( 218 pid int unsigned NOT NULL auto_increment, 219 fid int unsigned NOT NULL default '0', 220 gid int unsigned NOT NULL default '0', 221 canview int(1) NOT NULL default '0', 222 canviewthreads int(1) NOT NULL default '0', 223 canonlyviewownthreads int(1) NOT NULL default '0', 224 candlattachments int(1) NOT NULL default '0', 225 canpostthreads int(1) NOT NULL default '0', 226 canpostreplys int(1) NOT NULL default '0', 227 canpostattachments int(1) NOT NULL default '0', 228 canratethreads int(1) NOT NULL default '0', 229 caneditposts int(1) NOT NULL default '0', 230 candeleteposts int(1) NOT NULL default '0', 231 candeletethreads int(1) NOT NULL default '0', 232 caneditattachments int(1) NOT NULL default '0', 233 canpostpolls int(1) NOT NULL default '0', 234 canvotepolls int(1) NOT NULL default '0', 235 cansearch int(1) NOT NULL default '0', 236 PRIMARY KEY (pid) 237 ) ENGINE=MyISAM;"; 238 239 $tables[] = "CREATE TABLE mybb_forums ( 240 fid smallint unsigned NOT NULL auto_increment, 241 name varchar(120) NOT NULL default '', 242 description text NOT NULL, 243 linkto varchar(180) NOT NULL default '', 244 type char(1) NOT NULL default '', 245 pid smallint unsigned NOT NULL default '0', 246 parentlist text NOT NULL, 247 disporder smallint unsigned NOT NULL default '0', 248 active int(1) NOT NULL default '0', 249 open int(1) NOT NULL default '0', 250 threads int unsigned NOT NULL default '0', 251 posts int unsigned NOT NULL default '0', 252 lastpost int(10) unsigned NOT NULL default '0', 253 lastposter varchar(120) NOT NULL default '', 254 lastposteruid int(10) unsigned NOT NULL default '0', 255 lastposttid int(10) NOT NULL default '0', 256 lastpostsubject varchar(120) NOT NULL default '', 257 allowhtml int(1) NOT NULL default '0', 258 allowmycode int(1) NOT NULL default '0', 259 allowsmilies int(1) NOT NULL default '0', 260 allowimgcode int(1) NOT NULL default '0', 261 allowvideocode int(1) NOT NULL default '0', 262 allowpicons int(1) NOT NULL default '0', 263 allowtratings int(1) NOT NULL default '0', 264 status int(4) NOT NULL default '1', 265 usepostcounts int(1) NOT NULL default '0', 266 password varchar(50) NOT NULL default '', 267 showinjump int(1) NOT NULL default '0', 268 modposts int(1) NOT NULL default '0', 269 modthreads int(1) NOT NULL default '0', 270 mod_edit_posts int(1) NOT NULL default '0', 271 modattachments int(1) NOT NULL default '0', 272 style smallint unsigned NOT NULL default '0', 273 overridestyle int(1) NOT NULL default '0', 274 rulestype smallint(1) NOT NULL default '0', 275 rulestitle varchar(200) NOT NULL default '', 276 rules text NOT NULL, 277 unapprovedthreads int(10) unsigned NOT NULL default '0', 278 unapprovedposts int(10) unsigned NOT NULL default '0', 279 defaultdatecut smallint(4) unsigned NOT NULL default '0', 280 defaultsortby varchar(10) NOT NULL default '', 281 defaultsortorder varchar(4) NOT NULL default '', 282 PRIMARY KEY (fid) 283 ) ENGINE=MyISAM;"; 284 285 $tables[] = "CREATE TABLE mybb_forumsread ( 286 fid int unsigned NOT NULL default '0', 287 uid int unsigned NOT NULL default '0', 288 dateline int(10) NOT NULL default '0', 289 KEY dateline (dateline), 290 UNIQUE KEY fid (fid,uid) 291 ) ENGINE=MyISAM;"; 292 293 294 $tables[] = "CREATE TABLE mybb_forumsubscriptions ( 295 fsid int unsigned NOT NULL auto_increment, 296 fid smallint unsigned NOT NULL default '0', 297 uid int unsigned NOT NULL default '0', 298 PRIMARY KEY (fsid) 299 ) ENGINE=MyISAM;"; 300 301 $tables[] = "CREATE TABLE mybb_groupleaders ( 302 lid smallint unsigned NOT NULL auto_increment, 303 gid smallint unsigned NOT NULL default '0', 304 uid int unsigned NOT NULL default '0', 305 canmanagemembers int(1) NOT NULL default '0', 306 canmanagerequests int(1) NOT NULL default '0', 307 PRIMARY KEY (lid) 308 ) ENGINE=MyISAM;"; 309 310 $tables[] = "CREATE TABLE mybb_helpdocs ( 311 hid smallint unsigned NOT NULL auto_increment, 312 sid smallint unsigned NOT NULL default '0', 313 name varchar(120) NOT NULL default '', 314 description text NOT NULL, 315 document text NOT NULL, 316 usetranslation int(1) NOT NULL default '0', 317 enabled int(1) NOT NULL default '0', 318 disporder smallint unsigned NOT NULL default '0', 319 PRIMARY KEY (hid) 320 ) ENGINE=MyISAM;"; 321 322 323 $tables[] = "CREATE TABLE mybb_helpsections ( 324 sid smallint unsigned NOT NULL auto_increment, 325 name varchar(120) NOT NULL default '', 326 description text NOT NULL, 327 usetranslation int(1) NOT NULL default '0', 328 enabled int(1) NOT NULL default '0', 329 disporder smallint unsigned NOT NULL default '0', 330 PRIMARY KEY (sid) 331 ) ENGINE=MyISAM;"; 332 333 334 $tables[] = "CREATE TABLE mybb_icons ( 335 iid smallint unsigned NOT NULL auto_increment, 336 name varchar(120) NOT NULL default '', 337 path varchar(220) NOT NULL default '', 338 PRIMARY KEY (iid) 339 ) ENGINE=MyISAM;"; 340 341 342 $tables[] = "CREATE TABLE mybb_joinrequests ( 343 rid int unsigned NOT NULL auto_increment, 344 uid int unsigned NOT NULL default '0', 345 gid smallint unsigned NOT NULL default '0', 346 reason varchar(250) NOT NULL default '', 347 dateline bigint(30) NOT NULL default '0', 348 PRIMARY KEY (rid) 349 ) ENGINE=MyISAM;"; 350 351 $tables[] = "CREATE TABLE mybb_massemails ( 352 mid int unsigned NOT NULL auto_increment, 353 uid int unsigned NOT NULL default '0', 354 subject varchar(200) NOT NULL default '', 355 message text NOT NULL, 356 htmlmessage text NOT NULL, 357 type tinyint(1) NOT NULL default '0', 358 format tinyint(1) NOT NULL default '0', 359 dateline bigint(30) NOT NULL default '0', 360 senddate bigint(30) NOT NULL default '0', 361 status tinyint(1) NOT NULL default '0', 362 sentcount int unsigned NOT NULL default '0', 363 totalcount int unsigned NOT NULL default '0', 364 conditions text NOT NULL, 365 perpage smallint(4) NOT NULL default '50', 366 PRIMARY KEY(mid) 367 ) ENGINE=MyISAM;"; 368 369 $tables[] = "CREATE TABLE mybb_mailerrors ( 370 eid int unsigned NOT NULL auto_increment, 371 subject varchar(200) NOT NULL default '', 372 message text NOT NULL, 373 toaddress varchar(150) NOT NULL default '', 374 fromaddress varchar(150) NOT NULL default '', 375 dateline bigint(30) NOT NULL default '0', 376 error text NOT NULL, 377 smtperror varchar(200) NOT NULL default '', 378 smtpcode int(5) NOT NULL default '0', 379 PRIMARY KEY (eid) 380 ) ENGINE=MyISAM;"; 381 382 $tables[] = "CREATE TABLE mybb_maillogs ( 383 mid int unsigned NOT NULL auto_increment, 384 subject varchar(200) not null default '', 385 message text NOT NULL, 386 dateline bigint(30) NOT NULL default '0', 387 fromuid int unsigned NOT NULL default '0', 388 fromemail varchar(200) not null default '', 389 touid bigint(30) NOT NULL default '0', 390 toemail varchar(200) NOT NULL default '', 391 tid int unsigned NOT NULL default '0', 392 ipaddress varchar(20) NOT NULL default '', 393 PRIMARY KEY (mid) 394 ) ENGINE=MyISAM;"; 395 396 $tables[] = "CREATE TABLE mybb_mailqueue ( 397 mid int unsigned NOT NULL auto_increment, 398 mailto varchar(200) NOT NULL, 399 mailfrom varchar(200) NOT NULL, 400 subject varchar(200) NOT NULL, 401 message text NOT NULL, 402 headers text NOT NULL, 403 PRIMARY KEY (mid) 404 ) ENGINE=MyISAM;"; 405 406 $tables[] = "CREATE TABLE mybb_moderatorlog ( 407 uid int unsigned NOT NULL default '0', 408 dateline bigint(30) NOT NULL default '0', 409 fid smallint unsigned NOT NULL default '0', 410 tid int unsigned NOT NULL default '0', 411 pid int unsigned NOT NULL default '0', 412 action text NOT NULL, 413 data text NOT NULL, 414 ipaddress varchar(50) NOT NULL default '', 415 KEY tid (tid) 416 ) ENGINE=MyISAM;"; 417 418 $tables[] = "CREATE TABLE mybb_moderators ( 419 mid smallint unsigned NOT NULL auto_increment, 420 fid smallint unsigned NOT NULL default '0', 421 id int unsigned NOT NULL default '0', 422 isgroup int(1) unsigned NOT NULL default '0', 423 caneditposts int(1) NOT NULL default '0', 424 candeleteposts int(1) NOT NULL default '0', 425 canviewips int(1) NOT NULL default '0', 426 canopenclosethreads int(1) NOT NULL default '0', 427 canmanagethreads int(1) NOT NULL default '0', 428 canmovetononmodforum int(1) NOT NULL default '0', 429 canusecustomtools int(1) NOT NULL default '0', 430 KEY uid (id, fid), 431 PRIMARY KEY (mid) 432 ) ENGINE=MyISAM;"; 433 434 $tables[] = "CREATE TABLE mybb_modtools ( 435 tid smallint unsigned NOT NULL auto_increment, 436 name varchar(200) NOT NULL, 437 description text NOT NULL, 438 forums text NOT NULL, 439 type char(1) NOT NULL default '', 440 postoptions text NOT NULL, 441 threadoptions text NOT NULL, 442 PRIMARY KEY (tid) 443 ) ENGINE=MyISAM;"; 444 445 $tables[] = "CREATE TABLE mybb_mycode ( 446 cid int unsigned NOT NULL auto_increment, 447 title varchar(100) NOT NULL default '', 448 description text NOT NULL, 449 regex text NOT NULL, 450 replacement text NOT NULL, 451 active int(1) NOT NULL default '0', 452 parseorder smallint unsigned NOT NULL default '0', 453 PRIMARY KEY(cid) 454 ) ENGINE=MyISAM;"; 455 456 $tables[] = "CREATE TABLE mybb_polls ( 457 pid int unsigned NOT NULL auto_increment, 458 tid int unsigned NOT NULL default '0', 459 question varchar(200) NOT NULL default '', 460 dateline bigint(30) NOT NULL default '0', 461 options text NOT NULL, 462 votes text NOT NULL, 463 numoptions smallint unsigned NOT NULL default '0', 464 numvotes text NOT NULL, 465 timeout bigint(30) NOT NULL default '0', 466 closed int(1) NOT NULL default '0', 467 multiple int(1) NOT NULL default '0', 468 public int(1) NOT NULL default '0', 469 PRIMARY KEY (pid) 470 ) ENGINE=MyISAM;"; 471 472 $tables[] = "CREATE TABLE mybb_pollvotes ( 473 vid int unsigned NOT NULL auto_increment, 474 pid int unsigned NOT NULL default '0', 475 uid int unsigned NOT NULL default '0', 476 voteoption smallint unsigned NOT NULL default '0', 477 dateline bigint(30) NOT NULL default '0', 478 KEY pid (pid, uid), 479 PRIMARY KEY (vid) 480 ) ENGINE=MyISAM;"; 481 482 $tables[] = "CREATE TABLE mybb_posts ( 483 pid int unsigned NOT NULL auto_increment, 484 tid int unsigned NOT NULL default '0', 485 replyto int unsigned NOT NULL default '0', 486 fid smallint unsigned NOT NULL default '0', 487 subject varchar(120) NOT NULL default '', 488 icon smallint unsigned NOT NULL default '0', 489 uid int unsigned NOT NULL default '0', 490 username varchar(80) NOT NULL default '', 491 dateline bigint(30) NOT NULL default '0', 492 message text NOT NULL, 493 ipaddress varchar(30) NOT NULL default '', 494 longipaddress int(11) NOT NULL default '0', 495 includesig int(1) NOT NULL default '0', 496 smilieoff int(1) NOT NULL default '0', 497 edituid int unsigned NOT NULL default '0', 498 edittime int(10) NOT NULL default '0', 499 visible int(1) NOT NULL default '0', 500 posthash varchar(32) NOT NULL default '', 501 KEY tid (tid, uid), 502 KEY uid (uid), 503 KEY visible (visible), 504 KEY dateline (dateline), 505 KEY longipaddress (longipaddress), 506 PRIMARY KEY (pid) 507 ) ENGINE=MyISAM;"; 508 509 510 $tables[] = "CREATE TABLE mybb_privatemessages ( 511 pmid int unsigned NOT NULL auto_increment, 512 uid int unsigned NOT NULL default '0', 513 toid int unsigned NOT NULL default '0', 514 fromid int unsigned NOT NULL default '0', 515 recipients text NOT NULL, 516 folder smallint unsigned NOT NULL default '1', 517 subject varchar(120) NOT NULL default '', 518 icon smallint unsigned NOT NULL default '0', 519 message text NOT NULL, 520 dateline bigint(30) NOT NULL default '0', 521 deletetime bigint(30) NOT NULL default '0', 522 status int(1) NOT NULL default '0', 523 statustime bigint(30) NOT NULL default '0', 524 includesig int(1) NOT NULL default '0', 525 smilieoff int(1) NOT NULL default '0', 526 receipt int(1) NOT NULL default '0', 527 readtime bigint(30) NOT NULL default '0', 528 KEY uid (uid, folder), 529 KEY toid (toid), 530 PRIMARY KEY (pmid) 531 ) ENGINE=MyISAM;"; 532 533 534 $tables[] = "CREATE TABLE mybb_profilefields ( 535 fid smallint unsigned NOT NULL auto_increment, 536 name varchar(100) NOT NULL default '', 537 description text NOT NULL, 538 disporder smallint unsigned NOT NULL default '0', 539 type text NOT NULL, 540 length smallint unsigned NOT NULL default '0', 541 maxlength smallint unsigned NOT NULL default '0', 542 required int(1) NOT NULL default '0', 543 editable int(1) NOT NULL default '0', 544 hidden int(1) NOT NULL default '0', 545 postnum bigint(30) NOT NULL default '0', 546 PRIMARY KEY (fid) 547 ) ENGINE=MyISAM;"; 548 549 550 $tables[] = "CREATE TABLE mybb_promotions ( 551 pid int unsigned NOT NULL auto_increment, 552 title varchar(120) NOT NULL default '', 553 description text NOT NULL, 554 enabled tinyint(1) NOT NULL default '1', 555 logging tinyint(1) NOT NULL default '0', 556 posts int NOT NULL default '0', 557 posttype char(2) NOT NULL default '', 558 registered int NOT NULL default '0', 559 registeredtype varchar(20) NOT NULL default '', 560 reputations int NOT NULL default '0', 561 reputationtype char(2) NOT NULL default '', 562 referrals int NOT NULL default '0', 563 referralstype char(2) NOT NULL default '', 564 requirements varchar(200) NOT NULL default '', 565 originalusergroup varchar(120) NOT NULL default '0', 566 newusergroup smallint unsigned NOT NULL default '0', 567 usergrouptype varchar(120) NOT NULL default '0', 568 PRIMARY KEY (pid) 569 ) ENGINE=MyISAM;"; 570 571 $tables[] = "CREATE TABLE mybb_promotionlogs ( 572 plid int unsigned NOT NULL auto_increment, 573 pid int unsigned NOT NULL default '0', 574 uid int unsigned NOT NULL default '0', 575 oldusergroup varchar(200) NOT NULL default '0', 576 newusergroup smallint NOT NULL default '0', 577 dateline bigint(30) NOT NULL default '0', 578 type varchar(9) NOT NULL default 'primary', 579 PRIMARY KEY(plid) 580 ) ENGINE=MyISAM;"; 581 582 $tables[] = "CREATE TABLE mybb_reportedposts ( 583 rid int unsigned NOT NULL auto_increment, 584 pid int unsigned NOT NULL default '0', 585 tid int unsigned NOT NULL default '0', 586 fid int unsigned NOT NULL default '0', 587 uid int unsigned NOT NULL default '0', 588 reportstatus int(1) NOT NULL default '0', 589 reason varchar(250) NOT NULL default '', 590 dateline bigint(30) NOT NULL default '0', 591 KEY fid (fid), 592 KEY dateline (dateline), 593 PRIMARY KEY (rid) 594 ) ENGINE=MyISAM;"; 595 596 $tables[] = "CREATE TABLE mybb_reputation ( 597 rid int unsigned NOT NULL auto_increment, 598 uid int unsigned NOT NULL default '0', 599 adduid int unsigned NOT NULL default '0', 600 pid int unsigned NOT NULL default '0', 601 reputation bigint(30) NOT NULL default '0', 602 dateline bigint(30) NOT NULL default '0', 603 comments text NOT NULL, 604 KEY uid (uid), 605 KEY pid (pid), 606 KEY dateline (dateline), 607 PRIMARY KEY (rid) 608 ) ENGINE=MyISAM;"; 609 610 $tables[] = "CREATE TABLE mybb_searchlog ( 611 sid varchar(32) NOT NULL default '', 612 uid int unsigned NOT NULL default '0', 613 dateline bigint(30) NOT NULL default '0', 614 ipaddress varchar(120) NOT NULL default '', 615 threads longtext NOT NULL, 616 posts longtext NOT NULL, 617 resulttype varchar(10) NOT NULL default '', 618 querycache text NOT NULL, 619 keywords text NOT NULL, 620 PRIMARY KEY (sid) 621 ) ENGINE=MyISAM;"; 622 623 $tables[] = "CREATE TABLE mybb_sessions ( 624 sid varchar(32) NOT NULL default '', 625 uid int unsigned NOT NULL default '0', 626 ip varchar(40) NOT NULL default '', 627 time bigint(30) NOT NULL default '0', 628 location varchar(150) NOT NULL default '', 629 useragent varchar(100) NOT NULL default '', 630 anonymous int(1) NOT NULL default '0', 631 nopermission int(1) NOT NULL default '0', 632 location1 int(10) NOT NULL default '0', 633 location2 int(10) NOT NULL default '0', 634 PRIMARY KEY(sid), 635 KEY location1 (location1), 636 KEY location2 (location2), 637 KEY time (time), 638 KEY uid (uid), 639 KEY ip (ip) 640 ) ENGINE=MyISAM;"; 641 642 $tables[] = "CREATE TABLE mybb_settinggroups ( 643 gid smallint unsigned NOT NULL auto_increment, 644 name varchar(100) NOT NULL default '', 645 title varchar(220) NOT NULL default '', 646 description text NOT NULL, 647 disporder smallint unsigned NOT NULL default '0', 648 isdefault int(1) NOT NULL default '0', 649 PRIMARY KEY (gid) 650 ) ENGINE=MyISAM;"; 651 652 653 $tables[] = "CREATE TABLE mybb_settings ( 654 sid smallint unsigned NOT NULL auto_increment, 655 name varchar(120) NOT NULL default '', 656 title varchar(120) NOT NULL default '', 657 description text NOT NULL, 658 optionscode text NOT NULL, 659 value text NOT NULL, 660 disporder smallint unsigned NOT NULL default '0', 661 gid smallint unsigned NOT NULL default '0', 662 isdefault int(1) NOT NULL default '0', 663 PRIMARY KEY (sid) 664 ) ENGINE=MyISAM;"; 665 666 667 $tables[] = "CREATE TABLE mybb_smilies ( 668 sid smallint unsigned NOT NULL auto_increment, 669 name varchar(120) NOT NULL default '', 670 find varchar(120) NOT NULL default '', 671 image varchar(220) NOT NULL default '', 672 disporder smallint unsigned NOT NULL default '0', 673 showclickable int(1) NOT NULL default '0', 674 PRIMARY KEY (sid) 675 ) ENGINE=MyISAM;"; 676 677 $tables[] = "CREATE TABLE mybb_spiders ( 678 sid int unsigned NOT NULL auto_increment, 679 name varchar(100) NOT NULL default '', 680 theme int unsigned NOT NULL default '0', 681 language varchar(20) NOT NULL default '', 682 usergroup int unsigned NOT NULL default '0', 683 useragent varchar(200) NOT NULL default '', 684 lastvisit bigint(30) NOT NULL default '0', 685 PRIMARY KEY (sid) 686 ) ENGINE=MyISAM;"; 687 688 $tables[] = "CREATE TABLE mybb_stats ( 689 dateline bigint(30) NOT NULL default '0', 690 numusers int unsigned NOT NULL default '0', 691 numthreads int unsigned NOT NULL default '0', 692 numposts int unsigned NOT NULL default '0', 693 PRIMARY KEY(dateline) 694 ) ENGINE=MyISAM;"; 695 696 $tables[] = "CREATE TABLE mybb_tasks ( 697 tid int unsigned NOT NULL auto_increment, 698 title varchar(120) NOT NULL default '', 699 description text NOT NULL, 700 file varchar(30) NOT NULL default '', 701 minute varchar(200) NOT NULL default '', 702 hour varchar(200) NOT NULL default '', 703 day varchar(100) NOT NULL default '', 704 month varchar(30) NOT NULL default '', 705 weekday varchar(15) NOT NULL default '', 706 nextrun bigint(30) NOT NULL default '0', 707 lastrun bigint(30) NOT NULL default '0', 708 enabled int(1) NOT NULL default '1', 709 logging int(1) NOT NULL default '0', 710 locked bigint(30) NOT NULL default '0', 711 PRIMARY KEY (tid) 712 ) ENGINE=MyISAM;"; 713 714 $tables[] = "CREATE TABLE mybb_tasklog ( 715 lid int unsigned NOT NULL auto_increment, 716 tid int unsigned NOT NULL default '0', 717 dateline bigint(30) NOT NULL default '0', 718 data text NOT NULL, 719 PRIMARY KEY (lid) 720 ) ENGINE=MyISAM;"; 721 722 $tables[] = "CREATE TABLE mybb_templategroups ( 723 gid int unsigned NOT NULL auto_increment, 724 prefix varchar(50) NOT NULL default '', 725 title varchar(100) NOT NULL default '', 726 PRIMARY KEY (gid) 727 ) ENGINE=MyISAM;"; 728 729 $tables[] = "CREATE TABLE mybb_templates ( 730 tid int unsigned NOT NULL auto_increment, 731 title varchar(120) NOT NULL default '', 732 template text NOT NULL, 733 sid int(10) NOT NULL default '0', 734 version varchar(20) NOT NULL default '0', 735 status varchar(10) NOT NULL default '', 736 dateline int(10) NOT NULL default '0', 737 PRIMARY KEY (tid) 738 ) ENGINE=MyISAM;"; 739 740 $tables[] = "CREATE TABLE mybb_templatesets ( 741 sid smallint unsigned NOT NULL auto_increment, 742 title varchar(120) NOT NULL default '', 743 PRIMARY KEY (sid) 744 ) ENGINE=MyISAM;"; 745 746 747 $tables[] = "CREATE TABLE mybb_themes ( 748 tid smallint unsigned NOT NULL auto_increment, 749 name varchar(100) NOT NULL default '', 750 pid smallint unsigned NOT NULL default '0', 751 def smallint(1) NOT NULL default '0', 752 properties text NOT NULL, 753 stylesheets text NOT NULL, 754 allowedgroups text NOT NULL, 755 PRIMARY KEY (tid) 756 ) ENGINE=MyISAM;"; 757 758 $tables[] = "CREATE TABLE mybb_themestylesheets( 759 sid int unsigned NOT NULL auto_increment, 760 name varchar(30) NOT NULL default '', 761 tid int unsigned NOT NULL default '0', 762 attachedto text NOT NULL, 763 stylesheet text NOT NULL, 764 cachefile varchar(100) NOT NULL default '', 765 lastmodified bigint(30) NOT NULL default '0', 766 PRIMARY KEY(sid) 767 ) ENGINE=MyISAM;"; 768 769 $tables[] = "CREATE TABLE mybb_threadprefixes ( 770 pid int unsigned NOT NULL auto_increment, 771 prefix varchar(120) NOT NULL default '', 772 displaystyle varchar(200) NOT NULL default '', 773 forums text NOT NULL, 774 groups text NOT NULL, 775 PRIMARY KEY(pid) 776 ) ENGINE=MyISAM;"; 777 778 $tables[] = "CREATE TABLE mybb_threadratings ( 779 rid int unsigned NOT NULL auto_increment, 780 tid int unsigned NOT NULL default '0', 781 uid int unsigned NOT NULL default '0', 782 rating smallint unsigned NOT NULL default '0', 783 ipaddress varchar(30) NOT NULL default '', 784 KEY tid (tid, uid), 785 PRIMARY KEY (rid) 786 ) ENGINE=MyISAM;"; 787 788 $tables[] = "CREATE TABLE mybb_threadviews ( 789 tid int unsigned NOT NULL default '0', 790 KEY (tid) 791 ) ENGINE=MyISAM;"; 792 793 794 $tables[] = "CREATE TABLE mybb_threads ( 795 tid int unsigned NOT NULL auto_increment, 796 fid smallint unsigned NOT NULL default '0', 797 subject varchar(120) NOT NULL default '', 798 prefix smallint unsigned NOT NULL default '0', 799 icon smallint unsigned NOT NULL default '0', 800 poll int unsigned NOT NULL default '0', 801 uid int unsigned NOT NULL default '0', 802 username varchar(80) NOT NULL default '', 803 dateline bigint(30) NOT NULL default '0', 804 firstpost int unsigned NOT NULL default '0', 805 lastpost bigint(30) NOT NULL default '0', 806 lastposter varchar(120) NOT NULL default '', 807 lastposteruid int unsigned NOT NULL default '0', 808 views int(100) NOT NULL default '0', 809 replies int(100) NOT NULL default '0', 810 closed varchar(30) NOT NULL default '', 811 sticky int(1) NOT NULL default '0', 812 numratings smallint unsigned NOT NULL default '0', 813 totalratings smallint unsigned NOT NULL default '0', 814 notes text NOT NULL, 815 visible int(1) NOT NULL default '0', 816 unapprovedposts int(10) unsigned NOT NULL default '0', 817 attachmentcount int(10) unsigned NOT NULL default '0', 818 deletetime int(10) unsigned NOT NULL default '0', 819 KEY fid (fid, visible, sticky), 820 KEY dateline (dateline), 821 KEY lastpost (lastpost, fid), 822 KEY firstpost (firstpost), 823 KEY uid (uid), 824 PRIMARY KEY (tid) 825 ) ENGINE=MyISAM;"; 826 827 $tables[] = "CREATE TABLE mybb_threadsread ( 828 tid int unsigned NOT NULL default '0', 829 uid int unsigned NOT NULL default '0', 830 dateline int(10) NOT NULL default '0', 831 KEY dateline (dateline), 832 UNIQUE KEY tid (tid,uid) 833 ) ENGINE=MyISAM;"; 834 835 $tables[] = "CREATE TABLE mybb_threadsubscriptions ( 836 sid int unsigned NOT NULL auto_increment, 837 uid int unsigned NOT NULL default '0', 838 tid int unsigned NOT NULL default '0', 839 notification int(1) NOT NULL default '0', 840 dateline bigint(30) NOT NULL default '0', 841 subscriptionkey varchar(32) NOT NULL default '', 842 KEY uid (uid), 843 KEY tid (tid,notification), 844 PRIMARY KEY (sid) 845 ) ENGINE=MyISAM;"; 846 847 $tables[] = "CREATE TABLE mybb_userfields ( 848 ufid int unsigned NOT NULL default '0', 849 fid1 text NOT NULL, 850 fid2 text NOT NULL, 851 fid3 text NOT NULL, 852 PRIMARY KEY (ufid) 853 ) ENGINE=MyISAM;"; 854 855 $tables[] = "CREATE TABLE mybb_usergroups ( 856 gid smallint unsigned NOT NULL auto_increment, 857 type smallint(2) NOT NULL default '2', 858 title varchar(120) NOT NULL default '', 859 description text NOT NULL, 860 namestyle varchar(200) NOT NULL default '{username}', 861 usertitle varchar(120) NOT NULL default '', 862 stars smallint(4) NOT NULL default '0', 863 starimage varchar(120) NOT NULL default '', 864 image varchar(120) NOT NULL default '', 865 disporder smallint(6) unsigned NOT NULL, 866 isbannedgroup int(1) NOT NULL default '0', 867 canview int(1) NOT NULL default '0', 868 canviewthreads int(1) NOT NULL default '0', 869 canviewprofiles int(1) NOT NULL default '0', 870 candlattachments int(1) NOT NULL default '0', 871 canpostthreads int(1) NOT NULL default '0', 872 canpostreplys int(1) NOT NULL default '0', 873 canpostattachments int(1) NOT NULL default '0', 874 canratethreads int(1) NOT NULL default '0', 875 caneditposts int(1) NOT NULL default '0', 876 candeleteposts int(1) NOT NULL default '0', 877 candeletethreads int(1) NOT NULL default '0', 878 caneditattachments int(1) NOT NULL default '0', 879 canpostpolls int(1) NOT NULL default '0', 880 canvotepolls int(1) NOT NULL default '0', 881 canundovotes int(1) NOT NULL default '0', 882 canusepms int(1) NOT NULL default '0', 883 cansendpms int(1) NOT NULL default '0', 884 cantrackpms int(1) NOT NULL default '0', 885 candenypmreceipts int(1) NOT NULL default '0', 886 pmquota int(3) NOT NULL default '0', 887 maxpmrecipients int(4) NOT NULL default '5', 888 cansendemail int(1) NOT NULL default '0', 889 cansendemailoverride int(1) NOT NULL default '0', 890 maxemails int(3) NOT NULL default '5', 891 canviewmemberlist int(1) NOT NULL default '0', 892 canviewcalendar int(1) NOT NULL default '0', 893 canaddevents int(1) NOT NULL default '0', 894 canbypasseventmod int(1) NOT NULL default '0', 895 canmoderateevents int(1) NOT NULL default '0', 896 canviewonline int(1) NOT NULL default '0', 897 canviewwolinvis int(1) NOT NULL default '0', 898 canviewonlineips int(1) NOT NULL default '0', 899 cancp int(1) NOT NULL default '0', 900 issupermod int(1) NOT NULL default '0', 901 cansearch int(1) NOT NULL default '0', 902 canusercp int(1) NOT NULL default '0', 903 canuploadavatars int(1) NOT NULL default '0', 904 canratemembers int(1) NOT NULL default '0', 905 canchangename int(1) NOT NULL default '0', 906 showforumteam int(1) NOT NULL default '0', 907 usereputationsystem int(1) NOT NULL default '0', 908 cangivereputations int(1) NOT NULL default '0', 909 reputationpower bigint(30) NOT NULL default '0', 910 maxreputationsday bigint(30) NOT NULL default '0', 911 maxreputationsperuser bigint(30) NOT NULL default '0', 912 maxreputationsperthread bigint(30) NOT NULL default '0', 913 candisplaygroup int(1) NOT NULL default '0', 914 attachquota bigint(30) NOT NULL default '0', 915 cancustomtitle int(1) NOT NULL default '0', 916 canwarnusers int(1) NOT NULL default '0', 917 canreceivewarnings int(1) NOT NULL default '0', 918 maxwarningsday int(3) NOT NULL default '3', 919 canmodcp int(1) NOT NULL default '0', 920 showinbirthdaylist int(1) NOT NULL default '0', 921 canoverridepm int(1) NOT NULL default '0', 922 canusesig int(1) NOT NULL default '0', 923 canusesigxposts bigint(30) NOT NULL default '0', 924 signofollow int(1) NOT NULL default '0', 925 PRIMARY KEY (gid) 926 ) ENGINE=MyISAM;"; 927 928 929 $tables[] = "CREATE TABLE mybb_users ( 930 uid int unsigned NOT NULL auto_increment, 931 username varchar(120) NOT NULL default '', 932 password varchar(120) NOT NULL default '', 933 salt varchar(10) NOT NULL default '', 934 loginkey varchar(50) NOT NULL default '', 935 email varchar(220) NOT NULL default '', 936 postnum int(10) NOT NULL default '0', 937 avatar varchar(200) NOT NULL default '', 938 avatardimensions varchar(10) NOT NULL default '', 939 avatartype varchar(10) NOT NULL default '0', 940 usergroup smallint unsigned NOT NULL default '0', 941 additionalgroups varchar(200) NOT NULL default '', 942 displaygroup smallint unsigned NOT NULL default '0', 943 usertitle varchar(250) NOT NULL default '', 944 regdate bigint(30) NOT NULL default '0', 945 lastactive bigint(30) NOT NULL default '0', 946 lastvisit bigint(30) NOT NULL default '0', 947 lastpost bigint(30) NOT NULL default '0', 948 website varchar(200) NOT NULL default '', 949 icq varchar(10) NOT NULL default '', 950 aim varchar(50) NOT NULL default '', 951 yahoo varchar(50) NOT NULL default '', 952 msn varchar(75) NOT NULL default '', 953 birthday varchar(15) NOT NULL default '', 954 birthdayprivacy varchar(4) NOT NULL default 'all', 955 signature text NOT NULL, 956 allownotices int(1) NOT NULL default '0', 957 hideemail int(1) NOT NULL default '0', 958 subscriptionmethod int(1) NOT NULL default '0', 959 invisible int(1) NOT NULL default '0', 960 receivepms int(1) NOT NULL default '0', 961 receivefrombuddy int(1) NOT NULL default '0', 962 pmnotice int(1) NOT NULL default '0', 963 pmnotify int(1) NOT NULL default '0', 964 threadmode varchar(8) NOT NULL default '', 965 showsigs int(1) NOT NULL default '0', 966 showavatars int(1) NOT NULL default '0', 967 showquickreply int(1) NOT NULL default '0', 968 showredirect int(1) NOT NULL default '0', 969 ppp smallint(6) NOT NULL default '0', 970 tpp smallint(6) NOT NULL default '0', 971 daysprune smallint(6) NOT NULL default '0', 972 dateformat varchar(4) NOT NULL default '', 973 timeformat varchar(4) NOT NULL default '', 974 timezone varchar(4) NOT NULL default '', 975 dst int(1) NOT NULL default '0', 976 dstcorrection int(1) NOT NULL default '0', 977 buddylist text NOT NULL, 978 ignorelist text NOT NULL, 979 style smallint unsigned NOT NULL default '0', 980 away int(1) NOT NULL default '0', 981 awaydate int(10) unsigned NOT NULL default '0', 982 returndate varchar(15) NOT NULL default '', 983 awayreason varchar(200) NOT NULL default '', 984 pmfolders text NOT NULL, 985 notepad text NOT NULL, 986 referrer int unsigned NOT NULL default '0', 987 referrals int unsigned NOT NULL default '0', 988 reputation bigint(30) NOT NULL default '0', 989 regip varchar(50) NOT NULL default '', 990 lastip varchar(50) NOT NULL default '', 991 longregip int(11) NOT NULL default '0', 992 longlastip int(11) NOT NULL default '0', 993 language varchar(50) NOT NULL default '', 994 timeonline bigint(30) NOT NULL default '0', 995 showcodebuttons int(1) NOT NULL default '1', 996 totalpms int(10) NOT NULL default '0', 997 unreadpms int(10) NOT NULL default '0', 998 warningpoints int(3) NOT NULL default '0', 999 moderateposts int(1) NOT NULL default '0', 1000 moderationtime bigint(30) NOT NULL default '0', 1001 suspendposting int(1) NOT NULL default '0', 1002 suspensiontime bigint(30) NOT NULL default '0', 1003 suspendsignature int(1) NOT NULL default '0', 1004 suspendsigtime bigint(30) NOT NULL default '0', 1005 coppauser int(1) NOT NULL default '0', 1006 classicpostbit int(1) NOT NULL default '0', 1007 loginattempts tinyint(2) NOT NULL default '1', 1008 usernotes text NOT NULL, 1009 UNIQUE KEY username (username), 1010 KEY usergroup (usergroup), 1011 KEY birthday (birthday), 1012 KEY longregip (longregip), 1013 KEY longlastip (longlastip), 1014 PRIMARY KEY (uid) 1015 ) ENGINE=MyISAM;"; 1016 1017 $tables[] = "CREATE TABLE mybb_usertitles ( 1018 utid smallint unsigned NOT NULL auto_increment, 1019 posts int unsigned NOT NULL default '0', 1020 title varchar(250) NOT NULL default '', 1021 stars smallint(4) NOT NULL default '0', 1022 starimage varchar(120) NOT NULL default '', 1023 PRIMARY KEY (utid) 1024 ) ENGINE=MyISAM;"; 1025 1026 $tables[] = "CREATE TABLE mybb_warninglevels ( 1027 lid int unsigned NOT NULL auto_increment, 1028 percentage int(3) NOT NULL default '0', 1029 action text NOT NULL, 1030 PRIMARY KEY (lid) 1031 ) ENGINE=MyISAM;"; 1032 1033 $tables[] = "CREATE TABLE mybb_warningtypes ( 1034 tid int unsigned NOT NULL auto_increment, 1035 title varchar(120) NOT NULL default '', 1036 points int unsigned NOT NULL default '0', 1037 expirationtime bigint(30) NOT NULL default '0', 1038 PRIMARY KEY (tid) 1039 ) ENGINE=MyISAM;"; 1040 1041 $tables[] = "CREATE TABLE mybb_warnings ( 1042 wid int unsigned NOT NULL auto_increment, 1043 uid int unsigned NOT NULL default '0', 1044 tid int unsigned NOT NULL default '0', 1045 pid int unsigned NOT NULL default '0', 1046 title varchar(120) NOT NULL default '', 1047 points int unsigned NOT NULL default '0', 1048 dateline bigint(30) NOT NULL default '0', 1049 issuedby int unsigned NOT NULL default '0', 1050 expires bigint(30) NOT NULL default '0', 1051 expired int(1) NOT NULL default '0', 1052 daterevoked bigint(30) NOT NULL default '0', 1053 revokedby int unsigned NOT NULL default '0', 1054 revokereason text NOT NULL, 1055 notes text NOT NULL, 1056 PRIMARY KEY (wid) 1057 ) ENGINE=MyISAM;"; 1058 1059 ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Tue Oct 8 19:19:50 2013 | Cross-referenced by PHPXref 0.7.1 |