Title: Parse error &#8211; unexpected T_String
Last modified: August 19, 2016

---

# Parse error – unexpected T_String

 *  [janec88](https://wordpress.org/support/users/janec88/)
 * (@janec88)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/)
 * Have justed installed Version 2.6.3 and had the following error message come 
   up:
    Parse error: parse error, unexpected T_STRING in e:\inetpub\esvc000210\blog\
   wp-config.php on line 4
 * I have removed all ” and ‘ marks as per an earlier post with no success.
 * Any ideas?

Viewing 9 replies - 1 through 9 (of 9 total)

 *  [wpbct7](https://wordpress.org/support/users/wpbct7/)
 * (@wpbct7)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-899995)
 * Please post here the code on line 4 and few lines around it.
 *  Thread Starter [janec88](https://wordpress.org/support/users/janec88/)
 * (@janec88)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-900007)
 * FOURTH LINE OF 1ST PARAGRAPH IN wp-config
 * define(‘DB_HOST’, ‘localhost’); // 99% chance you won’t need to change this value
 * OR
    Define (AUTH_KEY … is the beginning of the fourth line 2nd paragraph:
 * // Change each KEY to a different unique phrase. You won’t have to remember the
   phrases later,
    // so make them long and complicated. You can visit [http://api.wordpress.org/secret-key/1.1/](http://api.wordpress.org/secret-key/1.1/)//
   to get keys generated for you, or just make something up. Each key should have
   a different phrase. define(AUTH_KEY (l\yOgw<=:MIPb7 (i~FK}<CPQt>_0}/F+)QG%GvK8I0fltu
   =zvI[If,Sk(r\s); // Change this to a unique phrase. define(SECURE_AUTH_KEY u!
   =\ZoPZkYQU@qPr2QFKLE5\\Q|rWTmH1(>R6UDekik8}AIU&ecM./RWsjX$z&#); // Change this
   to a unique phrase. define(LOGGED_IN_KEY u)$p,R_Kh*Hie=R#0z+2NFD\n/\)CHdc-9{N0jbDG
   |!#=$/FoVp~N46k@@$=); // Change this to a unique phrase.
 *  [wpbct7](https://wordpress.org/support/users/wpbct7/)
 * (@wpbct7)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-900048)
 * The “define” syntax:
 * `define(name, value);`
 * where name is name of the constant (SECURE_AUTH_KEY, LOGGED_IN_KEY, etc.) and
   value is number or string value, or PHP expression: 1, ‘test’, 1 + rand(), $another_var,
   etc.
 * So you need to change the code as follows (add comma and quotes around the text):
 *     ```
       define(AUTH_KEY, '(l\yOgw<=:MIPb7 (i~FK}<CPQt>_0}/F+)QG%GvK8I0fltu=zvI[If,Sk(r\s');
       define(SECURE_AUTH_KEY, 'u!=\ZoPZkYQU@qPr2QFKLE5\\Q|rWTmH1(>R6UDekik8}AIU&ecM./RWsjX$z&#');
       define(LOGGED_IN_KEY, 'u)$p,R_Kh*Hie=R#0z+2NFD\n/\)CHdc-9{N0jbDG|!#=$/FoVp~N46k@@$=');
       ```
   
 * (but please change the keys so they are public now 🙂 )
 *  [MichaelH](https://wordpress.org/support/users/michaelh/)
 * (@michaelh)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-900112)
 * Visiting [http://api.wordpress.org/secret-key/1.1/](http://api.wordpress.org/secret-key/1.1/)
   provides you a set of uniquely generated values you can copy and paste directly
   into wp-config.php
 *  Thread Starter [janec88](https://wordpress.org/support/users/janec88/)
 * (@janec88)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-900163)
 * I have tried the generated values from [http://api.wordpress.org/secret-key/1.1/](http://api.wordpress.org/secret-key/1.1/)
   twice with no luck. I have also tried the suggestion from Member wpbct7. Below
   is the current codes as follows. When I go to re try to install through Explorer
   it comes back with the error message instantly.
 * <?php
    // ** MySQL settings ** // define(‘DB_NAME’, “****”); // The name of the
   database define(‘DB_USER’, ‘****’); // Your MySQL username define(‘DB_PASSWORD’,‘****’);//…
   and password define(‘DB_HOST’, ‘localhost’); // 99% chance you won’t need to 
   change this value define(‘DB_CHARSET’, ‘utf8’); define(‘DB_COLLATE’, ”);
 * // Change each KEY to a different unique phrase. You won’t have to remember the
   phrases later,
    // so make them long and complicated. You can visit [http://api.wordpress.org/secret-key/1.1/](http://api.wordpress.org/secret-key/1.1/)//
   to get keys generated for you, or just make something up. Each key should have
   a different phrase. define(AUTH_KEY, ‘S1khIrv4@0/9rm#ppmx]~Ed1%4]3L8R6pm=A$E!}
   iC3[CfYh@vl@J<~\\bcsEq~s’); define(SECURE_AUTH_KEY, ‘_r9b08x<GP~\’c$_}Gtt=<-{
   BNS13%\sudPkL:BlSh]SDkcA*2UEMGAxj~\lccw7Bj\’); define(LOGGED_IN_KEY, ‘K]n!^WOQi(
   tho4[5~\o[34(r?30L?rS_mBLF36bUe!usuu(30#pl]eAcqo2KH?d?F’);// Change this to a
   unique phrase.
 * // You can have multiple installations in one database if you give each a unique
   prefix
    $table_prefix = ‘wp_’; // Only numbers, letters, and underscores please!
 * // Change this to localize WordPress. A corresponding MO file for the
    // chosen
   language must be installed to wp-content/languages. // For example, install de.
   mo to wp-content/languages and set WPLANG to ‘de’ // to enable German language
   support. define (‘WPLANG’, ”);
 * /* That’s all, stop editing! Happy blogging. */
 * if ( !defined(‘ABSPATH’) )
    define(‘ABSPATH’, dirname(__FILE__) . ‘/’); require_once(
   ABSPATH . ‘wp-settings.php’); ?>
 *  [whooami](https://wordpress.org/support/users/whooami/)
 * (@whooami)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-900165)
 * sigh, do this:
 * go get a clean wp-config.php
 * make those 3 lines look like this:
 *     ```
       define('AUTH_KEY', ''); // Change this to a unique phrase.
       define('SECURE_AUTH_KEY', ''); // Change this to a unique phrase.
       define('LOGGED_IN_KEY', ''); // Change this to a unique phrase.
       ```
   
 * all you have done is removed the: _put your unique phrase here_ from each line.
 * Notice thats what is left is one pair of single quotes. Your key(s) needs to 
   go inside those single quotes, and should not contain any single or double quotes
   of it’s own.
 * I would suggest putting your cursor in the middle of the quotes and just typing
   randomly, avoiding both quotes keys.
 * aka:
 * kwelkfmsxpoj54mpoiU)*(&()JI
 *  [moshu](https://wordpress.org/support/users/moshu/)
 * (@moshu)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-900167)
 * Hmmm… the problem is that everybody accepted that the 4th line was whatever the
   OP thought it was, although it is obvious that s/he has no clue about it.
    In
   the code posted above line #4 is: `define('DB_USER', '****'); // Your MySQL username`
   There is no script that would count lines **by paragraphs**, as the OP posted!!!
 *  [whooami](https://wordpress.org/support/users/whooami/)
 * (@whooami)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-900175)
 * i didnt assume that. her key stuff was wrong though in her original paste, and
   as thats where she’s at now, thats what I answered. 🙂
 *  [wpbct7](https://wordpress.org/support/users/wpbct7/)
 * (@wpbct7)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-900198)
 * In PHP string the \ character prevent the ‘ character from being treated as string
   end. So the following code is incorrect:
 * `define(SECURE_AUTH_KEY, '_r9b08x<GP~\'c$_}Gtt=<-{BNS13%\sudPkL:BlSh]SDkcA*2UEMGAxj
   ~\lccw7Bj\');`
 * You need to remove last \ from the string:
 * `define(SECURE_AUTH_KEY, '_r9b08x<GP~\'c$_}Gtt=<-{BNS13%\sudPkL:BlSh]SDkcA*2UEMGAxj
   ~\lccw7Bj');`

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Parse error – unexpected T_String’ is closed to new replies.

## Tags

 * [parse-error](https://wordpress.org/support/topic-tag/parse-error/)

 * In: [Installing WordPress](https://wordpress.org/support/forum/installation/)
 * 9 replies
 * 5 participants
 * Last reply from: [wpbct7](https://wordpress.org/support/users/wpbct7/)
 * Last activity: [17 years, 7 months ago](https://wordpress.org/support/topic/parse-error-unexpected-t_string-1/#post-900198)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
