Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress From Bootstrap to WordPress Setup a Bootstrap Theme Setup Your WordPress Development Environment

Martina Carrington
Martina Carrington
15,754 Points

bootstrap

i was trying to installed the bootstrap on my Xampp and some reason i received this

Parse error: syntax error, unexpected '4' (T_LNUMBER), expecting ',' or ';' in C:\xampp\htdocs\index.php on line 3

Patrick Cooney
Patrick Cooney
12,216 Points

Can you post the code from your index.php file for us?

8 Answers

Martina Carrington
Martina Carrington
15,754 Points

i was following the video and place the bootstrap folder in the htdocs and i received error . i am using the apach

Martina Carrington
Martina Carrington
15,754 Points

@Patrick Cooney, thanks . i was looking at the code and realized it was missing

Patrick Cooney
Patrick Cooney
12,216 Points

Excellent. Glad that's fixed. I changed my comment to an answer so people know this has been answered.

Patrick Cooney
Patrick Cooney
12,216 Points

Is this the entire file? Do you have the closing ?>? I don't see any other obvious errors.

Martina Carrington
Martina Carrington
15,754 Points

yes , this come from the wordpress project folder and i copy it and place it in the bootstrap folder . located in the htdoc

Konrad Pilch
Konrad Pilch
2,435 Points

Good its solved :D i though you were doing something else :D i forogt Zac takes it from 0

Martina Carrington
Martina Carrington
15,754 Points

@Patrick Cooney

<?php
/**
 * Front to the WordPress application. This file doesn't do anything, but loads
 * wp-blog-header.php which does and tells WordPress to load the theme.
 *
 * @package WordPress
 */

/**
 * Tells WordPress to load the WordPress theme and output it.
 *
 * @var bool
 */
define('WP_USE_THEMES', true);

/** Loads the WordPress Environment and Template */
require( dirname( __FILE__ ) . '/wp-blog-header.php' );
Konrad Pilch
Konrad Pilch
2,435 Points

You were trying to activate bootstrap in your WordPress site ? Do you know well enoguh WP ? and did you work with PHP includes before ? How did you wanted to install it?

Martina Carrington
Martina Carrington
15,754 Points

Hey Konrad Pilch , i still have problem locating my database .

Konrad Pilch
Konrad Pilch
2,435 Points

What kind of database? your PHP MyAdmin?

Martina Carrington
Martina Carrington
15,754 Points

@Konrad pilch yes, it been created on PHP myAdmin but wordpress can't located the bootstraps_to_wp table.

Konrad Pilch
Konrad Pilch
2,435 Points

Are you making a WordPress Theme?

It needs to be in htdocs .
You need to downolad wordpress and put it in htdocs.
You need to go on themes and put your site there.
YOu need to create a database.
YOu need to install wordpress.
It should connect automatically .

Martina Carrington
Martina Carrington
15,754 Points

Konrad Pilch , yes .I am sorry if i sound very confusing lol

Konrad Pilch
Konrad Pilch
2,435 Points

So is it working now ? : p

Konrad Pilch
Konrad Pilch
2,435 Points

Are you back yet? xD