vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Bigger edit boxes by default in Admin CP scripts? (https://vborg.vbsupport.ru/showthread.php?t=175788)

styleforum 04-11-2008 01:17 AM

Bigger edit boxes by default in Admin CP scripts?
 
I find it annoying that all the edit boxes start out tiny when I go to edit things in the Admin CP. I can increase the size (with the 'Increase Size' Javascript link), but the next time I use the same thing, they are small again.

Is there any way to change all those places that the "increase size" appears so that the box stretches to fit the frame by default? Looking at code in a 50 char wide by 12 row box is ridiculous.

Thanks.

Lynne 04-11-2008 02:14 AM

Sure you can, but you have to actually edit the file. For instance, in the faq page, you will find this code for the textarea:
PHP Code:

 print_textarea_row($vbphrase['text'], 'deftext'$faqphrase["$defaultlang"]['text'], 10'70" style="width:100%'); 

If you look at the function print_textarea_row (in adminfunctions.php), you will see that the 10 is the number of rows and the 70 is the number of columns. So, you can change the 70 to something larger, like 150 or so.

MikQuattro 05-07-2008 03:11 PM

Is there a solution for v3.7? I've tried changing the values in the adminfunction.php file with no effect. I just want to make the textarea larger by default when I'm editing templates. :)

Lynne 05-07-2008 03:20 PM

I only gave one example from the adminfunction.php file. There are several places you would need to change that line depending on whilh textarea you want to make larger. Every textarea is called from a separate line.

MikQuattro 05-07-2008 04:17 PM

Thanks for the speedy reply...:)

That bit of code you posted isn't even in the adminfunctions.php file, the only thing close is this:
PHP Code:

function print_textarea_row($title$name$value ''$rows 4$cols 40$htmlise true$doeditbutton true$direction ''$textareaclass false

That's why I assumed that the code had changed for v3.7. I tried editing that, with no effect. I also looked for similar code in adminfunctions_template.php file as well as others, but I'm having a hard time tracking down the values I need.

All I'm trying to do is make the default size of the textarea in the template editor larger. I'm assuming that is going to be one piece of code because whenever you open a template to edit, it's always the same, regardless of the template.

When you do a View Source of the page, you get this for the textarea:
Code:

<div id="ctrl_template"><textarea name="template" id="ta_template_2" class="code" rows="22" cols="75" style="width:100%" wrap="virtual" dir="ltr" tabindex="1">
The problem is, I've search in loads of files for "ctrl_template", "template", "ta_template_2", etc, and I haven't come up with anything.

Anyway, sorry for the confusion, I hope that explains it a bit better.......TBH, I think I confused myself even more.....LOL

Lynne 05-07-2008 06:00 PM

I just reread what I originally wrote. When I wrote about the adminfuction.php file, I was telling the user to take a look at the *function* in that file to see the parameters. The line I quoted is found in whatever page is calling the textarea which you will have to determine by whichever textarea you are trying to change the size of.


All times are GMT. The time now is 05:05 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.01127 seconds
  • Memory Usage 1,724KB
  • 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
  • (2)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (6)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