config.rst.txt 114 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624
  1. .. index:: config.inc.php
  2. .. _config:
  3. Configuration
  4. =============
  5. All configurable data is placed in :file:`config.inc.php` in phpMyAdmin's
  6. toplevel directory. If this file does not exist, please refer to the
  7. :ref:`setup` section to create one. This file only needs to contain the
  8. parameters you want to change from their corresponding default value in
  9. :file:`libraries/config.default.php` (this file is not inteded for changes).
  10. .. seealso::
  11. :ref:`config-examples` for examples of configurations
  12. If a directive is missing from your file, you can just add another line with
  13. the file. This file is for over-writing the defaults; if you wish to use the
  14. default value there's no need to add a line here.
  15. The parameters which relate to design (like colors) are placed in
  16. :file:`themes/themename/layout.inc.php`. You might also want to create
  17. :file:`config.footer.inc.php` and :file:`config.header.inc.php` files to add
  18. your site specific code to be included on start and end of each page.
  19. .. note::
  20. Some distributions (eg. Debian or Ubuntu) store :file:`config.inc.php` in
  21. ``/etc/phpmyadmin`` instead of within phpMyAdmin sources.
  22. .. warning::
  23. :term:`Mac` users should note that if you are on a version before
  24. :term:`Mac OS X`, PHP does not seem to
  25. like :term:`Mac` end of lines character (``\r``). So
  26. ensure you choose the option that allows to use the \*nix end of line
  27. character (``\n``) in your text editor before saving a script you have
  28. modified.
  29. Basic settings
  30. --------------
  31. .. config:option:: $cfg['PmaAbsoluteUri']
  32. :type: string
  33. :default: ``''``
  34. .. versionchanged:: 4.6.5
  35. This setting was not available in phpMyAdmin 4.6.0 - 4.6.4.
  36. Sets here the complete :term:`URL` (with full path) to your phpMyAdmin
  37. installation's directory. E.g.
  38. ``https://www.example.net/path_to_your_phpMyAdmin_directory/``. Note also
  39. that the :term:`URL` on most of web servers are case sensitive (even on
  40. Windows). Don’t forget the trailing slash at the end.
  41. Starting with version 2.3.0, it is advisable to try leaving this blank. In
  42. most cases phpMyAdmin automatically detects the proper setting. Users of
  43. port forwarding or complex reverse proxy setup might need to set this.
  44. A good test is to browse a table, edit a row and save it. There should be
  45. an error message if phpMyAdmin is having trouble auto–detecting the correct
  46. value. If you get an error that this must be set or if the autodetect code
  47. fails to detect your path, please post a bug report on our bug tracker so
  48. we can improve the code.
  49. .. seealso:: :ref:`faq1_40`, :ref:`faq2_5`, :ref:`faq4_7`, :ref:`faq5_16`
  50. .. config:option:: $cfg['PmaNoRelation_DisableWarning']
  51. :type: boolean
  52. :default: false
  53. Starting with version 2.3.0 phpMyAdmin offers a lot of features to
  54. work with master / foreign – tables (see :config:option:`$cfg['Servers'][$i]['pmadb']`).
  55. If you tried to set this
  56. up and it does not work for you, have a look on the :guilabel:`Structure` page
  57. of one database where you would like to use it. You will find a link
  58. that will analyze why those features have been disabled.
  59. If you do not want to use those features set this variable to ``true`` to
  60. stop this message from appearing.
  61. .. config:option:: $cfg['AuthLog']
  62. :type: string
  63. :default: ``'auto'``
  64. .. versionadded:: 4.8.0
  65. This is supported since phpMyAdmin 4.8.0.
  66. Configure authentication logging destination. Failed (or all, depending on
  67. :config:option:`$cfg['AuthLogSuccess']`) authentication attempts will be
  68. logged according to this directive:
  69. ``auto``
  70. Let phpMyAdmin automatically choose between ``syslog`` and ``php``.
  71. ``syslog``
  72. Log using syslog, using AUTH facility, on most systems this ends up
  73. in :file:`/var/log/auth.log`.
  74. ``php``
  75. Log into PHP error log.
  76. ``sapi``
  77. Log into PHP SAPI logging.
  78. ``/path/to/file``
  79. Any other value is treated as a filename and log entries are written there.
  80. .. note::
  81. When logging to a file, make sure its permissions are correctly set
  82. for a web server user, the setup should closely match instructions
  83. described in :config:option:`$cfg['TempDir']`:
  84. .. config:option:: $cfg['AuthLogSuccess']
  85. :type: boolean
  86. :default: false
  87. .. versionadded:: 4.8.0
  88. This is supported since phpMyAdmin 4.8.0.
  89. Whether to log successful authentication attempts into
  90. :config:option:`$cfg['AuthLog']`.
  91. .. config:option:: $cfg['SuhosinDisableWarning']
  92. :type: boolean
  93. :default: false
  94. A warning is displayed on the main page if Suhosin is detected.
  95. You can set this parameter to ``true`` to stop this message from appearing.
  96. .. config:option:: $cfg['LoginCookieValidityDisableWarning']
  97. :type: boolean
  98. :default: false
  99. A warning is displayed on the main page if the PHP parameter
  100. session.gc_maxlifetime is lower than cookie validity configured in phpMyAdmin.
  101. You can set this parameter to ``true`` to stop this message from appearing.
  102. .. config:option:: $cfg['ServerLibraryDifference_DisableWarning']
  103. :type: boolean
  104. :default: false
  105. .. deprecated:: 4.7.0
  106. This setting was removed as the warning has been removed as well.
  107. A warning is displayed on the main page if there is a difference
  108. between the MySQL library and server version.
  109. You can set this parameter to ``true`` to stop this message from appearing.
  110. .. config:option:: $cfg['ReservedWordDisableWarning']
  111. :type: boolean
  112. :default: false
  113. This warning is displayed on the Structure page of a table if one or more
  114. column names match with words which are MySQL reserved.
  115. If you want to turn off this warning, you can set it to ``true`` and
  116. warning will no longer be displayed.
  117. .. config:option:: $cfg['TranslationWarningThreshold']
  118. :type: integer
  119. :default: 80
  120. Show warning about incomplete translations on certain threshold.
  121. .. config:option:: $cfg['SendErrorReports']
  122. :type: string
  123. :default: ``'ask'``
  124. Sets the default behavior for JavaScript error reporting.
  125. Whenever an error is detected in the JavaScript execution, an error report
  126. may be sent to the phpMyAdmin team if the user agrees.
  127. The default setting of ``'ask'`` will ask the user everytime there is a new
  128. error report. However you can set this parameter to ``'always'`` to send error
  129. reports without asking for confirmation or you can set it to ``'never'`` to
  130. never send error reports.
  131. This directive is available both in the configuration file and in users
  132. preferences. If the person in charge of a multi-user installation prefers
  133. to disable this feature for all users, a value of ``'never'`` should be
  134. set, and the :config:option:`$cfg['UserprefsDisallow']` directive should
  135. contain ``'SendErrorReports'`` in one of its array values.
  136. .. config:option:: $cfg['ConsoleEnterExecutes']
  137. :type: boolean
  138. :default: false
  139. Setting this to ``true`` allows the user to execute queries by pressing Enter
  140. instead of Ctrl+Enter. A new line can be inserted by pressing Shift + Enter.
  141. The behaviour of the console can be temporarily changed using console's
  142. settings interface.
  143. .. config:option:: $cfg['AllowThirdPartyFraming']
  144. :type: boolean
  145. :default: false
  146. Setting this to ``true`` allows phpMyAdmin to be included inside a frame,
  147. and is a potential security hole allowing cross-frame scripting attacks or
  148. clickjacking.
  149. Server connection settings
  150. --------------------------
  151. .. config:option:: $cfg['Servers']
  152. :type: array
  153. :default: one server array with settings listed below
  154. Since version 1.4.2, phpMyAdmin supports the administration of multiple
  155. MySQL servers. Therefore, a :config:option:`$cfg['Servers']`-array has been
  156. added which contains the login information for the different servers. The
  157. first :config:option:`$cfg['Servers'][$i]['host']` contains the hostname of
  158. the first server, the second :config:option:`$cfg['Servers'][$i]['host']`
  159. the hostname of the second server, etc. In
  160. :file:`libraries/config.default.php`, there is only one section for server
  161. definition, however you can put as many as you need in
  162. :file:`config.inc.php`, copy that block or needed parts (you don't have to
  163. define all settings, just those you need to change).
  164. .. note::
  165. The :config:option:`$cfg['Servers']` array starts with
  166. $cfg['Servers'][1]. Do not use $cfg['Servers'][0]. If you want more
  167. than one server, just copy following section (including $i
  168. incrementation) serveral times. There is no need to define full server
  169. array, just define values you need to change.
  170. .. config:option:: $cfg['Servers'][$i]['host']
  171. :type: string
  172. :default: ``'localhost'``
  173. The hostname or :term:`IP` address of your $i-th MySQL-server. E.g.
  174. ``localhost``.
  175. Possible values are:
  176. * hostname, e.g., ``'localhost'`` or ``'mydb.example.org'``
  177. * IP address, e.g., ``'127.0.0.1'`` or ``'192.168.10.1'``
  178. * IPv6 address, e.g. ``2001:cdba:0000:0000:0000:0000:3257:9652``
  179. * dot - ``'.'``, i.e., use named pipes on windows systems
  180. * empty - ``''``, disables this server
  181. .. note::
  182. The hostname ``localhost`` is handled specially by MySQL and it uses
  183. the socket based connection protocol. To use TCP/IP networking, use an
  184. IP address or hostname such as ``127.0.0.1`` or ``db.example.com``. You
  185. can configure the path to the socket with
  186. :config:option:`$cfg['Servers'][$i]['socket']`.
  187. .. seealso::
  188. :config:option:`$cfg['Servers'][$i]['port']`,
  189. <https://dev.mysql.com/doc/refman/5.7/en/connecting.html>
  190. .. config:option:: $cfg['Servers'][$i]['port']
  191. :type: string
  192. :default: ``''``
  193. The port-number of your $i-th MySQL-server. Default is 3306 (leave
  194. blank).
  195. .. note::
  196. If you use ``localhost`` as the hostname, MySQL ignores this port number
  197. and connects with the socket, so if you want to connect to a port
  198. different from the default port, use ``127.0.0.1`` or the real hostname
  199. in :config:option:`$cfg['Servers'][$i]['host']`.
  200. .. seealso::
  201. :config:option:`$cfg['Servers'][$i]['host']`,
  202. <https://dev.mysql.com/doc/refman/5.7/en/connecting.html>
  203. .. config:option:: $cfg['Servers'][$i]['socket']
  204. :type: string
  205. :default: ``''``
  206. The path to the socket to use. Leave blank for default. To determine
  207. the correct socket, check your MySQL configuration or, using the
  208. :command:`mysql` command–line client, issue the ``status`` command. Among the
  209. resulting information displayed will be the socket used.
  210. .. note::
  211. This takes effect only if :config:option:`$cfg['Servers'][$i]['host']` is set
  212. to ``localhost``.
  213. .. seealso::
  214. :config:option:`$cfg['Servers'][$i]['host']`,
  215. <https://dev.mysql.com/doc/refman/5.7/en/connecting.html>
  216. .. config:option:: $cfg['Servers'][$i]['ssl']
  217. :type: boolean
  218. :default: false
  219. Whether to enable SSL for the connection between phpMyAdmin and the MySQL
  220. server to secure the connection.
  221. When using the ``'mysql'`` extension,
  222. none of the remaining ``'ssl...'`` configuration options apply.
  223. We strongly recommend the ``'mysqli'`` extension when using this option.
  224. .. seealso::
  225. :ref:`ssl`,
  226. :ref:`example-google-ssl`,
  227. :config:option:`$cfg['Servers'][$i]['ssl_key']`,
  228. :config:option:`$cfg['Servers'][$i]['ssl_cert']`,
  229. :config:option:`$cfg['Servers'][$i]['ssl_ca']`,
  230. :config:option:`$cfg['Servers'][$i]['ssl_ca_path']`,
  231. :config:option:`$cfg['Servers'][$i]['ssl_ciphers']`,
  232. :config:option:`$cfg['Servers'][$i]['ssl_verify']`
  233. .. config:option:: $cfg['Servers'][$i]['ssl_key']
  234. :type: string
  235. :default: NULL
  236. Path to the client key file when using SSL for connecting to the MySQL
  237. server. This is used to authenticate the client to the server.
  238. For example:
  239. .. code-block:: php
  240. $cfg['Servers'][$i]['ssl_key'] = '/etc/mysql/server-key.pem';
  241. .. seealso::
  242. :ref:`ssl`,
  243. :ref:`example-google-ssl`,
  244. :config:option:`$cfg['Servers'][$i]['ssl']`,
  245. :config:option:`$cfg['Servers'][$i]['ssl_cert']`,
  246. :config:option:`$cfg['Servers'][$i]['ssl_ca']`,
  247. :config:option:`$cfg['Servers'][$i]['ssl_ca_path']`,
  248. :config:option:`$cfg['Servers'][$i]['ssl_ciphers']`,
  249. :config:option:`$cfg['Servers'][$i]['ssl_verify']`
  250. .. config:option:: $cfg['Servers'][$i]['ssl_cert']
  251. :type: string
  252. :default: NULL
  253. Path to the client certificate file when using SSL for connecting to the
  254. MySQL server. This is used to authenticate the client to the server.
  255. .. seealso::
  256. :ref:`ssl`,
  257. :ref:`example-google-ssl`,
  258. :config:option:`$cfg['Servers'][$i]['ssl']`,
  259. :config:option:`$cfg['Servers'][$i]['ssl_key']`,
  260. :config:option:`$cfg['Servers'][$i]['ssl_ca']`,
  261. :config:option:`$cfg['Servers'][$i]['ssl_ca_path']`,
  262. :config:option:`$cfg['Servers'][$i]['ssl_ciphers']`,
  263. :config:option:`$cfg['Servers'][$i]['ssl_verify']`
  264. .. config:option:: $cfg['Servers'][$i]['ssl_ca']
  265. :type: string
  266. :default: NULL
  267. Path to the CA file when using SSL for connecting to the MySQL server.
  268. .. seealso::
  269. :ref:`ssl`,
  270. :ref:`example-google-ssl`,
  271. :config:option:`$cfg['Servers'][$i]['ssl']`,
  272. :config:option:`$cfg['Servers'][$i]['ssl_key']`,
  273. :config:option:`$cfg['Servers'][$i]['ssl_cert']`,
  274. :config:option:`$cfg['Servers'][$i]['ssl_ca_path']`,
  275. :config:option:`$cfg['Servers'][$i]['ssl_ciphers']`,
  276. :config:option:`$cfg['Servers'][$i]['ssl_verify']`
  277. .. config:option:: $cfg['Servers'][$i]['ssl_ca_path']
  278. :type: string
  279. :default: NULL
  280. Directory containing trusted SSL CA certificates in PEM format.
  281. .. seealso::
  282. :ref:`ssl`,
  283. :ref:`example-google-ssl`,
  284. :config:option:`$cfg['Servers'][$i]['ssl']`,
  285. :config:option:`$cfg['Servers'][$i]['ssl_key']`,
  286. :config:option:`$cfg['Servers'][$i]['ssl_cert']`,
  287. :config:option:`$cfg['Servers'][$i]['ssl_ca']`,
  288. :config:option:`$cfg['Servers'][$i]['ssl_ciphers']`,
  289. :config:option:`$cfg['Servers'][$i]['ssl_verify']`
  290. .. config:option:: $cfg['Servers'][$i]['ssl_ciphers']
  291. :type: string
  292. :default: NULL
  293. List of allowable ciphers for SSL connections to the MySQL server.
  294. .. seealso::
  295. :ref:`ssl`,
  296. :ref:`example-google-ssl`,
  297. :config:option:`$cfg['Servers'][$i]['ssl']`,
  298. :config:option:`$cfg['Servers'][$i]['ssl_key']`,
  299. :config:option:`$cfg['Servers'][$i]['ssl_cert']`,
  300. :config:option:`$cfg['Servers'][$i]['ssl_ca']`,
  301. :config:option:`$cfg['Servers'][$i]['ssl_ca_path']`,
  302. :config:option:`$cfg['Servers'][$i]['ssl_verify']`
  303. .. config:option:: $cfg['Servers'][$i]['ssl_verify']
  304. :type: boolean
  305. :default: true
  306. .. versionadded:: 4.6.0
  307. This is supported since phpMyAdmin 4.6.0.
  308. If your PHP install uses the MySQL Native Driver (mysqlnd), your
  309. MySQL server is 5.6 or later, and your SSL certificate is self-signed,
  310. there is a chance your SSL connection will fail due to validation.
  311. Setting this to ``false`` will disable the validation check.
  312. Since PHP 5.6.0 it also verifies whether server name matches CN of its
  313. certificate. There is currently no way to disable just this check without
  314. disabling complete SSL verification.
  315. .. warning::
  316. Disabling the certificate verification defeats purpose of using SSL.
  317. This will make the connection vulnerable to man in the middle attacks.
  318. .. note::
  319. This flag only works with PHP 5.6.16 or later.
  320. .. seealso::
  321. :ref:`ssl`,
  322. :ref:`example-google-ssl`,
  323. :config:option:`$cfg['Servers'][$i]['ssl']`,
  324. :config:option:`$cfg['Servers'][$i]['ssl_key']`,
  325. :config:option:`$cfg['Servers'][$i]['ssl_cert']`,
  326. :config:option:`$cfg['Servers'][$i]['ssl_ca']`,
  327. :config:option:`$cfg['Servers'][$i]['ssl_ca_path']`,
  328. :config:option:`$cfg['Servers'][$i]['ssl_ciphers']`,
  329. :config:option:`$cfg['Servers'][$i]['ssl_verify']`
  330. .. config:option:: $cfg['Servers'][$i]['connect_type']
  331. :type: string
  332. :default: ``'tcp'``
  333. .. deprecated:: 4.7.0
  334. This setting is no longer used as of 4.7.0, since MySQL decides the
  335. connection type based on host, so it could lead to unexpected results.
  336. Please set :config:option:`$cfg['Servers'][$i]['host']` accordingly
  337. instead.
  338. What type connection to use with the MySQL server. Your options are
  339. ``'socket'`` and ``'tcp'``. It defaults to tcp as that is nearly guaranteed
  340. to be available on all MySQL servers, while sockets are not supported on
  341. some platforms. To use the socket mode, your MySQL server must be on the
  342. same machine as the Web server.
  343. .. config:option:: $cfg['Servers'][$i]['compress']
  344. :type: boolean
  345. :default: false
  346. Whether to use a compressed protocol for the MySQL server connection
  347. or not (experimental).
  348. .. _controlhost:
  349. .. config:option:: $cfg['Servers'][$i]['controlhost']
  350. :type: string
  351. :default: ``''``
  352. Permits to use an alternate host to hold the configuration storage
  353. data.
  354. .. seealso::
  355. :config:option:`$cfg['Servers'][$i]['control_*']`
  356. .. _controlport:
  357. .. config:option:: $cfg['Servers'][$i]['controlport']
  358. :type: string
  359. :default: ``''``
  360. Permits to use an alternate port to connect to the host that
  361. holds the configuration storage.
  362. .. seealso::
  363. :config:option:`$cfg['Servers'][$i]['control_*']`
  364. .. _controluser:
  365. .. config:option:: $cfg['Servers'][$i]['controluser']
  366. :type: string
  367. :default: ``''``
  368. .. config:option:: $cfg['Servers'][$i]['controlpass']
  369. :type: string
  370. :default: ``''``
  371. This special account is used to access :ref:`linked-tables`.
  372. You don't need it in single user case, but if phpMyAdmin is shared it
  373. is recommended to give access to :ref:`linked-tables` only to this user
  374. and configure phpMyAdmin to use it. All users will then be able to use
  375. the features without need to have direct access to :ref:`linked-tables`.
  376. .. versionchanged:: 2.2.5
  377. those were called ``stduser`` and ``stdpass``
  378. .. seealso::
  379. :ref:`setup`,
  380. :ref:`authentication_modes`,
  381. :ref:`linked-tables`,
  382. :config:option:`$cfg['Servers'][$i]['pmadb']`,
  383. :config:option:`$cfg['Servers'][$i]['controlhost']`,
  384. :config:option:`$cfg['Servers'][$i]['controlport']`,
  385. :config:option:`$cfg['Servers'][$i]['control_*']`
  386. .. config:option:: $cfg['Servers'][$i]['control_*']
  387. :type: mixed
  388. .. versionadded:: 4.7.0
  389. You can change any MySQL connection setting for control link (used to
  390. access :ref:`linked-tables`) using configuration prefixed with ``control_``.
  391. This can be used to change any aspect of the control connection, which by
  392. default uses same parameters as the user one.
  393. For example you can configure SSL for the control connection:
  394. .. code-block:: php
  395. // Enable SSL
  396. $cfg['Servers'][$i]['control_ssl'] = true;
  397. // Client secret key
  398. $cfg['Servers'][$i]['control_ssl_key'] = '../client-key.pem';
  399. // Client certificate
  400. $cfg['Servers'][$i]['control_ssl_cert'] = '../client-cert.pem';
  401. // Server certification authority
  402. $cfg['Servers'][$i]['control_ssl_ca'] = '../server-ca.pem';
  403. .. seealso::
  404. :config:option:`$cfg['Servers'][$i]['ssl']`,
  405. :config:option:`$cfg['Servers'][$i]['ssl_key']`,
  406. :config:option:`$cfg['Servers'][$i]['ssl_cert']`,
  407. :config:option:`$cfg['Servers'][$i]['ssl_ca']`,
  408. :config:option:`$cfg['Servers'][$i]['ssl_ca_path']`,
  409. :config:option:`$cfg['Servers'][$i]['ssl_ciphers']`,
  410. :config:option:`$cfg['Servers'][$i]['ssl_verify']`
  411. .. config:option:: $cfg['Servers'][$i]['auth_type']
  412. :type: string
  413. :default: ``'cookie'``
  414. Whether config or cookie or :term:`HTTP` or signon authentication should be
  415. used for this server.
  416. * 'config' authentication (``$auth_type = 'config'``) is the plain old
  417. way: username and password are stored in :file:`config.inc.php`.
  418. * 'cookie' authentication mode (``$auth_type = 'cookie'``) allows you to
  419. log in as any valid MySQL user with the help of cookies.
  420. * 'http' authentication allows you to log in as any
  421. valid MySQL user via HTTP-Auth.
  422. * 'signon' authentication mode (``$auth_type = 'signon'``) allows you to
  423. log in from prepared PHP session data or using supplied PHP script.
  424. .. seealso:: :ref:`authentication_modes`
  425. .. _servers_auth_http_realm:
  426. .. config:option:: $cfg['Servers'][$i]['auth_http_realm']
  427. :type: string
  428. :default: ``''``
  429. When using auth\_type = ``http``, this field allows to define a custom
  430. :term:`HTTP` Basic Auth Realm which will be displayed to the user. If not
  431. explicitly specified in your configuration, a string combined of
  432. "phpMyAdmin " and either :config:option:`$cfg['Servers'][$i]['verbose']` or
  433. :config:option:`$cfg['Servers'][$i]['host']` will be used.
  434. .. _servers_user:
  435. .. config:option:: $cfg['Servers'][$i]['user']
  436. :type: string
  437. :default: ``'root'``
  438. .. config:option:: $cfg['Servers'][$i]['password']
  439. :type: string
  440. :default: ``''``
  441. When using :config:option:`$cfg['Servers'][$i]['auth_type']` set to
  442. 'config', this is the user/password-pair which phpMyAdmin will use to
  443. connect to the MySQL server. This user/password pair is not needed when
  444. :term:`HTTP` or cookie authentication is used
  445. and should be empty.
  446. .. _servers_nopassword:
  447. .. config:option:: $cfg['Servers'][$i]['nopassword']
  448. :type: boolean
  449. :default: false
  450. .. deprecated:: 4.7.0
  451. This setting was removed as it can produce unexpected results.
  452. Allow attempt to log in without password when a login with password
  453. fails. This can be used together with http authentication, when
  454. authentication is done some other way and phpMyAdmin gets user name
  455. from auth and uses empty password for connecting to MySQL. Password
  456. login is still tried first, but as fallback, no password method is
  457. tried.
  458. .. _servers_only_db:
  459. .. config:option:: $cfg['Servers'][$i]['only_db']
  460. :type: string or array
  461. :default: ``''``
  462. If set to a (an array of) database name(s), only this (these)
  463. database(s) will be shown to the user. Since phpMyAdmin 2.2.1,
  464. this/these database(s) name(s) may contain MySQL wildcards characters
  465. ("\_" and "%"): if you want to use literal instances of these
  466. characters, escape them (I.E. use ``'my\_db'`` and not ``'my_db'``).
  467. This setting is an efficient way to lower the server load since the
  468. latter does not need to send MySQL requests to build the available
  469. database list. But **it does not replace the privileges rules of the
  470. MySQL database server**. If set, it just means only these databases
  471. will be displayed but **not that all other databases can't be used.**
  472. An example of using more that one database:
  473. .. code-block:: php
  474. $cfg['Servers'][$i]['only_db'] = array('db1', 'db2');
  475. .. versionchanged:: 4.0.0
  476. Previous versions permitted to specify the display order of
  477. the database names via this directive.
  478. .. config:option:: $cfg['Servers'][$i]['hide_db']
  479. :type: string
  480. :default: ``''``
  481. Regular expression for hiding some databases from unprivileged users.
  482. This only hides them from listing, but a user is still able to access
  483. them (using, for example, the SQL query area). To limit access, use
  484. the MySQL privilege system. For example, to hide all databases
  485. starting with the letter "a", use
  486. .. code-block:: php
  487. $cfg['Servers'][$i]['hide_db'] = '^a';
  488. and to hide both "db1" and "db2" use
  489. .. code-block:: php
  490. $cfg['Servers'][$i]['hide_db'] = '^(db1|db2)$';
  491. More information on regular expressions can be found in the `PCRE
  492. pattern syntax
  493. <https://www.php.net/manual/en/reference.pcre.pattern.syntax.php>`_ portion
  494. of the PHP reference manual.
  495. .. config:option:: $cfg['Servers'][$i]['verbose']
  496. :type: string
  497. :default: ``''``
  498. Only useful when using phpMyAdmin with multiple server entries. If
  499. set, this string will be displayed instead of the hostname in the
  500. pull-down menu on the main page. This can be useful if you want to
  501. show only certain databases on your system, for example. For HTTP
  502. auth, all non-US-ASCII characters will be stripped.
  503. .. config:option:: $cfg['Servers'][$i]['extension']
  504. :type: string
  505. :default: ``'mysqli'``
  506. The PHP MySQL extension to use (``mysql`` or ``mysqli``).
  507. It is recommended to use ``mysqli`` in all installations.
  508. .. config:option:: $cfg['Servers'][$i]['pmadb']
  509. :type: string
  510. :default: ``''``
  511. The name of the database containing the phpMyAdmin configuration
  512. storage.
  513. See the :ref:`linked-tables` section in this document to see the benefits of
  514. this feature, and for a quick way of creating this database and the needed
  515. tables.
  516. If you are the only user of this phpMyAdmin installation, you can use your
  517. current database to store those special tables; in this case, just put your
  518. current database name in :config:option:`$cfg['Servers'][$i]['pmadb']`. For a
  519. multi-user installation, set this parameter to the name of your central
  520. database containing the phpMyAdmin configuration storage.
  521. .. _bookmark:
  522. .. config:option:: $cfg['Servers'][$i]['bookmarktable']
  523. :type: string or false
  524. :default: ``''``
  525. Since release 2.2.0 phpMyAdmin allows users to bookmark queries. This
  526. can be useful for queries you often run. To allow the usage of this
  527. functionality:
  528. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  529. * enter the table name in :config:option:`$cfg['Servers'][$i]['bookmarktable']`
  530. This feature can be disabled by setting the configuration to ``false``.
  531. .. _relation:
  532. .. config:option:: $cfg['Servers'][$i]['relation']
  533. :type: string or false
  534. :default: ``''``
  535. Since release 2.2.4 you can describe, in a special 'relation' table,
  536. which column is a key in another table (a foreign key). phpMyAdmin
  537. currently uses this to:
  538. * make clickable, when you browse the master table, the data values that
  539. point to the foreign table;
  540. * display in an optional tool-tip the "display column" when browsing the
  541. master table, if you move the mouse to a column containing a foreign
  542. key (use also the 'table\_info' table); (see :ref:`faqdisplay`)
  543. * in edit/insert mode, display a drop-down list of possible foreign keys
  544. (key value and "display column" are shown) (see :ref:`faq6_21`)
  545. * display links on the table properties page, to check referential
  546. integrity (display missing foreign keys) for each described key;
  547. * in query-by-example, create automatic joins (see :ref:`faq6_6`)
  548. * enable you to get a :term:`PDF` schema of
  549. your database (also uses the table\_coords table).
  550. The keys can be numeric or character.
  551. To allow the usage of this functionality:
  552. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  553. * put the relation table name in :config:option:`$cfg['Servers'][$i]['relation']`
  554. * now as normal user open phpMyAdmin and for each one of your tables
  555. where you want to use this feature, click :guilabel:`Structure/Relation view/`
  556. and choose foreign columns.
  557. This feature can be disabled by setting the configuration to ``false``.
  558. .. note::
  559. In the current version, ``master_db`` must be the same as ``foreign_db``.
  560. Those columns have been put in future development of the cross-db
  561. relations.
  562. .. _table_info:
  563. .. config:option:: $cfg['Servers'][$i]['table_info']
  564. :type: string or false
  565. :default: ``''``
  566. Since release 2.3.0 you can describe, in a special 'table\_info'
  567. table, which column is to be displayed as a tool-tip when moving the
  568. cursor over the corresponding key. This configuration variable will
  569. hold the name of this special table. To allow the usage of this
  570. functionality:
  571. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  572. * put the table name in :config:option:`$cfg['Servers'][$i]['table\_info']` (e.g.
  573. ``pma__table_info``)
  574. * then for each table where you want to use this feature, click
  575. "Structure/Relation view/Choose column to display" to choose the
  576. column.
  577. This feature can be disabled by setting the configuration to ``false``.
  578. .. seealso:: :ref:`faqdisplay`
  579. .. _table_coords:
  580. .. config:option:: $cfg['Servers'][$i]['table_coords']
  581. :type: string or false
  582. :default: ``''``
  583. The designer feature can save your page layout; by pressing the "Save page" or "Save page as"
  584. button in the expanding designer menu, you can customize the layout and have it loaded the next
  585. time you use the designer. That layout is stored in this table. Furthermore, this table is also
  586. required for using the PDF relation export feature, see
  587. :config:option:`$cfg['Servers'][$i]['pdf\_pages']` for additional details.
  588. .. config:option:: $cfg['Servers'][$i]['pdf_pages']
  589. :type: string or false
  590. :default: ``''``
  591. Since release 2.3.0 you can have phpMyAdmin create :term:`PDF` pages
  592. showing the relations between your tables. Further, the designer interface
  593. permits visually managing the relations. To do this it needs two tables
  594. "pdf\_pages" (storing information about the available :term:`PDF` pages)
  595. and "table\_coords" (storing coordinates where each table will be placed on
  596. a :term:`PDF` schema output). You must be using the "relation" feature.
  597. To allow the usage of this functionality:
  598. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  599. * put the correct table names in
  600. :config:option:`$cfg['Servers'][$i]['table\_coords']` and
  601. :config:option:`$cfg['Servers'][$i]['pdf\_pages']`
  602. This feature can be disabled by setting either of the configurations to ``false``.
  603. .. seealso:: :ref:`faqpdf`.
  604. .. _col_com:
  605. .. config:option:: $cfg['Servers'][$i]['column_info']
  606. :type: string or false
  607. :default: ``''``
  608. This part requires a content update! Since release 2.3.0 you can
  609. store comments to describe each column for each table. These will then
  610. be shown on the "printview".
  611. Starting with release 2.5.0, comments are consequently used on the table
  612. property pages and table browse view, showing up as tool-tips above the
  613. column name (properties page) or embedded within the header of table in
  614. browse view. They can also be shown in a table dump. Please see the
  615. relevant configuration directives later on.
  616. Also new in release 2.5.0 is a MIME- transformation system which is also
  617. based on the following table structure. See :ref:`transformations` for
  618. further information. To use the MIME- transformation system, your
  619. column\_info table has to have the three new columns 'mimetype',
  620. 'transformation', 'transformation\_options'.
  621. Starting with release 4.3.0, a new input-oriented transformation system
  622. has been introduced. Also, backward compatibility code used in the old
  623. transformations system was removed. As a result, an update to column\_info
  624. table is necessary for previous transformations and the new input-oriented
  625. transformation system to work. phpMyAdmin will upgrade it automatically
  626. for you by analyzing your current column\_info table structure.
  627. However, if something goes wrong with the auto-upgrade then you can
  628. use the SQL script found in ``./sql/upgrade_column_info_4_3_0+.sql``
  629. to upgrade it manually.
  630. To allow the usage of this functionality:
  631. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  632. * put the table name in :config:option:`$cfg['Servers'][$i]['column\_info']` (e.g.
  633. ``pma__column_info``)
  634. * to update your PRE-2.5.0 Column\_comments table use this: and
  635. remember that the Variable in :file:`config.inc.php` has been renamed from
  636. :samp:`$cfg['Servers'][$i]['column\_comments']` to
  637. :config:option:`$cfg['Servers'][$i]['column\_info']`
  638. .. code-block:: mysql
  639. ALTER TABLE `pma__column_comments`
  640. ADD `mimetype` VARCHAR( 255 ) NOT NULL,
  641. ADD `transformation` VARCHAR( 255 ) NOT NULL,
  642. ADD `transformation_options` VARCHAR( 255 ) NOT NULL;
  643. * to update your PRE-4.3.0 Column\_info table manually use this
  644. ``./sql/upgrade_column_info_4_3_0+.sql`` SQL script.
  645. This feature can be disabled by setting the configuration to ``false``.
  646. .. note::
  647. For auto-upgrade functionality to work, your
  648. :config:option:`$cfg['Servers'][$i]['controluser']` must have ALTER privilege on
  649. ``phpmyadmin`` database. See the `MySQL documentation for GRANT
  650. <https://dev.mysql.com/doc/refman/5.7/en/grant.html>`_ on how to
  651. ``GRANT`` privileges to a user.
  652. .. _history:
  653. .. config:option:: $cfg['Servers'][$i]['history']
  654. :type: string or false
  655. :default: ``''``
  656. Since release 2.5.0 you can store your :term:`SQL` history, which means all
  657. queries you entered manually into the phpMyAdmin interface. If you don't
  658. want to use a table-based history, you can use the JavaScript-based
  659. history.
  660. Using that, all your history items are deleted when closing the window.
  661. Using :config:option:`$cfg['QueryHistoryMax']` you can specify an amount of
  662. history items you want to have on hold. On every login, this list gets cut
  663. to the maximum amount.
  664. The query history is only available if JavaScript is enabled in
  665. your browser.
  666. To allow the usage of this functionality:
  667. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  668. * put the table name in :config:option:`$cfg['Servers'][$i]['history']` (e.g.
  669. ``pma__history``)
  670. This feature can be disabled by setting the configuration to ``false``.
  671. .. _recent:
  672. .. config:option:: $cfg['Servers'][$i]['recent']
  673. :type: string or false
  674. :default: ``''``
  675. Since release 3.5.0 you can show recently used tables in the
  676. navigation panel. It helps you to jump across table directly, without
  677. the need to select the database, and then select the table. Using
  678. :config:option:`$cfg['NumRecentTables']` you can configure the maximum number
  679. of recent tables shown. When you select a table from the list, it will jump to
  680. the page specified in :config:option:`$cfg['NavigationTreeDefaultTabTable']`.
  681. Without configuring the storage, you can still access the recently used tables,
  682. but it will disappear after you logout.
  683. To allow the usage of this functionality persistently:
  684. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  685. * put the table name in :config:option:`$cfg['Servers'][$i]['recent']` (e.g.
  686. ``pma__recent``)
  687. This feature can be disabled by setting the configuration to ``false``.
  688. .. _favorite:
  689. .. config:option:: $cfg['Servers'][$i]['favorite']
  690. :type: string or false
  691. :default: ``''``
  692. Since release 4.2.0 you can show a list of selected tables in the
  693. navigation panel. It helps you to jump to the table directly, without
  694. the need to select the database, and then select the table. When you
  695. select a table from the list, it will jump to the page specified in
  696. :config:option:`$cfg['NavigationTreeDefaultTabTable']`.
  697. You can add tables to this list or remove tables from it in database
  698. structure page by clicking on the star icons next to table names. Using
  699. :config:option:`$cfg['NumFavoriteTables']` you can configure the maximum
  700. number of favorite tables shown.
  701. Without configuring the storage, you can still access the favorite tables,
  702. but it will disappear after you logout.
  703. To allow the usage of this functionality persistently:
  704. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  705. * put the table name in :config:option:`$cfg['Servers'][$i]['favorite']` (e.g.
  706. ``pma__favorite``)
  707. This feature can be disabled by setting the configuration to ``false``.
  708. .. _table_uiprefs:
  709. .. config:option:: $cfg['Servers'][$i]['table_uiprefs']
  710. :type: string or false
  711. :default: ``''``
  712. Since release 3.5.0 phpMyAdmin can be configured to remember several
  713. things (sorted column :config:option:`$cfg['RememberSorting']`, column order,
  714. and column visibility from a database table) for browsing tables. Without
  715. configuring the storage, these features still can be used, but the values will
  716. disappear after you logout.
  717. To allow the usage of these functionality persistently:
  718. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  719. * put the table name in :config:option:`$cfg['Servers'][$i]['table\_uiprefs']` (e.g.
  720. ``pma__table_uiprefs``)
  721. This feature can be disabled by setting the configuration to ``false``.
  722. .. config:option:: $cfg['Servers'][$i]['users']
  723. :type: string or false
  724. :default: ``''``
  725. .. config:option:: $cfg['Servers'][$i]['usergroups']
  726. :type: string or false
  727. :default: ``''``
  728. Since release 4.1.0 you can create different user groups with menu items
  729. attached to them. Users can be assigned to these groups and the logged in
  730. user would only see menu items configured to the usergroup he is assigned to.
  731. To do this it needs two tables "usergroups" (storing allowed menu items for each
  732. user group) and "users" (storing users and their assignments to user groups).
  733. To allow the usage of this functionality:
  734. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  735. * put the correct table names in
  736. :config:option:`$cfg['Servers'][$i]['users']` (e.g. ``pma__users``) and
  737. :config:option:`$cfg['Servers'][$i]['usergroups']` (e.g. ``pma__usergroups``)
  738. This feature can be disabled by setting either of the configurations to ``false``.
  739. .. seealso:: :ref:`configurablemenus`
  740. .. _navigationhiding:
  741. .. config:option:: $cfg['Servers'][$i]['navigationhiding']
  742. :type: string or false
  743. :default: ``''``
  744. Since release 4.1.0 you can hide/show items in the navigation tree.
  745. To allow the usage of this functionality:
  746. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  747. * put the table name in :config:option:`$cfg['Servers'][$i]['navigationhiding']` (e.g.
  748. ``pma__navigationhiding``)
  749. This feature can be disabled by setting the configuration to ``false``.
  750. .. _central_columns:
  751. .. config:option:: $cfg['Servers'][$i]['central_columns']
  752. :type: string or false
  753. :default: ``''``
  754. Since release 4.3.0 you can have a central list of columns per database.
  755. You can add/remove columns to the list as per your requirement. These columns
  756. in the central list will be available to use while you create a new column for
  757. a table or create a table itself. You can select a column from central list
  758. while creating a new column, it will save you from writing the same column definition
  759. over again or from writing different names for similar column.
  760. To allow the usage of this functionality:
  761. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  762. * put the table name in :config:option:`$cfg['Servers'][$i]['central_columns']` (e.g.
  763. ``pma__central_columns``)
  764. This feature can be disabled by setting the configuration to ``false``.
  765. .. _designer_settings:
  766. .. config:option:: $cfg['Servers'][$i]['designer_settings']
  767. :type: string or false
  768. :default: ``''``
  769. Since release 4.5.0 your designer settings can be remembered.
  770. Your choice regarding 'Angular/Direct Links', 'Snap to Grid', 'Toggle Relation Lines',
  771. 'Small/Big All', 'Move Menu' and 'Pin Text' can be remembered persistently.
  772. To allow the usage of this functionality:
  773. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  774. * put the table name in :config:option:`$cfg['Servers'][$i]['designer_settings']` (e.g.
  775. ``pma__designer_settings``)
  776. This feature can be disabled by setting the configuration to ``false``.
  777. .. _savedsearches:
  778. .. config:option:: $cfg['Servers'][$i]['savedsearches']
  779. :type: string or false
  780. :default: ``''``
  781. Since release 4.2.0 you can save and load query-by-example searches from the Database > Query panel.
  782. To allow the usage of this functionality:
  783. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  784. * put the table name in :config:option:`$cfg['Servers'][$i]['savedsearches']` (e.g.
  785. ``pma__savedsearches``)
  786. This feature can be disabled by setting the configuration to ``false``.
  787. .. _export_templates:
  788. .. config:option:: $cfg['Servers'][$i]['export_templates']
  789. :type: string or false
  790. :default: ``''``
  791. Since release 4.5.0 you can save and load export templates.
  792. To allow the usage of this functionality:
  793. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  794. * put the table name in :config:option:`$cfg['Servers'][$i]['export_templates']` (e.g.
  795. ``pma__export_templates``)
  796. This feature can be disabled by setting the configuration to ``false``.
  797. .. _tracking:
  798. .. config:option:: $cfg['Servers'][$i]['tracking']
  799. :type: string or false
  800. :default: ``''``
  801. Since release 3.3.x a tracking mechanism is available. It helps you to
  802. track every :term:`SQL` command which is
  803. executed by phpMyAdmin. The mechanism supports logging of data
  804. manipulation and data definition statements. After enabling it you can
  805. create versions of tables.
  806. The creation of a version has two effects:
  807. * phpMyAdmin saves a snapshot of the table, including structure and
  808. indexes.
  809. * phpMyAdmin logs all commands which change the structure and/or data of
  810. the table and links these commands with the version number.
  811. Of course you can view the tracked changes. On the :guilabel:`Tracking`
  812. page a complete report is available for every version. For the report you
  813. can use filters, for example you can get a list of statements within a date
  814. range. When you want to filter usernames you can enter \* for all names or
  815. you enter a list of names separated by ','. In addition you can export the
  816. (filtered) report to a file or to a temporary database.
  817. To allow the usage of this functionality:
  818. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  819. * put the table name in :config:option:`$cfg['Servers'][$i]['tracking']` (e.g.
  820. ``pma__tracking``)
  821. This feature can be disabled by setting the configuration to ``false``.
  822. .. _tracking2:
  823. .. config:option:: $cfg['Servers'][$i]['tracking_version_auto_create']
  824. :type: boolean
  825. :default: false
  826. Whether the tracking mechanism creates versions for tables and views
  827. automatically.
  828. If this is set to true and you create a table or view with
  829. * CREATE TABLE ...
  830. * CREATE VIEW ...
  831. and no version exists for it, the mechanism will create a version for
  832. you automatically.
  833. .. _tracking3:
  834. .. config:option:: $cfg['Servers'][$i]['tracking_default_statements']
  835. :type: string
  836. :default: ``'CREATE TABLE,ALTER TABLE,DROP TABLE,RENAME TABLE,CREATE INDEX,DROP INDEX,INSERT,UPDATE,DELETE,TRUNCATE,REPLACE,CREATE VIEW,ALTER VIEW,DROP VIEW,CREATE DATABASE,ALTER DATABASE,DROP DATABASE'``
  837. Defines the list of statements the auto-creation uses for new
  838. versions.
  839. .. _tracking4:
  840. .. config:option:: $cfg['Servers'][$i]['tracking_add_drop_view']
  841. :type: boolean
  842. :default: true
  843. Whether a DROP VIEW IF EXISTS statement will be added as first line to
  844. the log when creating a view.
  845. .. _tracking5:
  846. .. config:option:: $cfg['Servers'][$i]['tracking_add_drop_table']
  847. :type: boolean
  848. :default: true
  849. Whether a DROP TABLE IF EXISTS statement will be added as first line
  850. to the log when creating a table.
  851. .. _tracking6:
  852. .. config:option:: $cfg['Servers'][$i]['tracking_add_drop_database']
  853. :type: boolean
  854. :default: true
  855. Whether a DROP DATABASE IF EXISTS statement will be added as first
  856. line to the log when creating a database.
  857. .. _userconfig:
  858. .. config:option:: $cfg['Servers'][$i]['userconfig']
  859. :type: string or false
  860. :default: ``''``
  861. Since release 3.4.x phpMyAdmin allows users to set most preferences by
  862. themselves and store them in the database.
  863. If you don't allow for storing preferences in
  864. :config:option:`$cfg['Servers'][$i]['pmadb']`, users can still personalize
  865. phpMyAdmin, but settings will be saved in browser's local storage, or, it
  866. is is unavailable, until the end of session.
  867. To allow the usage of this functionality:
  868. * set up :config:option:`$cfg['Servers'][$i]['pmadb']` and the phpMyAdmin configuration storage
  869. * put the table name in :config:option:`$cfg['Servers'][$i]['userconfig']`
  870. This feature can be disabled by setting the configuration to ``false``.
  871. .. config:option:: $cfg['Servers'][$i]['MaxTableUiprefs']
  872. :type: integer
  873. :default: 100
  874. Maximum number of rows saved in
  875. :config:option:`$cfg['Servers'][$i]['table_uiprefs']` table.
  876. When tables are dropped or renamed,
  877. :config:option:`$cfg['Servers'][$i]['table_uiprefs']` may contain invalid data
  878. (referring to tables which no longer exist). We only keep this number of newest
  879. rows in :config:option:`$cfg['Servers'][$i]['table_uiprefs']` and automatically
  880. delete older rows.
  881. .. config:option:: $cfg['Servers'][$i]['SessionTimeZone']
  882. :type: string
  883. :default: ``''``
  884. Sets the time zone used by phpMyAdmin. Leave blank to use the time zone of your
  885. database server. Possible values are explained at
  886. https://dev.mysql.com/doc/refman/5.7/en/time-zone-support.html
  887. This is useful when your database server uses a time zone which is different from the
  888. time zone you want to use in phpMyAdmin.
  889. .. config:option:: $cfg['Servers'][$i]['AllowRoot']
  890. :type: boolean
  891. :default: true
  892. Whether to allow root access. This is just a shortcut for the
  893. :config:option:`$cfg['Servers'][$i]['AllowDeny']['rules']` below.
  894. .. config:option:: $cfg['Servers'][$i]['AllowNoPassword']
  895. :type: boolean
  896. :default: false
  897. Whether to allow logins without a password. The default value of
  898. ``false`` for this parameter prevents unintended access to a MySQL
  899. server with was left with an empty password for root or on which an
  900. anonymous (blank) user is defined.
  901. .. _servers_allowdeny_order:
  902. .. config:option:: $cfg['Servers'][$i]['AllowDeny']['order']
  903. :type: string
  904. :default: ``''``
  905. If your rule order is empty, then :term:`IP`
  906. authorization is disabled.
  907. If your rule order is set to
  908. ``'deny,allow'`` then the system applies all deny rules followed by
  909. allow rules. Access is allowed by default. Any client which does not
  910. match a Deny command or does match an Allow command will be allowed
  911. access to the server.
  912. If your rule order is set to ``'allow,deny'``
  913. then the system applies all allow rules followed by deny rules. Access
  914. is denied by default. Any client which does not match an Allow
  915. directive or does match a Deny directive will be denied access to the
  916. server.
  917. If your rule order is set to ``'explicit'``, authorization is
  918. performed in a similar fashion to rule order 'deny,allow', with the
  919. added restriction that your host/username combination **must** be
  920. listed in the *allow* rules, and not listed in the *deny* rules. This
  921. is the **most** secure means of using Allow/Deny rules, and was
  922. available in Apache by specifying allow and deny rules without setting
  923. any order.
  924. Please also see :config:option:`$cfg['TrustedProxies']` for
  925. detecting IP address behind proxies.
  926. .. _servers_allowdeny_rules:
  927. .. config:option:: $cfg['Servers'][$i]['AllowDeny']['rules']
  928. :type: array of strings
  929. :default: array()
  930. The general format for the rules is as such:
  931. .. code-block:: none
  932. <'allow' | 'deny'> <username> [from] <ipmask>
  933. If you wish to match all users, it is possible to use a ``'%'`` as a
  934. wildcard in the *username* field.
  935. There are a few shortcuts you can
  936. use in the *ipmask* field as well (please note that those containing
  937. SERVER\_ADDRESS might not be available on all webservers):
  938. .. code-block:: none
  939. 'all' -> 0.0.0.0/0
  940. 'localhost' -> 127.0.0.1/8
  941. 'localnetA' -> SERVER_ADDRESS/8
  942. 'localnetB' -> SERVER_ADDRESS/16
  943. 'localnetC' -> SERVER_ADDRESS/24
  944. Having an empty rule list is equivalent to either using ``'allow %
  945. from all'`` if your rule order is set to ``'deny,allow'`` or ``'deny %
  946. from all'`` if your rule order is set to ``'allow,deny'`` or
  947. ``'explicit'``.
  948. For the :term:`IP address` matching
  949. system, the following work:
  950. * ``xxx.xxx.xxx.xxx`` (an exact :term:`IP address`)
  951. * ``xxx.xxx.xxx.[yyy-zzz]`` (an :term:`IP address` range)
  952. * ``xxx.xxx.xxx.xxx/nn`` (CIDR, Classless Inter-Domain Routing type :term:`IP` addresses)
  953. But the following does not work:
  954. * ``xxx.xxx.xxx.xx[yyy-zzz]`` (partial :term:`IP` address range)
  955. For :term:`IPv6` addresses, the following work:
  956. * ``xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx`` (an exact :term:`IPv6` address)
  957. * ``xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:[yyyy-zzzz]`` (an :term:`IPv6` address range)
  958. * ``xxxx:xxxx:xxxx:xxxx/nn`` (CIDR, Classless Inter-Domain Routing type :term:`IPv6` addresses)
  959. But the following does not work:
  960. * ``xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xx[yyy-zzz]`` (partial :term:`IPv6` address range)
  961. Examples:
  962. .. code-block:: none
  963. $cfg['Servers'][$i]['AllowDeny']['order'] = 'allow,deny';
  964. $cfg['Servers'][$i]['AllowDeny']['rules'] = array('allow bob from all');
  965. // Allow only 'bob' to connect from any host
  966. $cfg['Servers'][$i]['AllowDeny']['order'] = 'allow,deny';
  967. $cfg['Servers'][$i]['AllowDeny']['rules'] = array('allow mary from 192.168.100.[50-100]');
  968. // Allow only 'mary' to connect from host 192.168.100.50 through 192.168.100.100
  969. $cfg['Servers'][$i]['AllowDeny']['order'] = 'allow,deny';
  970. $cfg['Servers'][$i]['AllowDeny']['rules'] = array('allow % from 192.168.[5-6].10');
  971. // Allow any user to connect from host 192.168.5.10 or 192.168.6.10
  972. $cfg['Servers'][$i]['AllowDeny']['order'] = 'allow,deny';
  973. $cfg['Servers'][$i]['AllowDeny']['rules'] = array('allow root from 192.168.5.50','allow % from 192.168.6.10');
  974. // Allow any user to connect from 192.168.6.10, and additionally allow root to connect from 192.168.5.50
  975. .. config:option:: $cfg['Servers'][$i]['DisableIS']
  976. :type: boolean
  977. :default: false
  978. Disable using ``INFORMATION_SCHEMA`` to retrieve information (use
  979. ``SHOW`` commands instead), because of speed issues when many
  980. databases are present.
  981. .. note::
  982. Enabling this option might give you a big performance boost on older
  983. MySQL servers.
  984. .. config:option:: $cfg['Servers'][$i]['SignonScript']
  985. :type: string
  986. :default: ``''``
  987. .. versionadded:: 3.5.0
  988. Name of PHP script to be sourced and executed to obtain login
  989. credentials. This is alternative approach to session based single
  990. signon. The script has to provide a function called
  991. ``get_login_credentials`` which returns list of username and
  992. password, accepting single parameter of existing username (can be
  993. empty). See :file:`examples/signon-script.php` for an example:
  994. .. literalinclude:: ../examples/signon-script.php
  995. :language: php
  996. .. seealso:: :ref:`auth_signon`
  997. .. config:option:: $cfg['Servers'][$i]['SignonSession']
  998. :type: string
  999. :default: ``''``
  1000. Name of session which will be used for signon authentication method.
  1001. You should use something different than ``phpMyAdmin``, because this
  1002. is session which phpMyAdmin uses internally. Takes effect only if
  1003. :config:option:`$cfg['Servers'][$i]['SignonScript']` is not configured.
  1004. .. seealso:: :ref:`auth_signon`
  1005. .. config:option:: $cfg['Servers'][$i]['SignonCookieParams']
  1006. :type: array
  1007. :default: ``array()``
  1008. .. versionadded:: 4.7.0
  1009. An associative array of session cookie parameters of other authentication system.
  1010. It is not needed if the other system doesn't use session_set_cookie_params().
  1011. Keys should include 'lifetime', 'path', 'domain', 'secure' or 'httponly'.
  1012. Valid values are mentioned in `session_get_cookie_params <https://www.php.net/manual/en/
  1013. function.session-get-cookie-params.php>`_, they should be set to same values as the
  1014. other application uses. Takes effect only if
  1015. :config:option:`$cfg['Servers'][$i]['SignonScript']` is not configured.
  1016. .. seealso:: :ref:`auth_signon`
  1017. .. config:option:: $cfg['Servers'][$i]['SignonURL']
  1018. :type: string
  1019. :default: ``''``
  1020. :term:`URL` where user will be redirected
  1021. to log in for signon authentication method. Should be absolute
  1022. including protocol.
  1023. .. seealso:: :ref:`auth_signon`
  1024. .. config:option:: $cfg['Servers'][$i]['LogoutURL']
  1025. :type: string
  1026. :default: ``''``
  1027. :term:`URL` where user will be redirected
  1028. after logout (doesn't affect config authentication method). Should be
  1029. absolute including protocol.
  1030. .. config:option:: $cfg['Servers'][$i]['hide_connection_errors']
  1031. :type: boolean
  1032. :default: false
  1033. .. versionadded:: 4.9.8
  1034. Whether to show or hide detailed MySQL/MariaDB connection errors on the login page.
  1035. .. note::
  1036. This error message can contain the target database server hostname or IP address,
  1037. which may reveal information about your network to an attacker.
  1038. Generic settings
  1039. ----------------
  1040. .. config:option:: $cfg['DisableShortcutKeys']
  1041. :type: boolean
  1042. :default: false
  1043. You can disable phpMyAdmin shortcut keys by setting :config:option:`$cfg['DisableShortcutKeys']` to false.
  1044. .. config:option:: $cfg['ServerDefault']
  1045. :type: integer
  1046. :default: 1
  1047. If you have more than one server configured, you can set
  1048. :config:option:`$cfg['ServerDefault']` to any one of them to autoconnect to that
  1049. server when phpMyAdmin is started, or set it to 0 to be given a list
  1050. of servers without logging in.
  1051. If you have only one server configured,
  1052. :config:option:`$cfg['ServerDefault']` MUST be set to that server.
  1053. .. config:option:: $cfg['VersionCheck']
  1054. :type: boolean
  1055. :default: true
  1056. Enables check for latest versions using JavaScript on the main phpMyAdmin
  1057. page or by directly accessing :file:`version_check.php`.
  1058. .. note::
  1059. This setting can be adjusted by your vendor.
  1060. .. config:option:: $cfg['ProxyUrl']
  1061. :type: string
  1062. :default: ""
  1063. The url of the proxy to be used when phpmyadmin needs to access the outside
  1064. internet such as when retrieving the latest version info or submitting error
  1065. reports. You need this if the server where phpMyAdmin is installed does not
  1066. have direct access to the internet.
  1067. The format is: "hostname:portnumber"
  1068. .. config:option:: $cfg['ProxyUser']
  1069. :type: string
  1070. :default: ""
  1071. The username for authenticating with the proxy. By default, no
  1072. authentication is performed. If a username is supplied, Basic
  1073. Authentication will be performed. No other types of authentication
  1074. are currently supported.
  1075. .. config:option:: $cfg['ProxyPass']
  1076. :type: string
  1077. :default: ""
  1078. The password for authenticating with the proxy.
  1079. .. config:option:: $cfg['MaxDbList']
  1080. :type: integer
  1081. :default: 100
  1082. The maximum number of database names to be displayed in the main panel's
  1083. database list.
  1084. .. config:option:: $cfg['MaxTableList']
  1085. :type: integer
  1086. :default: 250
  1087. The maximum number of table names to be displayed in the main panel's
  1088. list (except on the Export page).
  1089. .. config:option:: $cfg['ShowHint']
  1090. :type: boolean
  1091. :default: true
  1092. Whether or not to show hints (for example, hints when hovering over
  1093. table headers).
  1094. .. config:option:: $cfg['MaxCharactersInDisplayedSQL']
  1095. :type: integer
  1096. :default: 1000
  1097. The maximum number of characters when a :term:`SQL` query is displayed. The
  1098. default limit of 1000 should be correct to avoid the display of tons of
  1099. hexadecimal codes that represent BLOBs, but some users have real
  1100. :term:`SQL` queries that are longer than 1000 characters. Also, if a
  1101. query's length exceeds this limit, this query is not saved in the history.
  1102. .. config:option:: $cfg['PersistentConnections']
  1103. :type: boolean
  1104. :default: false
  1105. Whether `persistent connections <https://www.php.net/manual/en/features
  1106. .persistent-connections.php>`_ should be used or not. Works with
  1107. following extensions:
  1108. * mysql (`mysql\_pconnect <https://www.php.net/manual/en/function.mysql-
  1109. pconnect.php>`_),
  1110. * mysqli (requires PHP 5.3.0 or newer, `more information
  1111. <https://www.php.net/manual/en/mysqli.persistconns.php>`_).
  1112. .. config:option:: $cfg['ForceSSL']
  1113. :type: boolean
  1114. :default: false
  1115. .. deprecated:: 4.6.0
  1116. This setting is no longer available since phpMyAdmin 4.6.0. Please
  1117. adjust your webserver instead.
  1118. Whether to force using https while accessing phpMyAdmin. In a reverse
  1119. proxy setup, setting this to ``true`` is not supported.
  1120. .. note::
  1121. In some setups (like separate SSL proxy or load balancer) you might
  1122. have to set :config:option:`$cfg['PmaAbsoluteUri']` for correct
  1123. redirection.
  1124. .. config:option:: $cfg['ExecTimeLimit']
  1125. :type: integer [number of seconds]
  1126. :default: 300
  1127. Set the number of seconds a script is allowed to run. If seconds is
  1128. set to zero, no time limit is imposed. This setting is used while
  1129. importing/exporting dump files but has
  1130. no effect when PHP is running in safe mode.
  1131. .. config:option:: $cfg['SessionSavePath']
  1132. :type: string
  1133. :default: ``''``
  1134. Path for storing session data (`session\_save\_path PHP parameter
  1135. <https://www.php.net/session_save_path>`_).
  1136. .. warning::
  1137. This folder should not be publicly accessible through the webserver,
  1138. otherwise you risk leaking private data from your session.
  1139. .. config:option:: $cfg['MemoryLimit']
  1140. :type: string [number of bytes]
  1141. :default: ``'-1'``
  1142. Set the number of bytes a script is allowed to allocate. If set to
  1143. ``'-1'``, no limit is imposed. If set to ``'0'``, no change of the
  1144. memory limit is attempted and the :file:`php.ini` ``memory_limit`` is
  1145. used.
  1146. This setting is used while importing/exporting dump files
  1147. so you definitely don't want to put here a too low
  1148. value. It has no effect when PHP is running in safe mode.
  1149. You can also use any string as in :file:`php.ini`, eg. '16M'. Ensure you
  1150. don't omit the suffix (16 means 16 bytes!)
  1151. .. config:option:: $cfg['SkipLockedTables']
  1152. :type: boolean
  1153. :default: false
  1154. Mark used tables and make it possible to show databases with locked
  1155. tables (since MySQL 3.23.30).
  1156. .. config:option:: $cfg['ShowSQL']
  1157. :type: boolean
  1158. :default: true
  1159. Defines whether :term:`SQL` queries
  1160. generated by phpMyAdmin should be displayed or not.
  1161. .. config:option:: $cfg['RetainQueryBox']
  1162. :type: boolean
  1163. :default: false
  1164. Defines whether the :term:`SQL` query box
  1165. should be kept displayed after its submission.
  1166. .. config:option:: $cfg['CodemirrorEnable']
  1167. :type: boolean
  1168. :default: true
  1169. Defines whether to use a Javascript code editor for SQL query boxes.
  1170. CodeMirror provides syntax highlighting and line numbers. However,
  1171. middle-clicking for pasting the clipboard contents in some Linux
  1172. distributions (such as Ubuntu) is not supported by all browsers.
  1173. .. config:option:: $cfg['DefaultForeignKeyChecks']
  1174. :type: string
  1175. :default: ``'default'``
  1176. Default value of the checkbox for foreign key checks, to disable/enable
  1177. foreign key checks for certain queries. The possible values are ``'default'``,
  1178. ``'enable'`` or ``'disable'``. If set to ``'default'``, the value of the
  1179. MySQL variable ``FOREIGN_KEY_CHECKS`` is used.
  1180. .. config:option:: $cfg['AllowUserDropDatabase']
  1181. :type: boolean
  1182. :default: false
  1183. .. warning::
  1184. This is not a security measure as there will be always ways to
  1185. circumvent this. If you want to prohibit users from dropping databases,
  1186. revoke their corresponding DROP privilege.
  1187. Defines whether normal users (non-administrator) are allowed to delete
  1188. their own database or not. If set as false, the link :guilabel:`Drop
  1189. Database` will not be shown, and even a ``DROP DATABASE mydatabase`` will
  1190. be rejected. Quite practical for :term:`ISP` 's with many customers.
  1191. This limitation of :term:`SQL` queries is not as strict as when using MySQL
  1192. privileges. This is due to nature of :term:`SQL` queries which might be
  1193. quite complicated. So this choice should be viewed as help to avoid
  1194. accidental dropping rather than strict privilege limitation.
  1195. .. config:option:: $cfg['Confirm']
  1196. :type: boolean
  1197. :default: true
  1198. Whether a warning ("Are your really sure...") should be displayed when
  1199. you're about to lose data.
  1200. .. config:option:: $cfg['UseDbSearch']
  1201. :type: boolean
  1202. :default: true
  1203. Define whether the "search string inside database" is enabled or not.
  1204. .. config:option:: $cfg['IgnoreMultiSubmitErrors']
  1205. :type: boolean
  1206. :default: false
  1207. Define whether phpMyAdmin will continue executing a multi-query
  1208. statement if one of the queries fails. Default is to abort execution.
  1209. .. config:option:: $cfg['URLQueryEncryption']
  1210. :type: boolean
  1211. :default: false
  1212. .. versionadded:: 4.9.8
  1213. Define whether phpMyAdmin will encrypt sensitive data (like database name
  1214. and table name) from the URL query string. Default is to not encrypt the URL
  1215. query string.
  1216. .. config:option:: $cfg['URLQueryEncryptionSecretKey']
  1217. :type: string
  1218. :default: ``''``
  1219. .. versionadded:: 4.9.8
  1220. A secret key used to encrypt/decrypt the URL query string.
  1221. Should be 32 bytes long.
  1222. Cookie authentication options
  1223. -----------------------------
  1224. .. config:option:: $cfg['blowfish_secret']
  1225. :type: string
  1226. :default: ``''``
  1227. The "cookie" auth\_type uses AES algorithm to encrypt the password. If you
  1228. are using the "cookie" auth\_type, enter here a random passphrase of your
  1229. choice. It will be used internally by the AES algorithm: you won’t be
  1230. prompted for this passphrase.
  1231. The secret should be 32 characters long. Using shorter will lead to weaker security
  1232. of encrypted cookies, using longer will cause no harm.
  1233. .. note::
  1234. The configuration is called blowfish_secret for historical reasons as
  1235. Blowfish algorithm was originally used to do the encryption.
  1236. .. versionchanged:: 3.1.0
  1237. Since version 3.1.0 phpMyAdmin can generate this on the fly, but it
  1238. makes a bit weaker security as this generated secret is stored in
  1239. session and furthermore it makes impossible to recall user name from
  1240. cookie.
  1241. .. config:option:: $cfg['LoginCookieRecall']
  1242. :type: boolean
  1243. :default: true
  1244. Define whether the previous login should be recalled or not in cookie
  1245. authentication mode.
  1246. This is automatically disabled if you do not have
  1247. configured :config:option:`$cfg['blowfish_secret']`.
  1248. .. config:option:: $cfg['LoginCookieValidity']
  1249. :type: integer [number of seconds]
  1250. :default: 1440
  1251. Define how long a login cookie is valid. Please note that php
  1252. configuration option `session.gc\_maxlifetime
  1253. <https://www.php.net/manual/en/session.configuration.php#ini.session.gc-
  1254. maxlifetime>`_ might limit session validity and if the session is lost,
  1255. the login cookie is also invalidated. So it is a good idea to set
  1256. ``session.gc_maxlifetime`` at least to the same value of
  1257. :config:option:`$cfg['LoginCookieValidity']`.
  1258. .. config:option:: $cfg['LoginCookieStore']
  1259. :type: integer [number of seconds]
  1260. :default: 0
  1261. Define how long login cookie should be stored in browser. Default 0
  1262. means that it will be kept for existing session. This is recommended
  1263. for not trusted environments.
  1264. .. config:option:: $cfg['LoginCookieDeleteAll']
  1265. :type: boolean
  1266. :default: true
  1267. If enabled (default), logout deletes cookies for all servers,
  1268. otherwise only for current one. Setting this to false makes it easy to
  1269. forget to log out from other server, when you are using more of them.
  1270. .. _AllowArbitraryServer:
  1271. .. config:option:: $cfg['AllowArbitraryServer']
  1272. :type: boolean
  1273. :default: false
  1274. If enabled, allows you to log in to arbitrary servers using cookie
  1275. authentication.
  1276. .. note::
  1277. Please use this carefully, as this may allow users access to MySQL servers
  1278. behind the firewall where your :term:`HTTP` server is placed.
  1279. See also :config:option:`$cfg['ArbitraryServerRegexp']`.
  1280. .. config:option:: $cfg['ArbitraryServerRegexp']
  1281. :type: string
  1282. :default: ``''``
  1283. Restricts the MySQL servers to which the user can log in when
  1284. :config:option:`$cfg['AllowArbitraryServer']` is enabled by
  1285. matching the :term:`IP` or the hostname of the MySQL server
  1286. to the given regular expression. The regular expression must be enclosed
  1287. with a delimiter character.
  1288. It is recommended to include start and end symbols in the regullar
  1289. expression, so that you can avoid partial matches on the string.
  1290. **Examples:**
  1291. .. code-block:: php
  1292. // Allow connection to three listed servers:
  1293. $cfg['ArbitraryServerRegexp'] = '/^(server|another|yetdifferent)$/';
  1294. // Allow connection to range of IP addresses:
  1295. $cfg['ArbitraryServerRegexp'] = '@^192\.168\.0\.[0-9]{1,}$@';
  1296. // Allow connection to server name ending with -mysql:
  1297. $cfg['ArbitraryServerRegexp'] = '@^[^:]\-mysql$@';
  1298. .. note::
  1299. The whole server name is matched, it can include port as well. Due to
  1300. way MySQL is permissive in connection parameters, it is possible to use
  1301. connection strings as ```server:3306-mysql```. This can be used to
  1302. bypass regullar expression by the suffix, while connecting to another
  1303. server.
  1304. .. config:option:: $cfg['CaptchaLoginPublicKey']
  1305. :type: string
  1306. :default: ``''``
  1307. The public key for the reCaptcha service that can be obtained from
  1308. https://www.google.com/recaptcha/intro/v3.html.
  1309. reCaptcha will be then used in :ref:`cookie`.
  1310. .. config:option:: $cfg['CaptchaLoginPrivateKey']
  1311. :type: string
  1312. :default: ``''``
  1313. The private key for the reCaptcha service that can be obtain from
  1314. https://www.google.com/recaptcha/intro/v3.html.
  1315. reCaptcha will be then used in :ref:`cookie`.
  1316. Navigation panel setup
  1317. ----------------------
  1318. .. config:option:: $cfg['ShowDatabasesNavigationAsTree']
  1319. :type: boolean
  1320. :default: true
  1321. In the navigation panel, replaces the database tree with a selector
  1322. .. config:option:: $cfg['FirstLevelNavigationItems']
  1323. :type: integer
  1324. :default: 100
  1325. The number of first level databases that can be displayed on each page
  1326. of navigation tree.
  1327. .. config:option:: $cfg['MaxNavigationItems']
  1328. :type: integer
  1329. :default: 50
  1330. The number of items (tables, columns, indexes) that can be displayed on each
  1331. page of the navigation tree.
  1332. .. config:option:: $cfg['NavigationTreeEnableGrouping']
  1333. :type: boolean
  1334. :default: true
  1335. Defines whether to group the databases based on a common prefix
  1336. in their name :config:option:`$cfg['NavigationTreeDbSeparator']`.
  1337. .. config:option:: $cfg['NavigationTreeDbSeparator']
  1338. :type: string
  1339. :default: ``'_'``
  1340. The string used to separate the parts of the database name when
  1341. showing them in a tree.
  1342. .. config:option:: $cfg['NavigationTreeTableSeparator']
  1343. :type: string or array
  1344. :default: ``'__'``
  1345. Defines a string to be used to nest table spaces. This means if you have
  1346. tables like ``first__second__third`` this will be shown as a three-level
  1347. hierarchy like: first > second > third. If set to false or empty, the
  1348. feature is disabled. NOTE: You should not use this separator at the
  1349. beginning or end of a table name or multiple times after another without
  1350. any other characters in between.
  1351. .. config:option:: $cfg['NavigationTreeTableLevel']
  1352. :type: integer
  1353. :default: 1
  1354. Defines how many sublevels should be displayed when splitting up
  1355. tables by the above separator.
  1356. .. config:option:: $cfg['NumRecentTables']
  1357. :type: integer
  1358. :default: 10
  1359. The maximum number of recently used tables shown in the navigation
  1360. panel. Set this to 0 (zero) to disable the listing of recent tables.
  1361. .. config:option:: $cfg['NumFavoriteTables']
  1362. :type: integer
  1363. :default: 10
  1364. The maximum number of favorite tables shown in the navigation
  1365. panel. Set this to 0 (zero) to disable the listing of favorite tables.
  1366. .. config:option:: $cfg['ZeroConf']
  1367. :type: boolean
  1368. :default: true
  1369. Enables Zero Configuration mode in which the user will be offered a choice to
  1370. create phpMyAdmin configuration storage in the current database
  1371. or use the existing one, if already present.
  1372. This setting has no effect if the phpMyAdmin configuration storage database
  1373. is properly created and the related configuration directives (such as
  1374. :config:option:`$cfg['Servers'][$i]['pmadb']` and so on) are configured.
  1375. .. config:option:: $cfg['NavigationLinkWithMainPanel']
  1376. :type: boolean
  1377. :default: true
  1378. Defines whether or not to link with main panel by highlighting
  1379. the current database or table.
  1380. .. config:option:: $cfg['NavigationDisplayLogo']
  1381. :type: boolean
  1382. :default: true
  1383. Defines whether or not to display the phpMyAdmin logo at the top of
  1384. the navigation panel.
  1385. .. config:option:: $cfg['NavigationLogoLink']
  1386. :type: string
  1387. :default: ``'index.php'``
  1388. Enter :term:`URL` where logo in the navigation panel will point to.
  1389. For use especially with self made theme which changes this.
  1390. For relative/internal URLs, you need to have leading `` ./ `` or trailing characters `` ? `` such as ``'./sql.php?'``.
  1391. For external URLs, you should include URL protocol schemes (``http`` or ``https``) with absolute URLs.
  1392. .. config:option:: $cfg['NavigationLogoLinkWindow']
  1393. :type: string
  1394. :default: ``'main'``
  1395. Whether to open the linked page in the main window (``main``) or in a
  1396. new one (``new``). Note: use ``new`` if you are linking to
  1397. ``phpmyadmin.net``.
  1398. .. config:option:: $cfg['NavigationTreeDisplayItemFilterMinimum']
  1399. :type: integer
  1400. :default: 30
  1401. Defines the minimum number of items (tables, views, routines and
  1402. events) to display a JavaScript filter box above the list of items in
  1403. the navigation tree.
  1404. To disable the filter completely some high number can be used (e.g. 9999)
  1405. .. config:option:: $cfg['NavigationTreeDisplayDbFilterMinimum']
  1406. :type: integer
  1407. :default: 30
  1408. Defines the minimum number of databases to display a JavaScript filter
  1409. box above the list of databases in the navigation tree.
  1410. To disable the filter completely some high number can be used
  1411. (e.g. 9999)
  1412. .. config:option:: $cfg['NavigationDisplayServers']
  1413. :type: boolean
  1414. :default: true
  1415. Defines whether or not to display a server choice at the top of the
  1416. navigation panel.
  1417. .. config:option:: $cfg['DisplayServersList']
  1418. :type: boolean
  1419. :default: false
  1420. Defines whether to display this server choice as links instead of in a
  1421. drop-down.
  1422. .. config:option:: $cfg['NavigationTreeDefaultTabTable']
  1423. :type: string
  1424. :default: ``'structure'``
  1425. Defines the tab displayed by default when clicking the small icon next
  1426. to each table name in the navigation panel. The possible values are the
  1427. localized equivalent of:
  1428. * ``structure``
  1429. * ``sql``
  1430. * ``search``
  1431. * ``insert``
  1432. * ``browse``
  1433. .. config:option:: $cfg['NavigationTreeDefaultTabTable2']
  1434. :type: string
  1435. :default: null
  1436. Defines the tab displayed by default when clicking the second small icon next
  1437. to each table name in the navigation panel. The possible values are the
  1438. localized equivalent of:
  1439. * ``(empty)``
  1440. * ``structure``
  1441. * ``sql``
  1442. * ``search``
  1443. * ``insert``
  1444. * ``browse``
  1445. .. config:option:: $cfg['NavigationTreeEnableExpansion']
  1446. :type: boolean
  1447. :default: true
  1448. Whether to offer the possibility of tree expansion in the navigation panel.
  1449. .. config:option:: $cfg['NavigationTreeShowTables']
  1450. :type: boolean
  1451. :default: true
  1452. Whether to show tables under database in the navigation panel.
  1453. .. config:option:: $cfg['NavigationTreeShowViews']
  1454. :type: boolean
  1455. :default: true
  1456. Whether to show views under database in the navigation panel.
  1457. .. config:option:: $cfg['NavigationTreeShowFunctions']
  1458. :type: boolean
  1459. :default: true
  1460. Whether to show functions under database in the navigation panel.
  1461. .. config:option:: $cfg['NavigationTreeShowProcedures']
  1462. :type: boolean
  1463. :default: true
  1464. Whether to show procedures under database in the navigation panel.
  1465. .. config:option:: $cfg['NavigationTreeShowEvents']
  1466. :type: boolean
  1467. :default: true
  1468. Whether to show events under database in the navigation panel.
  1469. .. config:option:: $cfg['NavigationWidth']
  1470. :type: integer
  1471. :default: 240
  1472. Navigation panel width, set to 0 to collapse it by default.
  1473. Main panel
  1474. ----------
  1475. .. config:option:: $cfg['ShowStats']
  1476. :type: boolean
  1477. :default: true
  1478. Defines whether or not to display space usage and statistics about
  1479. databases and tables. Note that statistics requires at least MySQL
  1480. 3.23.3 and that, at this date, MySQL doesn't return such information
  1481. for Berkeley DB tables.
  1482. .. config:option:: $cfg['ShowServerInfo']
  1483. :type: boolean
  1484. :default: true
  1485. Defines whether to display detailed server information on main page.
  1486. You can additionally hide more information by using
  1487. :config:option:`$cfg['Servers'][$i]['verbose']`.
  1488. .. config:option:: $cfg['ShowPhpInfo']
  1489. :type: boolean
  1490. :default: false
  1491. Defines whether to display the :guilabel:`PHP information` or not at
  1492. the starting main (right) frame.
  1493. Please note that to block the usage of ``phpinfo()`` in scripts, you have to
  1494. put this in your :file:`php.ini`:
  1495. .. code-block:: ini
  1496. disable_functions = phpinfo()
  1497. .. warning::
  1498. Enabling phpinfo page will leak quite a lot of information about server
  1499. setup. Is it not recommended to enable this on shared installations.
  1500. This might also make easier some remote attacks on your installations,
  1501. so enable this only when needed.
  1502. .. config:option:: $cfg['ShowChgPassword']
  1503. :type: boolean
  1504. :default: true
  1505. Defines whether to display the :guilabel:`Change password` link or not at
  1506. the starting main (right) frame. This setting does not check MySQL commands
  1507. entered directly.
  1508. Please note that enabling the :guilabel:`Change password` link has no effect
  1509. with config authentication mode: because of the hard coded password value
  1510. in the configuration file, end users can't be allowed to change their
  1511. passwords.
  1512. .. config:option:: $cfg['ShowCreateDb']
  1513. :type: boolean
  1514. :default: true
  1515. Defines whether to display the form for creating database or not at the
  1516. starting main (right) frame. This setting does not check MySQL commands
  1517. entered directly.
  1518. .. config:option:: $cfg['ShowGitRevision']
  1519. :type: boolean
  1520. :default: true
  1521. Defines whether to display informations about the current Git revision (if
  1522. applicable) on the main panel.
  1523. .. config:option:: $cfg['MysqlMinVersion']
  1524. :type: array
  1525. Defines the minimum supported MySQL version. The default is chosen
  1526. by the phpMyAdmin team; however this directive was asked by a developer
  1527. of the Plesk control panel to ease integration with older MySQL servers
  1528. (where most of the phpMyAdmin features work).
  1529. Database structure
  1530. ------------------
  1531. .. config:option:: $cfg['ShowDbStructureCreation']
  1532. :type: boolean
  1533. :default: false
  1534. Defines whether the database structure page (tables list) has a
  1535. "Creation" column that displays when each table was created.
  1536. .. config:option:: $cfg['ShowDbStructureLastUpdate']
  1537. :type: boolean
  1538. :default: false
  1539. Defines whether the database structure page (tables list) has a "Last
  1540. update" column that displays when each table was last updated.
  1541. .. config:option:: $cfg['ShowDbStructureLastCheck']
  1542. :type: boolean
  1543. :default: false
  1544. Defines whether the database structure page (tables list) has a "Last
  1545. check" column that displays when each table was last checked.
  1546. .. config:option:: $cfg['HideStructureActions']
  1547. :type: boolean
  1548. :default: true
  1549. Defines whether the table structure actions are hidden under a "More"
  1550. drop-down.
  1551. .. config:option:: $cfg['ShowColumnComments']
  1552. :type: boolean
  1553. :default: true
  1554. Defines whether to show column comments as a column in the table structure view.
  1555. Browse mode
  1556. -----------
  1557. .. config:option:: $cfg['TableNavigationLinksMode']
  1558. :type: string
  1559. :default: ``'icons'``
  1560. Defines whether the table navigation links contain ``'icons'``, ``'text'``
  1561. or ``'both'``.
  1562. .. config:option:: $cfg['ActionLinksMode']
  1563. :type: string
  1564. :default: ``'both'``
  1565. If set to ``icons``, will display icons instead of text for db and table
  1566. properties links (like :guilabel:`Browse`, :guilabel:`Select`,
  1567. :guilabel:`Insert`, ...). Can be set to ``'both'``
  1568. if you want icons AND text. When set to ``text``, will only show text.
  1569. .. config:option:: $cfg['RowActionType']
  1570. :type: string
  1571. :default: ``'both'``
  1572. Whether to display icons or text or both icons and text in table row action
  1573. segment. Value can be either of ``'icons'``, ``'text'`` or ``'both'``.
  1574. .. config:option:: $cfg['ShowAll']
  1575. :type: boolean
  1576. :default: false
  1577. Defines whether a user should be displayed a "Show all" button in browse
  1578. mode or not in all cases. By default it is shown only on small tables (less
  1579. than 500 rows) to avoid performance issues while getting too many rows.
  1580. .. config:option:: $cfg['MaxRows']
  1581. :type: integer
  1582. :default: 25
  1583. Number of rows displayed when browsing a result set and no LIMIT
  1584. clause is used. If the result set contains more rows, "Previous" and
  1585. "Next" links will be shown. Possible values: 25,50,100,250,500.
  1586. .. config:option:: $cfg['Order']
  1587. :type: string
  1588. :default: ``'SMART'``
  1589. Defines whether columns are displayed in ascending (``ASC``) order, in
  1590. descending (``DESC``) order or in a "smart" (``SMART``) order - I.E.
  1591. descending order for columns of type TIME, DATE, DATETIME and
  1592. TIMESTAMP, ascending order else- by default.
  1593. .. versionchanged:: 3.4.0
  1594. Since phpMyAdmin 3.4.0 the default value is ``'SMART'``.
  1595. .. config:option:: $cfg['GridEditing']
  1596. :type: string
  1597. :default: ``'double-click'``
  1598. Defines which action (``double-click`` or ``click``) triggers grid
  1599. editing. Can be deactivated with the ``disabled`` value.
  1600. .. config:option:: $cfg['RelationalDisplay']
  1601. :type: string
  1602. :default: ``'K'``
  1603. Defines the initial behavior for Options > Relational. ``K``, which
  1604. is the default, displays the key while ``D`` shows the display column.
  1605. .. config:option:: $cfg['SaveCellsAtOnce']
  1606. :type: boolean
  1607. :default: false
  1608. Defines whether or not to save all edited cells at once for grid
  1609. editing.
  1610. Editing mode
  1611. ------------
  1612. .. config:option:: $cfg['ProtectBinary']
  1613. :type: boolean or string
  1614. :default: ``'blob'``
  1615. Defines whether ``BLOB`` or ``BINARY`` columns are protected from
  1616. editing when browsing a table's content. Valid values are:
  1617. * ``false`` to allow editing of all columns;
  1618. * ``'blob'`` to allow editing of all columns except ``BLOBS``;
  1619. * ``'noblob'`` to disallow editing of all columns except ``BLOBS`` (the
  1620. opposite of ``'blob'``);
  1621. * ``'all'`` to disallow editing of all ``BINARY`` or ``BLOB`` columns.
  1622. .. config:option:: $cfg['ShowFunctionFields']
  1623. :type: boolean
  1624. :default: true
  1625. Defines whether or not MySQL functions fields should be initially
  1626. displayed in edit/insert mode. Since version 2.10, the user can toggle
  1627. this setting from the interface.
  1628. .. config:option:: $cfg['ShowFieldTypesInDataEditView']
  1629. :type: boolean
  1630. :default: true
  1631. Defines whether or not type fields should be initially displayed in
  1632. edit/insert mode. The user can toggle this setting from the interface.
  1633. .. config:option:: $cfg['InsertRows']
  1634. :type: integer
  1635. :default: 2
  1636. Defines the default number of rows to be entered from the Insert page.
  1637. Users can manually change this from the bottom of that page to add or remove
  1638. blank rows.
  1639. .. config:option:: $cfg['ForeignKeyMaxLimit']
  1640. :type: integer
  1641. :default: 100
  1642. If there are fewer items than this in the set of foreign keys, then a
  1643. drop-down box of foreign keys is presented, in the style described by
  1644. the :config:option:`$cfg['ForeignKeyDropdownOrder']` setting.
  1645. .. config:option:: $cfg['ForeignKeyDropdownOrder']
  1646. :type: array
  1647. :default: array('content-id', 'id-content')
  1648. For the foreign key drop-down fields, there are several methods of
  1649. display, offering both the key and value data. The contents of the
  1650. array should be one or both of the following strings: ``content-id``,
  1651. ``id-content``.
  1652. Export and import settings
  1653. --------------------------
  1654. .. config:option:: $cfg['ZipDump']
  1655. :type: boolean
  1656. :default: true
  1657. .. config:option:: $cfg['GZipDump']
  1658. :type: boolean
  1659. :default: true
  1660. .. config:option:: $cfg['BZipDump']
  1661. :type: boolean
  1662. :default: true
  1663. Defines whether to allow the use of zip/GZip/BZip2 compression when
  1664. creating a dump file
  1665. .. config:option:: $cfg['CompressOnFly']
  1666. :type: boolean
  1667. :default: true
  1668. Defines whether to allow on the fly compression for GZip/BZip2
  1669. compressed exports. This doesn't affect smaller dumps and allows users
  1670. to create larger dumps that won't otherwise fit in memory due to php
  1671. memory limit. Produced files contain more GZip/BZip2 headers, but all
  1672. normal programs handle this correctly.
  1673. .. config:option:: $cfg['Export']
  1674. :type: array
  1675. :default: array(...)
  1676. In this array are defined default parameters for export, names of
  1677. items are similar to texts seen on export page, so you can easily
  1678. identify what they mean.
  1679. .. config:option:: $cfg['Export']['format']
  1680. :type: string
  1681. :default: ``'sql'``
  1682. Default export format.
  1683. .. config:option:: $cfg['Export']['method']
  1684. :type: string
  1685. :default: ``'quick'``
  1686. Defines how the export form is displayed when it loads. Valid values
  1687. are:
  1688. * ``quick`` to display the minimum number of options to configure
  1689. * ``custom`` to display every available option to configure
  1690. * ``custom-no-form`` same as ``custom`` but does not display the option
  1691. of using quick export
  1692. .. config:option:: $cfg['Export']['charset']
  1693. :type: string
  1694. :default: ``''``
  1695. Defines charset for generated export. By default no charset conversion is
  1696. done assuming UTF-8.
  1697. .. config:option:: $cfg['Export']['file_template_table']
  1698. :type: string
  1699. :default: ``'@TABLE@'``
  1700. Default filename template for table exports.
  1701. .. seealso:: :ref:`faq6_27`
  1702. .. config:option:: $cfg['Export']['file_template_database']
  1703. :type: string
  1704. :default: ``'@DATABASE@'``
  1705. Default filename template for database exports.
  1706. .. seealso:: :ref:`faq6_27`
  1707. .. config:option:: $cfg['Export']['file_template_server']
  1708. :type: string
  1709. :default: ``'@SERVER@'``
  1710. Default filename template for server exports.
  1711. .. seealso:: :ref:`faq6_27`
  1712. .. config:option:: $cfg['Import']
  1713. :type: array
  1714. :default: array(...)
  1715. In this array are defined default parameters for import, names of
  1716. items are similar to texts seen on import page, so you can easily
  1717. identify what they mean.
  1718. .. config:option:: $cfg['Import']['charset']
  1719. :type: string
  1720. :default: ``''``
  1721. Defines charset for import. By default no charset conversion is done
  1722. assuming UTF-8.
  1723. Tabs display settings
  1724. ---------------------
  1725. .. config:option:: $cfg['TabsMode']
  1726. :type: string
  1727. :default: ``'both'``
  1728. Defines whether the menu tabs contain ``'icons'``, ``'text'`` or ``'both'``.
  1729. .. config:option:: $cfg['PropertiesNumColumns']
  1730. :type: integer
  1731. :default: 1
  1732. How many columns will be utilized to display the tables on the database
  1733. property view? When setting this to a value larger than 1, the type of the
  1734. database will be omitted for more display space.
  1735. .. config:option:: $cfg['DefaultTabServer']
  1736. :type: string
  1737. :default: ``'welcome'``
  1738. Defines the tab displayed by default on server view. The possible values
  1739. are the localized equivalent of:
  1740. * ``welcome`` (recommended for multi-user setups)
  1741. * ``databases``,
  1742. * ``status``
  1743. * ``variables``
  1744. * ``privileges``
  1745. .. config:option:: $cfg['DefaultTabDatabase']
  1746. :type: string
  1747. :default: ``'structure'``
  1748. Defines the tab displayed by default on database view. The possible values
  1749. are the localized equivalent of:
  1750. * ``structure``
  1751. * ``sql``
  1752. * ``search``
  1753. * ``operations``
  1754. .. config:option:: $cfg['DefaultTabTable']
  1755. :type: string
  1756. :default: ``'browse'``
  1757. Defines the tab displayed by default on table view. The possible values
  1758. are the localized equivalent of:
  1759. * ``structure``
  1760. * ``sql``
  1761. * ``search``
  1762. * ``insert``
  1763. * ``browse``
  1764. PDF Options
  1765. -----------
  1766. .. config:option:: $cfg['PDFPageSizes']
  1767. :type: array
  1768. :default: ``array('A3', 'A4', 'A5', 'letter', 'legal')``
  1769. Array of possible paper sizes for creating PDF pages.
  1770. You should never need to change this.
  1771. .. config:option:: $cfg['PDFDefaultPageSize']
  1772. :type: string
  1773. :default: ``'A4'``
  1774. Default page size to use when creating PDF pages. Valid values are any
  1775. listed in :config:option:`$cfg['PDFPageSizes']`.
  1776. Languages
  1777. ---------
  1778. .. config:option:: $cfg['DefaultLang']
  1779. :type: string
  1780. :default: ``'en'``
  1781. Defines the default language to use, if not browser-defined or user-
  1782. defined. The corresponding language file needs to be in
  1783. locale/*code*/LC\_MESSAGES/phpmyadmin.mo.
  1784. .. config:option:: $cfg['DefaultConnectionCollation']
  1785. :type: string
  1786. :default: ``'utf8mb4_general_ci'``
  1787. Defines the default connection collation to use, if not user-defined.
  1788. See the `MySQL documentation for charsets
  1789. <https://dev.mysql.com/doc/refman/5.7/en/charset-charsets.html>`_
  1790. for list of possible values.
  1791. .. config:option:: $cfg['Lang']
  1792. :type: string
  1793. :default: not set
  1794. Force language to use. The corresponding language file needs to be in
  1795. locale/*code*/LC\_MESSAGES/phpmyadmin.mo.
  1796. .. config:option:: $cfg['FilterLanguages']
  1797. :type: string
  1798. :default: ``''``
  1799. Limit list of available languages to those matching the given regular
  1800. expression. For example if you want only Czech and English, you should
  1801. set filter to ``'^(cs|en)'``.
  1802. .. config:option:: $cfg['RecodingEngine']
  1803. :type: string
  1804. :default: ``'auto'``
  1805. You can select here which functions will be used for character set
  1806. conversion. Possible values are:
  1807. * auto - automatically use available one (first is tested iconv, then
  1808. recode)
  1809. * iconv - use iconv or libiconv functions
  1810. * recode - use recode\_string function
  1811. * mb - use :term:`mbstring` extension
  1812. * none - disable encoding conversion
  1813. Enabled charset conversion activates a pull-down menu in the Export
  1814. and Import pages, to choose the character set when exporting a file.
  1815. The default value in this menu comes from
  1816. :config:option:`$cfg['Export']['charset']` and :config:option:`$cfg['Import']['charset']`.
  1817. .. config:option:: $cfg['IconvExtraParams']
  1818. :type: string
  1819. :default: ``'//TRANSLIT'``
  1820. Specify some parameters for iconv used in charset conversion. See
  1821. `iconv documentation <https://www.gnu.org/savannah-checkouts/gnu/libiconv/documentati
  1822. on/libiconv-1.15/iconv_open.3.html>`_ for details. By default
  1823. ``//TRANSLIT`` is used, so that invalid characters will be
  1824. transliterated.
  1825. .. config:option:: $cfg['AvailableCharsets']
  1826. :type: array
  1827. :default: array(...)
  1828. Available character sets for MySQL conversion. You can add your own
  1829. (any of supported by recode/iconv) or remove these which you don't
  1830. use. Character sets will be shown in same order as here listed, so if
  1831. you frequently use some of these move them to the top.
  1832. Web server settings
  1833. -------------------
  1834. .. config:option:: $cfg['OBGzip']
  1835. :type: string/boolean
  1836. :default: ``'auto'``
  1837. Defines whether to use GZip output buffering for increased speed in
  1838. :term:`HTTP` transfers. Set to
  1839. true/false for enabling/disabling. When set to 'auto' (string),
  1840. phpMyAdmin tries to enable output buffering and will automatically
  1841. disable it if your browser has some problems with buffering. IE6 with
  1842. a certain patch is known to cause data corruption when having enabled
  1843. buffering.
  1844. .. config:option:: $cfg['TrustedProxies']
  1845. :type: array
  1846. :default: array()
  1847. Lists proxies and HTTP headers which are trusted for
  1848. :config:option:`$cfg['Servers'][$i]['AllowDeny']['order']`. This list is by
  1849. default empty, you need to fill in some trusted proxy servers if you
  1850. want to use rules for IP addresses behind proxy.
  1851. The following example specifies that phpMyAdmin should trust a
  1852. HTTP\_X\_FORWARDED\_FOR (``X-Forwarded-For``) header coming from the proxy
  1853. 1.2.3.4:
  1854. .. code-block:: php
  1855. $cfg['TrustedProxies'] = array('1.2.3.4' => 'HTTP_X_FORWARDED_FOR');
  1856. The :config:option:`$cfg['Servers'][$i]['AllowDeny']['rules']` directive uses the
  1857. client's IP address as usual.
  1858. .. config:option:: $cfg['GD2Available']
  1859. :type: string
  1860. :default: ``'auto'``
  1861. Specifies whether GD >= 2 is available. If yes it can be used for MIME
  1862. transformations. Possible values are:
  1863. * auto - automatically detect
  1864. * yes - GD 2 functions can be used
  1865. * no - GD 2 function cannot be used
  1866. .. config:option:: $cfg['CheckConfigurationPermissions']
  1867. :type: boolean
  1868. :default: true
  1869. We normally check the permissions on the configuration file to ensure
  1870. it's not world writable. However, phpMyAdmin could be installed on a
  1871. NTFS filesystem mounted on a non-Windows server, in which case the
  1872. permissions seems wrong but in fact cannot be detected. In this case a
  1873. sysadmin would set this parameter to ``false``.
  1874. .. config:option:: $cfg['LinkLengthLimit']
  1875. :type: integer
  1876. :default: 1000
  1877. Limit for length of :term:`URL` in links. When length would be above this
  1878. limit, it is replaced by form with button. This is required as some web
  1879. servers (:term:`IIS`) have problems with long :term:`URL` .
  1880. .. config:option:: $cfg['CSPAllow']
  1881. :type: string
  1882. :default: ``''``
  1883. Additional string to include in allowed script and image sources in Content
  1884. Security Policy header.
  1885. This can be useful when you want to include some external JavaScript files
  1886. in :file:`config.footer.inc.php` or :file:`config.header.inc.php`, which
  1887. would be normally not allowed by Content Security Policy.
  1888. To allow some sites, just list them within the string:
  1889. .. code-block:: php
  1890. $cfg['CSPAllow'] = 'example.com example.net';
  1891. .. versionadded:: 4.0.4
  1892. .. config:option:: $cfg['DisableMultiTableMaintenance']
  1893. :type: boolean
  1894. :default: false
  1895. In the database Structure page, it's possible to mark some tables then
  1896. choose an operation like optimizing for many tables. This can slow
  1897. down a server; therefore, setting this to ``true`` prevents this kind
  1898. of multiple maintenance operation.
  1899. Theme settings
  1900. --------------
  1901. Please directly modify :file:`themes/themename/layout.inc.php`, although
  1902. your changes will be overwritten with the next update.
  1903. Design customization
  1904. --------------------
  1905. .. config:option:: $cfg['NavigationTreePointerEnable']
  1906. :type: boolean
  1907. :default: true
  1908. When set to true, hovering over an item in the navigation panel causes that item to be marked
  1909. (the background is highlighted).
  1910. .. config:option:: $cfg['BrowsePointerEnable']
  1911. :type: boolean
  1912. :default: true
  1913. When set to true, hovering over a row in the Browse page causes that row to be marked (the background
  1914. is highlighted).
  1915. .. config:option:: $cfg['BrowseMarkerEnable']
  1916. :type: boolean
  1917. :default: true
  1918. When set to true, a data row is marked (the background is highlighted) when the row is selected
  1919. with the checkbox.
  1920. .. config:option:: $cfg['LimitChars']
  1921. :type: integer
  1922. :default: 50
  1923. Maximum number of characters shown in any non-numeric field on browse
  1924. view. Can be turned off by a toggle button on the browse page.
  1925. .. config:option:: $cfg['RowActionLinks']
  1926. :type: string
  1927. :default: ``'left'``
  1928. Defines the place where table row links (Edit, Copy, Delete) would be
  1929. put when tables contents are displayed (you may have them displayed at
  1930. the left side, right side, both sides or nowhere).
  1931. .. config:option:: $cfg['RowActionLinksWithoutUnique']
  1932. :type: boolean
  1933. :default: false
  1934. Defines whether to show row links (Edit, Copy, Delete) and checkboxes
  1935. for multiple row operations even when the selection does not have a :term:`unique key`.
  1936. Using row actions in the absence of a unique key may result in different/more
  1937. rows being affected since there is no guaranteed way to select the exact row(s).
  1938. .. config:option:: $cfg['RememberSorting']
  1939. :type: boolean
  1940. :default: true
  1941. If enabled, remember the sorting of each table when browsing them.
  1942. .. config:option:: $cfg['TablePrimaryKeyOrder']
  1943. :type: string
  1944. :default: ``'NONE'``
  1945. This defines the default sort order for the tables, having a :term:`primary key`,
  1946. when there is no sort order defines externally.
  1947. Acceptable values : ['NONE', 'ASC', 'DESC']
  1948. .. config:option:: $cfg['ShowBrowseComments']
  1949. :type: boolean
  1950. :default: true
  1951. .. config:option:: $cfg['ShowPropertyComments']
  1952. :type: boolean
  1953. :default: true
  1954. By setting the corresponding variable to ``true`` you can enable the
  1955. display of column comments in Browse or Property display. In browse
  1956. mode, the comments are shown inside the header. In property mode,
  1957. comments are displayed using a CSS-formatted dashed-line below the
  1958. name of the column. The comment is shown as a tool-tip for that
  1959. column.
  1960. Text fields
  1961. -----------
  1962. .. config:option:: $cfg['CharEditing']
  1963. :type: string
  1964. :default: ``'input'``
  1965. Defines which type of editing controls should be used for CHAR and
  1966. VARCHAR columns. Applies to data editing and also to the default values
  1967. in structure editing. Possible values are:
  1968. * input - this allows to limit size of text to size of columns in MySQL,
  1969. but has problems with newlines in columns
  1970. * textarea - no problems with newlines in columns, but also no length
  1971. limitations
  1972. .. config:option:: $cfg['MinSizeForInputField']
  1973. :type: integer
  1974. :default: 4
  1975. Defines the minimum size for input fields generated for CHAR and
  1976. VARCHAR columns.
  1977. .. config:option:: $cfg['MaxSizeForInputField']
  1978. :type: integer
  1979. :default: 60
  1980. Defines the maximum size for input fields generated for CHAR and
  1981. VARCHAR columns.
  1982. .. config:option:: $cfg['TextareaCols']
  1983. :type: integer
  1984. :default: 40
  1985. .. config:option:: $cfg['TextareaRows']
  1986. :type: integer
  1987. :default: 15
  1988. .. config:option:: $cfg['CharTextareaCols']
  1989. :type: integer
  1990. :default: 40
  1991. .. config:option:: $cfg['CharTextareaRows']
  1992. :type: integer
  1993. :default: 2
  1994. Number of columns and rows for the textareas. This value will be
  1995. emphasized (\*2) for :term:`SQL` query
  1996. textareas and (\*1.25) for :term:`SQL`
  1997. textareas inside the query window.
  1998. The Char\* values are used for CHAR
  1999. and VARCHAR editing (if configured via :config:option:`$cfg['CharEditing']`).
  2000. .. config:option:: $cfg['LongtextDoubleTextarea']
  2001. :type: boolean
  2002. :default: true
  2003. Defines whether textarea for LONGTEXT columns should have double size.
  2004. .. config:option:: $cfg['TextareaAutoSelect']
  2005. :type: boolean
  2006. :default: false
  2007. Defines if the whole textarea of the query box will be selected on
  2008. click.
  2009. .. config:option:: $cfg['EnableAutocompleteForTablesAndColumns']
  2010. :type: boolean
  2011. :default: true
  2012. Whether to enable autocomplete for table and column names in any
  2013. SQL query box.
  2014. SQL query box settings
  2015. ----------------------
  2016. .. config:option:: $cfg['SQLQuery']['Edit']
  2017. :type: boolean
  2018. :default: true
  2019. Whether to display an edit link to change a query in any SQL Query
  2020. box.
  2021. .. config:option:: $cfg['SQLQuery']['Explain']
  2022. :type: boolean
  2023. :default: true
  2024. Whether to display a link to explain a SELECT query in any SQL Query
  2025. box.
  2026. .. config:option:: $cfg['SQLQuery']['ShowAsPHP']
  2027. :type: boolean
  2028. :default: true
  2029. Whether to display a link to wrap a query in PHP code in any SQL Query
  2030. box.
  2031. .. config:option:: $cfg['SQLQuery']['Refresh']
  2032. :type: boolean
  2033. :default: true
  2034. Whether to display a link to refresh a query in any SQL Query box.
  2035. .. _web-dirs:
  2036. Web server upload/save/import directories
  2037. -----------------------------------------
  2038. If PHP is running in safe mode, all directories must be owned by the same user
  2039. as the owner of the phpMyAdmin scripts.
  2040. If the directory where phpMyAdmin is installed is subject to an
  2041. ``open_basedir`` restriction, you need to create a temporary directory in some
  2042. directory accessible by the PHP interpreter.
  2043. For security reasons, all directories should be outside the tree published by
  2044. webserver. If you cannot avoid having this directory published by webserver,
  2045. limit access to it either by web server configuration (for example using
  2046. .htaccess or web.config files) or place at least an empty :file:`index.html`
  2047. file there, so that directory listing is not possible. However as long as the
  2048. directory is accessible by web server, an attacker can guess filenames to download
  2049. the files.
  2050. .. config:option:: $cfg['UploadDir']
  2051. :type: string
  2052. :default: ``''``
  2053. The name of the directory where :term:`SQL` files have been uploaded by
  2054. other means than phpMyAdmin (for example, ftp). Those files are available
  2055. under a drop-down box when you click the database or table name, then the
  2056. Import tab.
  2057. If
  2058. you want different directory for each user, %u will be replaced with
  2059. username.
  2060. Please note that the file names must have the suffix ".sql"
  2061. (or ".sql.bz2" or ".sql.gz" if support for compressed formats is
  2062. enabled).
  2063. This feature is useful when your file is too big to be
  2064. uploaded via :term:`HTTP`, or when file
  2065. uploads are disabled in PHP.
  2066. .. warning::
  2067. Please see top of this chapter (:ref:`web-dirs`) for instructions how
  2068. to setup this directory and how to make its usage secure.
  2069. .. seealso::
  2070. See :ref:`faq1_16` for alternatives.
  2071. .. config:option:: $cfg['SaveDir']
  2072. :type: string
  2073. :default: ``''``
  2074. The name of the webserver directory where exported files can be saved.
  2075. If you want a different directory for each user, %u will be replaced with the
  2076. username.
  2077. Please note that the directory must exist and has to be writable for
  2078. the user running webserver.
  2079. .. warning::
  2080. Please see top of this chapter (:ref:`web-dirs`) for instructions how
  2081. to setup this directory and how to make its usage secure.
  2082. .. config:option:: $cfg['TempDir']
  2083. :type: string
  2084. :default: ``'./tmp/'``
  2085. The name of the directory where temporary files can be stored. It is used
  2086. for several purposes, currently:
  2087. * The templates cache which speeds up page loading.
  2088. * ESRI Shapefiles import, see :ref:`faq6_30`.
  2089. * To work around limitations of ``open_basedir`` for uploaded files, see
  2090. :ref:`faq1_11`.
  2091. This directory should have as strict permissions as possible as the only
  2092. user required to access this directory is the one who runs the webserver.
  2093. If you have root privileges, simply make this user owner of this directory
  2094. and make it accessible only by it:
  2095. .. code-block:: sh
  2096. chown www-data:www-data tmp
  2097. chmod 700 tmp
  2098. If you cannot change owner of the directory, you can achieve a similar
  2099. setup using :term:`ACL`:
  2100. .. code-block:: sh
  2101. chmod 700 tmp
  2102. setfacl -m "g:www-data:rwx" tmp
  2103. setfacl -d -m "g:www-data:rwx" tmp
  2104. If neither of above works for you, you can still make the directory
  2105. :command:`chmod 777`, but it might impose risk of other users on system
  2106. reading and writing data in this directory.
  2107. .. warning::
  2108. Please see top of this chapter (:ref:`web-dirs`) for instructions how
  2109. to setup this directory and how to make its usage secure.
  2110. Various display setting
  2111. -----------------------
  2112. .. config:option:: $cfg['RepeatCells']
  2113. :type: integer
  2114. :default: 100
  2115. Repeat the headers every X cells, or 0 to deactivate.
  2116. .. config:option:: $cfg['QueryHistoryDB']
  2117. :type: boolean
  2118. :default: false
  2119. .. config:option:: $cfg['QueryHistoryMax']
  2120. :type: integer
  2121. :default: 25
  2122. If :config:option:`$cfg['QueryHistoryDB']` is set to ``true``, all your
  2123. Queries are logged to a table, which has to be created by you (see
  2124. :config:option:`$cfg['Servers'][$i]['history']`). If set to false, all your
  2125. queries will be appended to the form, but only as long as your window is
  2126. opened they remain saved.
  2127. When using the JavaScript based query window, it will always get updated
  2128. when you click on a new table/db to browse and will focus if you click on
  2129. :guilabel:`Edit SQL` after using a query. You can suppress updating the
  2130. query window by checking the box :guilabel:`Do not overwrite this query
  2131. from outside the window` below the query textarea. Then you can browse
  2132. tables/databases in the background without losing the contents of the
  2133. textarea, so this is especially useful when composing a query with tables
  2134. you first have to look in. The checkbox will get automatically checked
  2135. whenever you change the contents of the textarea. Please uncheck the button
  2136. whenever you definitely want the query window to get updated even though
  2137. you have made alterations.
  2138. If :config:option:`$cfg['QueryHistoryDB']` is set to ``true`` you can
  2139. specify the amount of saved history items using
  2140. :config:option:`$cfg['QueryHistoryMax']`.
  2141. .. config:option:: $cfg['BrowseMIME']
  2142. :type: boolean
  2143. :default: true
  2144. Enable :ref:`transformations`.
  2145. .. config:option:: $cfg['MaxExactCount']
  2146. :type: integer
  2147. :default: 50000
  2148. For InnoDB tables, determines for how large tables phpMyAdmin should
  2149. get the exact row count using ``SELECT COUNT``. If the approximate row
  2150. count as returned by ``SHOW TABLE STATUS`` is smaller than this value,
  2151. ``SELECT COUNT`` will be used, otherwise the approximate count will be
  2152. used.
  2153. .. versionchanged:: 4.8.0
  2154. The default value was lowered to 50000 for performance reasons.
  2155. .. versionchanged:: 4.2.6
  2156. The default value was changed to 500000.
  2157. .. seealso:: :ref:`faq3_11`
  2158. .. config:option:: $cfg['MaxExactCountViews']
  2159. :type: integer
  2160. :default: 0
  2161. For VIEWs, since obtaining the exact count could have an impact on
  2162. performance, this value is the maximum to be displayed, using a
  2163. ``SELECT COUNT ... LIMIT``. Setting this to 0 bypasses any row
  2164. counting.
  2165. .. config:option:: $cfg['NaturalOrder']
  2166. :type: boolean
  2167. :default: true
  2168. Sorts database and table names according to natural order (for
  2169. example, t1, t2, t10). Currently implemented in the navigation panel
  2170. and in Database view, for the table list.
  2171. .. config:option:: $cfg['InitialSlidersState']
  2172. :type: string
  2173. :default: ``'closed'``
  2174. If set to ``'closed'``, the visual sliders are initially in a closed
  2175. state. A value of ``'open'`` does the reverse. To completely disable
  2176. all visual sliders, use ``'disabled'``.
  2177. .. config:option:: $cfg['UserprefsDisallow']
  2178. :type: array
  2179. :default: array()
  2180. Contains names of configuration options (keys in ``$cfg`` array) that
  2181. users can't set through user preferences. For possible values, refer
  2182. to clases under :file:`libraries/classes/Config/Forms/User/`.
  2183. .. config:option:: $cfg['UserprefsDeveloperTab']
  2184. :type: boolean
  2185. :default: false
  2186. Activates in the user preferences a tab containing options for
  2187. developers of phpMyAdmin.
  2188. Page titles
  2189. -----------
  2190. .. config:option:: $cfg['TitleTable']
  2191. :type: string
  2192. :default: ``'@HTTP_HOST@ / @VSERVER@ / @DATABASE@ / @TABLE@ | @PHPMYADMIN@'``
  2193. .. config:option:: $cfg['TitleDatabase']
  2194. :type: string
  2195. :default: ``'@HTTP_HOST@ / @VSERVER@ / @DATABASE@ | @PHPMYADMIN@'``
  2196. .. config:option:: $cfg['TitleServer']
  2197. :type: string
  2198. :default: ``'@HTTP_HOST@ / @VSERVER@ | @PHPMYADMIN@'``
  2199. .. config:option:: $cfg['TitleDefault']
  2200. :type: string
  2201. :default: ``'@HTTP_HOST@ | @PHPMYADMIN@'``
  2202. Allows you to specify window's title bar. You can use :ref:`faq6_27`.
  2203. Theme manager settings
  2204. ----------------------
  2205. .. config:option:: $cfg['ThemeManager']
  2206. :type: boolean
  2207. :default: true
  2208. Enables user-selectable themes. See :ref:`faqthemes`.
  2209. .. config:option:: $cfg['ThemeDefault']
  2210. :type: string
  2211. :default: ``'pmahomme'``
  2212. The default theme (a subdirectory under :file:`./themes/`).
  2213. .. config:option:: $cfg['ThemePerServer']
  2214. :type: boolean
  2215. :default: false
  2216. Whether to allow different theme for each server.
  2217. .. config:option:: $cfg['FontSize']
  2218. :type: string
  2219. :default: '82%'
  2220. Font size to use, is applied in CSS.
  2221. Default queries
  2222. ---------------
  2223. .. config:option:: $cfg['DefaultQueryTable']
  2224. :type: string
  2225. :default: ``'SELECT * FROM @TABLE@ WHERE 1'``
  2226. .. config:option:: $cfg['DefaultQueryDatabase']
  2227. :type: string
  2228. :default: ``''``
  2229. Default queries that will be displayed in query boxes when user didn't
  2230. specify any. You can use standard :ref:`faq6_27`.
  2231. MySQL settings
  2232. --------------
  2233. .. config:option:: $cfg['DefaultFunctions']
  2234. :type: array
  2235. :default: array(...)
  2236. Functions selected by default when inserting/changing row, Functions
  2237. are defined for meta types as (FUNC\_NUMBER, FUNC\_DATE, FUNC\_CHAR,
  2238. FUNC\_SPATIAL, FUNC\_UUID) and for ``first_timestamp``, which is used
  2239. for first timestamp column in table.
  2240. Default options for Transformations
  2241. -----------------------------------
  2242. .. config:option:: $cfg['DefaultTransformations']
  2243. :type: array
  2244. :default: An array with below listed key-values
  2245. .. config:option:: $cfg['DefaultTransformations']['Substring']
  2246. :type: array
  2247. :default: array(0, 'all', '…')
  2248. .. config:option:: $cfg['DefaultTransformations']['Bool2Text']
  2249. :type: array
  2250. :default: array('T', 'F')
  2251. .. config:option:: $cfg['DefaultTransformations']['External']
  2252. :type: array
  2253. :default: array(0, '-f /dev/null -i -wrap -q', 1, 1)
  2254. .. config:option:: $cfg['DefaultTransformations']['PreApPend']
  2255. :type: array
  2256. :default: array('', '')
  2257. .. config:option:: $cfg['DefaultTransformations']['Hex']
  2258. :type: array
  2259. :default: array('2')
  2260. .. config:option:: $cfg['DefaultTransformations']['DateFormat']
  2261. :type: array
  2262. :default: array(0, '', 'local')
  2263. .. config:option:: $cfg['DefaultTransformations']['Inline']
  2264. :type: array
  2265. :default: array('100', 100)
  2266. .. config:option:: $cfg['DefaultTransformations']['TextImageLink']
  2267. :type: array
  2268. :default: array('', 100, 50)
  2269. .. config:option:: $cfg['DefaultTransformations']['TextLink']
  2270. :type: array
  2271. :default: array('', '', '')
  2272. Console settings
  2273. ----------------
  2274. .. note::
  2275. These settings are mostly meant to be changed by user.
  2276. .. config:option:: $cfg['Console']['StartHistory']
  2277. :type: boolean
  2278. :default: false
  2279. Show query history at start
  2280. .. config:option:: $cfg['Console']['AlwaysExpand']
  2281. :type: boolean
  2282. :default: false
  2283. Always expand query messages
  2284. .. config:option:: $cfg['Console']['CurrentQuery']
  2285. :type: boolean
  2286. :default: true
  2287. Show current browsing query
  2288. .. config:option:: $cfg['Console']['EnterExecutes']
  2289. :type: boolean
  2290. :default: false
  2291. Execute queries on Enter and insert new line with Shift + Enter
  2292. .. config:option:: $cfg['Console']['DarkTheme']
  2293. :type: boolean
  2294. :default: false
  2295. Switch to dark theme
  2296. .. config:option:: $cfg['Console']['Mode']
  2297. :type: string
  2298. :default: 'info'
  2299. Console mode
  2300. .. config:option:: $cfg['Console']['Height']
  2301. :type: integer
  2302. :default: 92
  2303. Console height
  2304. Developer
  2305. ---------
  2306. .. warning::
  2307. These settings might have huge effect on performance or security.
  2308. .. config:option:: $cfg['DBG']
  2309. :type: array
  2310. :default: array(...)
  2311. .. config:option:: $cfg['DBG']['sql']
  2312. :type: boolean
  2313. :default: false
  2314. Enable logging queries and execution times to be
  2315. displayed in the console's Debug SQL tab.
  2316. .. config:option:: $cfg['DBG']['sqllog']
  2317. :type: boolean
  2318. :default: false
  2319. Enable logging of queries and execution times to the syslog.
  2320. Requires :config:option:`$cfg['DBG']['sql']` to be enabled.
  2321. .. config:option:: $cfg['DBG']['demo']
  2322. :type: boolean
  2323. :default: false
  2324. Enable to let server present itself as demo server.
  2325. This is used for `phpMyAdmin demo server <https://www.phpmyadmin.net/try/>`_.
  2326. It currently changes following behavior:
  2327. * There is welcome message on the main page.
  2328. * There is footer information about demo server and used git revision.
  2329. * The setup script is enabled even with existing configuration.
  2330. * The setup does not try to connect to the MySQL server.
  2331. .. config:option:: $cfg['DBG']['simple2fa']
  2332. :type: boolean
  2333. :default: false
  2334. Can be used for testing two-factor authentication using :ref:`simple2fa`.
  2335. .. _config-examples:
  2336. Examples
  2337. --------
  2338. See following configuration snippets for typical setups of phpMyAdmin.
  2339. Basic example
  2340. +++++++++++++
  2341. Example configuration file, which can be copied to :file:`config.inc.php` to
  2342. get some core configuration layout; it is distributed with phpMyAdmin as
  2343. :file:`config.sample.inc.php`. Please note that it does not contain all
  2344. configuration options, only the most frequently used ones.
  2345. .. literalinclude:: ../config.sample.inc.php
  2346. :language: php
  2347. .. warning::
  2348. Don't use the controluser 'pma' if it does not yet exist and don't use 'pmapass'
  2349. as password.
  2350. .. _example-signon:
  2351. Example for signon authentication
  2352. +++++++++++++++++++++++++++++++++
  2353. This example uses :file:`examples/signon.php` to demonstrate usage of :ref:`auth_signon`:
  2354. .. code-block:: php
  2355. <?php
  2356. $i = 0;
  2357. $i++;
  2358. $cfg['Servers'][$i]['extension'] = 'mysqli';
  2359. $cfg['Servers'][$i]['auth_type'] = 'signon';
  2360. $cfg['Servers'][$i]['SignonSession'] = 'SignonSession';
  2361. $cfg['Servers'][$i]['SignonURL'] = 'examples/signon.php';
  2362. ?>`
  2363. Example for IP address limited autologin
  2364. ++++++++++++++++++++++++++++++++++++++++
  2365. If you want to automatically login when accessing phpMyAdmin locally while asking
  2366. for a password when accessing remotely, you can achieve it using following snippet:
  2367. .. code-block:: php
  2368. if ($_SERVER["REMOTE_ADDR"] == "127.0.0.1") {
  2369. $cfg['Servers'][$i]['auth_type'] = 'config';
  2370. $cfg['Servers'][$i]['user'] = 'root';
  2371. $cfg['Servers'][$i]['password'] = 'yourpassword';
  2372. } else {
  2373. $cfg['Servers'][$i]['auth_type'] = 'cookie';
  2374. }
  2375. .. note::
  2376. Filtering based on IP addresses isn't reliable over the internet, use it
  2377. only for local address.
  2378. Example for using multiple MySQL servers
  2379. ++++++++++++++++++++++++++++++++++++++++
  2380. You can configure any number of servers using :config:option:`$cfg['Servers']`,
  2381. following example shows two of them:
  2382. .. code-block:: php
  2383. <?php
  2384. $cfg['blowfish_secret']='multiServerExample70518';
  2385. //any string of your choice
  2386. $i = 0;
  2387. $i++; // server 1 :
  2388. $cfg['Servers'][$i]['auth_type'] = 'cookie';
  2389. $cfg['Servers'][$i]['verbose'] = 'no1';
  2390. $cfg['Servers'][$i]['host'] = 'localhost';
  2391. $cfg['Servers'][$i]['extension'] = 'mysqli';
  2392. // more options for #1 ...
  2393. $i++; // server 2 :
  2394. $cfg['Servers'][$i]['auth_type'] = 'cookie';
  2395. $cfg['Servers'][$i]['verbose'] = 'no2';
  2396. $cfg['Servers'][$i]['host'] = 'remote.host.addr';//or ip:'10.9.8.1'
  2397. // this server must allow remote clients, e.g., host 10.9.8.%
  2398. // not only in mysql.host but also in the startup configuration
  2399. $cfg['Servers'][$i]['extension'] = 'mysqli';
  2400. // more options for #2 ...
  2401. // end of server sections
  2402. $cfg['ServerDefault'] = 0; // to choose the server on startup
  2403. // further general options ...
  2404. ?>
  2405. .. _example-google-ssl:
  2406. Google Cloud SQL with SSL
  2407. +++++++++++++++++++++++++
  2408. To connect to Google Could SQL, you currently need to disable certificate
  2409. verification. This is caused by the certficate being issued for CN matching
  2410. your instance name, but you connect to an IP address and PHP tries to match
  2411. these two. With verfication you end up with error message like:
  2412. .. code-block:: text
  2413. Peer certificate CN=`api-project-851612429544:pmatest' did not match expected CN=`8.8.8.8'
  2414. .. warning::
  2415. With disabled verification your traffic is encrypted, but you're open to
  2416. man in the middle attacks.
  2417. To connect phpMyAdmin to Google Cloud SQL using SSL download the client and
  2418. server certificates and tell phpMyAdmin to use them:
  2419. .. code-block:: php
  2420. // IP address of your instance
  2421. $cfg['Servers'][$i]['host'] = '8.8.8.8';
  2422. // Use SSL for connection
  2423. $cfg['Servers'][$i]['ssl'] = true;
  2424. // Client secret key
  2425. $cfg['Servers'][$i]['ssl_key'] = '../client-key.pem';
  2426. // Client certificate
  2427. $cfg['Servers'][$i]['ssl_cert'] = '../client-cert.pem';
  2428. // Server certification authority
  2429. $cfg['Servers'][$i]['ssl_ca'] = '../server-ca.pem';
  2430. // Disable SSL verification (see above note)
  2431. $cfg['Servers'][$i]['ssl_verify'] = false;
  2432. .. seealso::
  2433. :ref:`ssl`,
  2434. :config:option:`$cfg['Servers'][$i]['ssl']`,
  2435. :config:option:`$cfg['Servers'][$i]['ssl_key']`,
  2436. :config:option:`$cfg['Servers'][$i]['ssl_cert']`,
  2437. :config:option:`$cfg['Servers'][$i]['ssl_ca']`,
  2438. :config:option:`$cfg['Servers'][$i]['ssl_verify']`,
  2439. <https://bugs.php.net/bug.php?id=72048>