Config Edit Window Size too small (Vertically)

Hello!

I have Asterisk v1.4.13 and FreePBX v2.3.1 installed and have run into a problem trying to edit configuration files from within FreePBX. For the record, I am using the newly released NerdVittles PBX-In-A-Flash ISO package.

The “edit window” presented to me on the screen only displays 2 lines of text on the screen. This is not enough room for me to edit the files, so I am going outside FreePBX to utilize an editor.

I have tried to edit the files from within FreePBX using the “Tools”, “Config Edit” option with Firefox and IE v7 (I know it’s not supported, but thought I’d try). Both produce identical two line text displays of the config file I am trying to edit.

Any ideas on how to increase the size of this edit window so that going out to the command line in my environment would no longer be necessary?

Thanks for any help and your attention!

Tim

Hi

The config edit window is unique to PiaF - not FreePBX - look in /var/www/html/admin/modules/configedit/ and one of the files shows the iframe size which you can change.

Joe

this is not a FreePBX module (and for good reason). If you need to edit a file, you should use a proper editor and terminal access to the server. You can use your own ssh client or the javassh provided by FreePBX.

The use of tools like config edit lead to problems with novice users especially that they present configuration files that should never be edited and novice users are not aware of these restrictions. Experienced users typically have no issues using an editor to access configuration files and can further benefit from smart editors that color code Asterisk and other configuration files (such as vim) as well as aid in other syntax related requirements in config files.

Philippe Lindheimer - FreePBX Project Lead
http//freepbx.org - IRC #freepbx

Thank you for the advice and the information. I am definitely a newbie and fall in the category of “novice user” as you describe!! I understand it’s not a good idea to use this tool to edit the .conf files, but I only use it on _custom.conf files due to it’s convenience within FreePBX. Just for my own education, you indicated this feature/function is not a part of FreePBX… is it a part of NerdVittles additions or elsewhere? Just trying to learn as I move along…

Using the information you provided, I found that the httpd error’s log is showing an undefined variable for this particular variable ($textarea_rows). I then commented out the line causing the error in “/var/www/html/maint/configedit/phpconfig.php”, and inserted a line setting the value of $textarea_rows to “24”.

This appears to have solved the problem and there is now sufficient room within the “Confieg Edit” window in FreePBX to allow for editing. After doing a little more research, it appears the underlying cause may be in the variable/constant assignment/declaration area of the file "/var/www/html/maint/configedit/cls_phpconfig_html.php ".

This appears to be where the value of “$textarea_rows” is being set.

I am not knowledgeable enough to say if this is a bug or not, but did want to document it here.

Thanks to everyone for thier help and patience with my naivete as I continue to learn!

Tim

I’ve never looked at the code for that, but it is very possible that it was ‘badly written’ to expect you php.ini file to have ‘register_globals=on’ set. You may want to try that. If that fixes it, I would consider it a bug to the owner of that module as it should not be necessary to have that set to on (although, unfortunately there are a lot of other web apps that expect it to be on as well).

Philippe Lindheimer - FreePBX Project Lead
http//freepbx.org - IRC #freepbx