vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Easy question: Staffrank - sql query (https://vborg.vbsupport.ru/showthread.php?t=81766)

Ala21 05-20-2005 12:26 PM

Easy question: Staffrank - sql query
 
Hello,

i installed the staff rank hack, though it looks like it is limiting the characters allowed in the field so this is a problem if I am using html code and want to format the text.
I am not a SQL expert but I think it's because of this query:

ALTER TABLE user ADD (
staffrank varchar(100) not null default ''
)


How do I edit it to increase the maximum characters allowed? IF it's that limiting the characters, but i'd guess so.

Thank you :)

jugo 05-20-2005 12:42 PM

I don't think it's that cause that has a character limit of 100.

Check the template and see what the form has set as the character limit. and change it there.

Ala21 05-20-2005 12:47 PM

Hello jugo thanks for your help

These are the instructions for the hack installation, can you tell me exactly where I should look? Thank you :)

Code:

====================================
Run this query
====================================
+---------------------+

ALTER TABLE user ADD (
        staffrank varchar(100) not null default ''
)

+---------------------+

====================================
open admincp/user.php Find:
====================================
+---------------------+

        print_select_row($vbphrase['language'] , 'user[languageid]', array('0' => $vbphrase['use_forum_default']) + fetch_language_titles_array('', 0), $user['languageid']);

+---------------------+

====================================
Add Under:
====================================
+---------------------+

        print_input_row($vbphrase['staff_title'], 'user[staffrank]', $user['staffrank']);

+---------------------+

====================================
Add Phrase:
====================================
+---------------------+
Phrase Type: Global
Varname: staff_title
Text: Staff Title
+---------------------+

====================================
In your postbit or postbit_legacy Add where you want to show your staff title:
====================================
+---------------------+
$post[staffrank]
+---------------------+

All Done :)

Or anyone else? :)

Fixed. As i thought it was the VARCHAR limiting to 100, i set it to 250 and now everything works like it should :)
Thanks for the help

Logikos 05-20-2005 05:17 PM

Yes it would only allow 100 as the query sets the limit, you would just have to go into phpmyadmin and change it to what ever you would like it to be.


All times are GMT. The time now is 07:40 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
  • Page Generation 0.01294 seconds
  • Memory Usage 1,717KB
  • 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
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)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