vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin Tips & Tricks (https://vborg.vbsupport.ru/forumdisplay.php?f=239)
-   -   Editing Your config.php File (https://vborg.vbsupport.ru/showthread.php?t=308457)

ozzy47 02-16-2014 11:00 PM

Editing Your config.php File
 
Sometimes as administrators, it is necessary to make changes to your includes/config.php file.

As a new administrator, or one that has never had to do this, it can be a bit scary, as you don't want to blow up your site. Or you may have edited it, and can not access your site.

So before you do this, you should do the following, to ensure you will not mess up the file.

First thing is to not use a editor such as notepad, or wordpad to edit the file, you need to use at a mininum, notepad ++, you can download it for free here, notepad-plus-plus

Why should I not use notepad or wordpad?
If you use wordpad or notepad in windows, edit the file then upload it to a server (which is more than likely Linux) it can sometimes insert hidden characters, this is what's known as UTF-8 BOM, its just how the program tries to read the file and when the hidden windows characters are inserted it causes issue because Linux is not Windows and vice-versa.

Now you should protect yourself by doing the following:
1) Download the includes/config.php file, and save it somewhere on your computer.
2) Download the includes/config.php file again, and open it in your editor, and make any changes.
3) Re-upload the edited file.

Whooops, I did not follow the above instructions, now I got errors like this, Warning: Cannot modify header information - headers already sent by (output started at [path]/includes/config.php:1) in [path]/includes/functions.php on line 4370 and I can not access my site!

1) Re-download the same exact version of vBulletin you are running from the members area, then extract the .zip locally to your pc.
2) Rename the includes/config.php.new file to includes/config.php
3) Now open up your original config.php file that is on your server, and the new one you just downloaded with your text editor, ( not notepad or wordpad )
4) Copy/paste any relevant info from the original file to the new file, such as database name, database username, and database password. If you see anything else that looks different copy that too such as technical email address etc
5) Now upload the newly edited file to your server, overwriting the old one.

As you can see, it is much easier to protect yourself with a backup copy, rather than re editing the entire thing.

CAG CheechDogg 02-17-2014 02:39 AM

Great little tutorial ozzy, thank you for putting this up my Man! I can't even remember how many times I edited files using notepad or wordpad then uploaded files and I was in a rut! ....

ozzy47 02-17-2014 02:50 AM

No problem, hopefully people will read it before diving in to things. :)

CAG CheechDogg 02-17-2014 03:07 AM

You know what would really help out, well me at least ozzy? If you could probably give more detailed explanation of what each of those settings in the config file do. There are a couple that I still don't know what they are for exactly....I know there are descriptions there already, but they are a bit confusing ...

ozzy47 02-17-2014 03:11 AM

I guess the generic answer would be, "If you don't know what they do, don't adjust them"

Which ones are you having trouble with? I may not know but someone might.

CAG CheechDogg 02-17-2014 03:22 AM

I will have to take a look ...lol...but yes..If I don't know what they do I leave them alone

ForceHSS 02-17-2014 03:28 AM

Ozzy many will understand like myself, but for the ones that don't understand you should make it easier for those

CAG CheechDogg 02-17-2014 03:28 AM

OK this one for instance:

// ****** UNDELETABLE / UNALTERABLE USERS ******
// The users specified here will not be deletable or alterable from the control panel by any users.
// To specify more than one user, separate userids with commas.
$config['SpecialUsers']['undeletableusers'] = 'user id separated by comman';

I added myself to this one, but even as an admin I can't edit my own profile? I don't get it ....

ozzy47 02-17-2014 03:29 AM

How could it be any simpler?

CAG CheechDogg 02-17-2014 03:31 AM

Quote:

Originally Posted by ForceHSS (Post 2481699)
Ozzy many will understand like myself, but for the ones that don't you should make it simple

I understand most of it and most of them, but some are a little confusing, like the one above. That means If I add my user id there and I don't want to risk any other admin from altering it and if I have to edit or alter it myself, I have to go back and change this every time ....sucks ! lol..


All times are GMT. The time now is 06:55 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01277 seconds
  • Memory Usage 1,737KB
  • 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_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete