Professional WordPress. Design and Development. Brad Williams. Читать онлайн. Newlib. NEWLIB.NET

Автор: Brad Williams
Издательство: John Wiley & Sons Limited
Серия:
Жанр произведения: Зарубежная образовательная литература
Год издания: 0
isbn: 9781118987278
Скачать книгу
built-in localizer. WordPress displays in English by default, but can easily be set to display any language that has been translated. Setting the WPLANG option triggers WordPress to load the specified language files:

      The option value shown previously comprises the ISO-639 language code followed by the ISO-3166 country code. So en-GB would be English-Great Britain. This setting will reference your .mo and .po files for language translation.

      You can also define the LANGDIR option. This option defines what directory will hold your language .mo files. By default, WordPress looks in wp-content/languages for the .mo file. If you would like to move this folder, just set the LANGDIR option like so:

      WordPress will now look in the new location for your .mo files.

      CUSTOM_USER_TABLE and CUSTOM_USER_META_TABLE are also very powerful options. They are useful if you want to have two or more individual WordPress installs use the same user accounts. Remember to set this prior to installing WordPress.

      Setting these two options enables you to define the name of the default WordPress user and usermeta database tables. Doing this means both websites share user information including usernames, passwords, author bios, and so on. This is a great way to set up a new installation of WordPress but not lose sync with your current user accounts.

      If you would like your users to have different roles on each WordPress install, but still share user accounts, don’t set the CUSTOM_USER_META_TABLE option. Everything stored in the user tables will stay the same, but everything else will be blog-specific (that is, user level, first and last name, and so on).

      You can set multiple cookie options such as COOKIE_DOMAIN, COOKIEPATH, and SITECOOKIEPATH. These options are typically used in a WordPress Multisite installation utilizing subdomains for websites. This allows you to set the primary domain so cookies can be created and validated on all subdomains in the network.

      Typically, you won’t need to use or change this option, but if you run into issues with cookies, this is the first place to check.

      Since the inclusion of the automatic installer functionality for plugins and themes, as well as the automatic update process, you can set FTP settings directly in your wp-config.php file. This is only needed if your host is not configured to support the automatic install process. This is easily detectable because each time you try to install a plugin or theme you are asked for your FTP information.

      To save your FTP information in WordPress, add the following options in your wp-config.php file:

      Just enter your FTP username, password, and host with port and you’re all set! WordPress will no longer ask for your FTP information when using the automatic installer.

      You can set additional FTP/SSH options for various configurations:

      You can also override default file permissions in WordPress using the FS_CHMOD_FILE and FS_CHMOD_DIR options:

      The numeric single digit values represent the User, Group, and World permissions set for files and folders on your web server. To learn more about WordPress and file permissions visit http://codex.wordpress.org/Changing_File_Permissions.

      These settings can help with certain hosting companies that use restrictive permissions for all user files. This will override the server settings and should allow WordPress updates and auto installations to work.

      The WP_CACHE option is required for some caching plugins to work. Enabling this option will include the file wp-content/advanced-cache.php. To enable this option, use the following code:

      WordPress has numerous constant options that you can set. There is a PHP function to view all constants currently set on your installation:

      An advanced option is forcing SSL on login to your WordPress site. This requires users to log in via the HTTPS access link and encrypts all data being transferred to and from your website. To activate SSL on login, add the FORCE_SSL_LOGIN option like so:

      Конец ознакомительного фрагмента.

      Текст предоставлен ООО «ЛитРес».

      Прочитайте эту книгу целиком, купив полную легальную версию на ЛитРес.

      Безопасно оплатить книгу можно банковской картой Visa, MasterCard, Maestro, со счета мобильного телефона, с платежного терминала, в салоне МТС или Связной, через PayPal, WebMoney, Яндекс.Деньги, QIWI Кошелек, бонусными картами или другим удобным Вам способом.

iVBORw0KGgoAAAANSUhEUgAABAEAAAAhCAYAAACoYLI9AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsIAAA7CARUoSoAAAAdoSURBVHhe7d0JkuI6DIBhTsJZOA0H4kzciyd5SWTHiyCdaV7n/6qoaiC2vBEUh5q5vAAAAAAAwCmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwEmwCQAAAAAAwElc7tfL63LRx/V1f8orz/vrGp7L4/aIR+FXPe/XNEfxwbT8HB3ba1j4b3jcvnce3mjbIX1P7+tjVPdvj/tH8X8In+ejPV/he+16l79OwPmZAwAAyC6Skb5ujcThcUubAvhlj9ftwGT2cbtJhM/tLf/Nhn2TxPtrL96ObpunfjnmkAsSR+zvXpPHfp5/03eN+/N1v51kEyA76jMHAAD+nEtISlNW/bitdxLKhE6OMXeu3rrDIomJvduV74LZZEXjLnVL3DJJ3hFb2V82yMOfJKW4V22PlpXxWOoqk92i/fa93Pe7bYOzrKjvGIZH1f/PY1fjmh7+i8dZ+fy+2UxKbYoPef