![]() |
Req: User decides post direction
Users continue to request the ability to choose which direction the forum threads are displayed, forward or reverse.
No matter what direction I set it in the control panel, I end up only pleasing half the group. Could someone please create a hack to add this feature? Perhaps as an option in the user control panel? Thanks! |
Easiest way:
Create a new user profile field editable by user and ask your users to enter "1" if they want normal order and "0" if they want reverse. (If you want you can hack register.php and member.php to show this profile field as a "radio button" or "check box") Then edit showthread.php, find: PHP Code:
PHP Code:
That's it.. :) |
Thanks I'll give that a try, and let you know how it turns out.
I was wondering though, what if the user hasn't filled out the new field, and it's simply blank? Will showthread choke on the empty field? |
Quote:
|
.
|
Okay, good news, VB came to its senses and realized the extra column wasn't there.
Lets leave the database alone if we can. Any other suggestions? |
If you want a user selectable option, how can u leave db alone? You have to save the user's selection somewhere in your database. You would consider adding a new field to user table if you didnt apply my solution and it would require much more hacking since you need to form a interface for your users to populate this field. Adding a new profile field just saves you from this trouble.
Bottom line is, you can not have such a hack without touching your db. |
.
|
.
|
1- Creating a new user profile field is done inside Admin CP. I hope you first this method in the first place? It would be very unnecessary to use PhPmyadmin to add a new profile field.
If you created the field via Admin CP, I doubt it would give you this problem. It should not be server intensive to create a new user profile field even if your db is large. 2- Messing with db with PhpMyadmin is not recommended unless you know what you are doing. But if you are intended a new profile field has 2 traces in your db. Its name and options are recorded in "profilefield" table where one new column is also added to "userfield" table. Deleting its record from profilefield and deleting the column from userfield, should solve the problem IF IT IS RELATED to profile fields. (BACKUP DB!) But as I said before I doubt it, it might be another db problem you are having at the moment.. |
Quote:
|
I should use VB's repair.php in the admin directory?
Quote:
|
What repair do you mean?
|
Quote:
|
Thanks, I found it, and did, but it was of little help.
I got the same error when running it. There seems to have been a slight problem with the Tundra Solutions database. Please try again by pressing the refresh button in your browser. An E-Mail has been dispatched to our Technical Staff, who you can also contact if the problem persists. We apologise for any inconvenience. Quote:
|
.
|
Any way to close the forum, without logging into the control panel? I'm getting hundreds of email notices.
|
Try running the following query via phpMyAdmin:
[sql]REPAIR TABLE `user`[/sql] |
I tried to repair both user and userfield, but no luck.
vbulletin.user repair error 28 when writing to datafile vbulletin.userfield repair error 28 when writing to datafile Quote:
|
I'm in the process of uploading the restore file. A 200 MB upload will take a while.
|
Okay can someone help me restore the database?
I tried doing it using phpMyAdmin but got this error: SQL-query : CREATE DATABASE `forum` MySQL said: Can't create database 'forum'. (errno: 28) what's error no. 28? |
I ran out of disk space on the MySQL partition. But I corrected it, and repaired two tables, so everything is working well again.
|
All times are GMT. The time now is 03:39 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|