config.rst.txt 118 KB

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