Jump to content
TNG Community

Confused about the tng/wp plugin install


John Paul

Recommended Posts

Reading the wiki on how to install WP and TNG using the plugin, I'm confused about where to put the wp and tng folders.  it says to put the wp folder in the root, but it also implies putting all the wp files/folders in the root so wp's index.php and .htaccess are in the root of your site.  to me this doesn't make sense.  here is a screenshot of my root folder on my localhost using xampp.  so on my localhost machine, http://localhost = the htdocs folder or http://mysite.com.  you'll see in the screenshot that i have a wp and tng folders there.  they are occupied but not installed yet until i am sure of what i'm doing.  I had wp and tng installed in separate folders previously and did step 2 of the wiki instructions. wp worked fine, but always got a blank page for tng then started getting tng cannot connect to the database errors.  so now i'm starting from scratch with fresh installs of both, BUT i want to know for sure if i have the folder structure correct.  Thanks.

htdocs.jpg

Link to comment
Share on other sites

Hi John,

I use xampp as well. My recommendation is to create a folder with your site name (e.g., myfamilytree). In THAT folder, put the wp and tng folders. Then you need to edit the apache httpd-vhosts.conf file located in xampp/apache/conf/extras folder. It should look something like this:

##<VirtualHost *:80>
    ##ServerAdmin webmaster@dummy-host.example.com
    DocumentRoot "C:/xampp/htdocs/myfamilytree"
    ServerName myfamilytree
    ##ServerAlias www.dummy-host.example.com
    ##ErrorLog "logs/dummy-host.example.com-error.log"
    ##CustomLog "logs/dummy-host.example.com-access.log" common
##</VirtualHost>

Now when you browse to http://localhost, you should see that site (right now all you will get is a folder listing).

  1. Point your browser to http://www.yourdomain.com/wp. Follow the onscreen instructions to create the configuration file and install WordPress. Once setup is complete, log in to the Admin Dashboard.
  2. In the sidebar Menu select Settings -> Permalinks. Set the permalink structure to anything but Default (I strongly recommend %postname%) and save changes.
    [NOTE: The plugin will NOT work with the Permalinks setting on Default.]
  3. Select Settings ->General. In the box for Site Address (URL), change the URL to the root level of your website (i.e. http://www.yourdomain.com). Be sure to include the http://. Do not try to view the front page yet – you will get an error message.
  4. Check the box for “anyone can register” and select the default level of Subscriber. You need this setting for integrated login to work.
    [NOTE: As of TNG 10.1, the integrated logins no longer work.]
  5. Using your FTP client, COPY ( not move) the index.php and .htaccess files from the WordPress folder to the root folder. If you can’t see the .htaccess file, check the settings in your FTP client to be sure the option to show hidden files is checked.
  6. Open the index.php file you copied to the root directory in a text editor and change the following line:
    require('./wp-blog-header.php'); to
    require('./[wordpress directory name]/wp-blog-header.php'); and save the file.
    NOTE: Do not make changes to the index.php file located in the /wordpress directory!

 

In TNG config, under Site Definition, home page is going to be the same as your sitename (yourdomain.com) and the TNG page is going to be the slug of the page you define in the plugin (e.g. yourdomain.com/genealogy). At that point, everything should work.

Link to comment
Share on other sites

Already did all that.  looks like i got it all working correctly, BUT still getting blank pages from tng..

notngpage.jpg

Link to comment
Share on other sites

Check your TNG config. Did you set up the urls correctly under site definition? For the full set of instructions I provide go here: http://www.uniquelyyourshosting.net/how-to-integrate-wordpress-with-tng/. Also, make sure that with the plugin you have updated the global variables. If you are still having issues, let me know. 

Link to comment
Share on other sites

in tng setup general site design, Home Page:  http://joneshyman/  Genealogy URL: http://joneshyman/genealogy/   (same as permalink on the Genealogy page in WP)

When clicking on the Genealogy page in WP theme, it's just blank  I've done everything correctly in the instructions, got the latest tng.php for the plugin, looks like all url's are correct, wp works great, just keep getting a blank page for tng.....

i update the variables after any change i make....

Edited by John Paul
added more info
Link to comment
Share on other sites

Okay... since I can't see your site, one suggestion is to find the mbtng-globalvariables row (or something like that -- the the tng plugin options begin with mbtng). Click on edit and look for a stray ,$, with nothing else. I'm not sure why that happens but sometimes it does. Delete that empty variable and then save the change. Do NOT update global variables again. Try loading the page again.

Link to comment
Share on other sites

no stray $ in tng.php  (i'm assuming thats the file you were talking about...)  Thank you for you time trying to help me out.  if you think of anything else to look for let me know.  right now I have a carolina gamecock football game to get ready to watch.

Link to comment
Share on other sites

I was actually talking about the database wp-options table, but that's okay. In the wp-options table of the database, you should find a row that is named mbtng_globalvars (or something like). THAT is where you need to look for the empty variable.

On the other hand, not to denigrate the plugin in any way, another option is to consider the Kloosterman method of integrating without the plugin. You can find the instructions here: http://www.kloosterman.be/info/how-i-made-my-tng-wp-website/

Link to comment
Share on other sites

didn't see a stray $ there either.  I've tested the kloosterman method and there's just way too much css editing for me.  well i am using a different theme now so maybe i'll try it again.  just not having any luck with either of these methods.  Thank you for your time trying to help me out.  i appreciate it a lot.

Link to comment
Share on other sites

jayat1familytree

Heather,  Why is the Sign in integration no longer working with TNG ver 10.1??

 

Link to comment
Share on other sites

It has something to do with the changes to the way TNG 10.1 connects to the database. You can see the original thread here: http://tng.community/index.php?/forums/topic/9976-fatal-error-after-101-update/ I reconfigured my user plugin to work independently of any other plugin so if you DO want integrated logins you can still do it. Since 10.1, I've switched to using Kloosterman's method of integration with great success.

Link to comment
Share on other sites

It has something to do with the changes to the way TNG 10.1 connects to the database. You can see the original thread here: http://tng.community/index.php?/forums/topic/9976-fatal-error-after-101-update/ I reconfigured my user plugin to work independently of any other plugin so if you DO want integrated logins you can still do it. Since 10.1, I've switched to using Kloosterman's method of integration with great success.

​That change - around line 1117, replacing instances of tng with mysql, worked for me.

	$link = @mysql_connect($database_host, $database_username, $database_password);
	if ($session_charset == 'UTF-8')
		@mysql_query("SET NAMES 'utf8'");
	if( $link && mysql_select_db($database_name, $link))
		return $link;

Good Luck

Link to comment
Share on other sites

Just let everyone here know, especially Heather, I actually completely reconfigured my local environment, got rid of xammp and installed 64bit wamp server 2.5, setup a virtual hosting environment, installed wp and tng as per the wiki instructions, and now it actually works!.  Now i can rest my mind on that and concentrate on setting the index.php page up as i'd like.  Again Thank you Heather for your time trying to help me out yesterday.  it did some good as far as today in concerned.

Link to comment
Share on other sites

jayat1familytree

Heather

 

Yea as Mahesh mentioned

 

$link = @mysql_connect($database_host, $database_username, $database_password);
	if ($session_charset == 'UTF-8')
		@mysql_query("SET NAMES 'utf8'");
	if( $link && mysql_select_db($database_name, $link))
		return $link;

 Needs to be like 

 

$link = @tng_connect($database_host, $database_username, $database_password);
	if ($session_charset == 'UTF-8')
		@tng_query("SET NAMES 'utf8'");
	if( $link && tng_select_db($database_name, $link))
		return $link;
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...