Jump to content
TNG Community

WP & TNG Histories


boonie67

Recommended Posts

Is there a reason why the history English & or French would not work in Word Press integration to TNG. It did however work at one time and now the pages are blank. Any changes? it works fine on the TNG site without integration. Would someone with WP & TNG integration please chime in here, this is only error remaining on site except for one small tab color on individual pages. Any help much appreciated and thanks for looking.

Link to comment
Share on other sites

Let me start by saying ooops sorry about that, Roger. They were made many years ago say 8 or so with the history template in without the body and then the body is in the English & French folders which allows switching languages. They worked awhile back on the integration, but don't know if the upgrade to TNG v11.1 did anything to it. It is a funny thing if I remove the integration and just have genealogy and wordpress in root they work fine. The pages are blank but colored however before one had to add font color at top of page if one wanted it. 

Attached is the template without body in the histories folder. The body of the English & French Versions are in their respective language folders. And this was how Ken explained it many years ago and it works great, except on integration. Could be some other updated part is needed now for it to work correctly. And thank you very much appreciate the reply. Thanks for heads up on Weaver Theme seems to work fine.

 

 

historyneige.php

Link to comment
Share on other sites

Randal,

Are you using $cms['tngpath'] as part of the include for the language specific page as in

	include($cms['tngpath'] . "$mylanguage/carignan_regiment.php");

 if so you may need to make sure the $cms[tngpath] is set correctly.

I don't use WP so I don't know what that value for the path should be.

Link to comment
Share on other sites

Hi Ken,

Yes I have the history templates in which the "include($cms['tngpath'] . "$mylanguage/historyneige.php");" without quotes, as all the histories I created have these included, except for one I made yesterday in tng administration. The file in the above previous post is attached and all work well our when running just tng. Can not figure this out it was working last week, even tried different wp themes, because not all themes are alike.

The histories I have created are from your instruction of 6 or 8 years ago and they work fine in tng. I have removed media block and you are welcome to view. All was working on wamp but now its throwing an error about header not sent for WP.

I Have looked at some wp site and see no language changes in history, even Kloosterman's site has two different menus one for English and one for Dutch. There has to be some sort of fix for this because it did work when I was in the trial mode. 

Any way thanks for the reply and feel free to go on our site and try the histories will leave all as it for most of the day.

Link to comment
Share on other sites

Sorry Randall,

I do not know anything about WP so I do not know if the $cms['tngpath'] needs to be updated to work correctly to find the language specific page

 

Link to comment
Share on other sites

Thanks Ken,

I thought if anyone would know it would probably be you, with your french on your own site. What about the new history template in tng v11 do you have that one in your site? 

Link to comment
Share on other sites

Try Updating the TNG Global Variables in the WordPress Admin ------> TNG area

Also if you edit the historyniege.php file to add

echo "cmstngpath = " . $cms['tngpath'];

before the line that includes the historyniege.php file, what value is printed out for $cms['tngpath']?

Roger

Link to comment
Share on other sites

Roger,

Let me resend you the attachment again so may view it and then maybe I could understand better. By the way I have removed block media so feel free to look into the history there isn't a block, it may give you an idea what is going on.

 

Link to comment
Share on other sites

Well integrating Kloosterman method is almost error free except for the histories switching to French and English. They were working couple weeks ago however it has stopped this week. It does load the page however it is blank.  There has to be some script to include that includes the page with the history selected. Using Weaver xtreme theme for now and seems to be all working correctly except for the history. Need someone versed in WP to help with this. I am a novice but shouldn't the tng part be called from tng and not WP? 

Question why would the histories work before and now they load blank pages? Could it be WP updated automatically? Grabbing at straws at the moment. Just wondering would the plugin work error free? I know that Roger has it installed. 

Thanks for looking and any help very much appreciated.

Link to comment
Share on other sites

Well, it is awful difficult to diagnose problems on sites that are locked down (require a user login).  Blank pages often mean that you have a syntax error   See Blank Pages on the TNG Wiki

If it was working before and now loads blank pages, it has to do with something you changes

Link to comment
Share on other sites

Ken,

I had sent a reply yesterday it was unlocked till afternoon if it would help it can be unlocked again. It has been locked since images, and data was taken and spread all over commercial sites. I will unlock it, but remember the histories did switch history before. The intro page and other pages still do change language, it is just the histories.

It is now unlocked till resolved and thanks, will look at blank pages, but I am a novice in syntax errors.

Link to comment
Share on other sites

I checked several history files for errors and no syntax errors detected in code, so back to square one. Why does it work our of WP and not integrated with it. All other change language work well, one example is the Home Page, I am wondering if the change language is necessary? Thanks for the help and feedback, very much appreciaed Ken.

Link to comment
Share on other sites

Looking at View Source, the page is truncated immediately after the </head> line.

When I look at View Source for https://ouracadianfamily.com/genealogy/browsemedia.php?mediatypeID=histories

there are 2 head sections.  Is that normal on WP sites?  Like I have said previously I know nothing about WP, so the WP experts will need to chime in

Link to comment
Share on other sites

Ken, Yes I will attach files.

Before you get started check the site now back to just tng no integration all the histories translate fine, send me a message & I will integrate back at your request.

 

 

 

Link to comment
Share on other sites

Interesting the the -en file is in French and not English.

Did you ever change the code to add the echo for the $cms['tngpath'] as requested by Roger in a prior post?  if so what was the path provided?

If not please add

On 3/22/2017 at 8:43 AM, theKiwi said:

echo "cmstngpath = " . $cms['tngpath'];

above line 21 in  the history/AcadianFamilies-source.php provided.  Interesting that this file is different name than what I tried to access earlier.

Link to comment
Share on other sites

17 minutes ago, boonie67 said:

Before you get started check the site now back to just tng no integration all the histories translate fine, send me a message & I will integrate back at your request.

Well, I am not sure that it is working since when I switch languages the page text remains in French.  Edited - Sorry, I only looked at the beginning and it appears to be French.

It is also difficult to trouble shoot when pages get changed from what they were.

Link to comment
Share on other sites

Ken,

After integrating wp and tng again, I quoted out header from source file and it is working now, will try others. 

I do not know on your site but on this one it stays on French or English in the histories until switched again.

Link to comment
Share on other sites

Randall,

 

2 minutes ago, boonie67 said:

After integrating wp and tng again, I quoted out header from source file and it is working now, will try others. 

what do you mean?

 

Link to comment
Share on other sites

When in the histories page and viewing all the history pages, switching on my site is done in the histories page. I cannot switch histories from the page I am viewing in English to French from that page.

Link to comment
Share on other sites

If you mean you removed the following line

<H1 align = "center" style = "text-align: center">
Mariages et Familles Cajun</h1>

<H1 align = "center" style = "text-align: center">
Mariages et Familles Cajun</h1>

then try changing all the HTML tags to be lower case only.  <H1 is not a valid tag.

Link to comment
Share on other sites

7 minutes ago, boonie67 said:

When in the histories page and viewing all the history pages, switching on my site is done in the histories page. I cannot switch histories from the page I am viewing in English to French from that page.

Did you comment out the tng_header call that generates the TNG page header and menu bar? 

I don't know what gets generated when you are not using a template.  As to whether the Language pull down is shown any place.

 

Link to comment
Share on other sites

All histories are working both languages now, but had to remove Roger's script, it produced an error and put back the script I had originally, $cms['tngpath'] = "../"; 

Just a note if you place wordpress in wamp it returns an error, just comment out the tng header. 

Thank you, much appreciated Ken and Roger.

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...