Jump to content
TNG Community

Search the Community

Showing results for tags 'code'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • TNG Specific
    • Announcements
    • Questions and Answers
    • Installation and Configuration
    • New Ideas and Suggestions
    • Code Discussion
    • Templates or Design Questions
    • CMS Integrations
    • TNG Wiki
  • Community
    • Member Webpages
    • Genealogy
    • Chit Chat
    • Questions and Answers
    • Offers And Requests

Blogs

  • Community News
  • TNG News

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Found 81 results

  1. I'm using template 13, v12.0.2. I see this code on the index.php page: <?php foreach( $mediatypes as $mediatype ) { if(!$mediatype['disabled']) { echo "<li><a href=\"browsemedia.php?mediatypeID={$mediatype['ID']}\">{$mediatype['display']}</a></li>\n"; } } ?> But, I don't see anywhere in admin how to "disable media types" so they don't appear among the list on my homepage? I can delete "reports," for instance, since that has its own line. But there are no lines here for histories, recordings, or videos. I'm sure I'm missing something obvious, but I can't find it. Can anyone tell me where this might be? homepage: https://buffalo.pitard.net/index.php
  2. I find it very useful and inspiring to see the design adaptions in the different member webpages. I am currently using template 12 - does anyone like to share their template 12 webpage? Thank you!
  3. My genealogy is integrated in a website and I would like to make a new link to "Home" of the website on all the pages. What is the best place and how do I do that? I did manage to make a new link on the homepage of TNG I am using TNG v. 12.02.2 Thank you for your help Muyz
  4. I just discovered...quite by accident, that TNG's 'Advanced Search' capability does not return any results for existence searches (the fact itself) on a broad range of custom events. My database has entries that contain the following custom events for which an EXISTS search fails to return any results: Adoption (ADOP) Naturalization (NATU) Emigration (EMIG) Immigration (IMMI) Residence (RESI) Cremation (CREM) And I believe that there are probably some others as well, but my testing hasn't been exhaustive. Conversely, some other events--'Also Known As (ALIA), 'Married Name' (_NAMM), and 'Degree' (DEGR), for example--seem to work fine. Is this a known issue? Anybody else experiencing this on TNG 12.0.2? (PHP 7.2, CentOS, MariaDB 5.5.56) Thanks, Bill Herndon Lindell-Herndon Genealogy
  5. Brian Yare

    PHPMailer end of life

    I have received a notification to say that " Outdated script detected on: (my web site) This is a notification that the PHPMailer installation in /htdocs/TNG on hosting account (my account), is end of life (version 5.2.22). End of life software is susceptible to vulnerabilities and bugs, which could result in your site being compromised. Please ensure you obtain and install the latest updates from the software vendor as soon as possible. Some of the scripts may be included as part of another software installation. Contact the vendor if you require further advice. Should the installed software remain out of date we may have no option but to suspend your web hosting service." What can I do to prevent losing my hosting service? Brian
  6. Hello, I'm running into an issue when attempting to display the custom event types in the administration of TNG 11.1.2. The query fails and returns this message: An error has occurred in the TNG software. This could be due to a setup issue, an incomplete upgrade or a program bug. If you are the site owner, you may contact TNG support for help with this problem. Please copy the query below and paste it into your message. Query: SELECT tng_eventtypes.eventtypeID, tag, description, display, type, keep, collapse, ordernum, count(eventID) as total_events FROM tng_eventtypes LEFT JOIN tng_events ON tng_eventtypes.eventtypeID = tng_events.eventtypeID GROUP BY eventtypeID ORDER BY tag, description LIMIT 50 MySQL server has gone away My database has many, many events and obviously the LEFT JOIN puts to much load on the MySQL server. A modified query that uses INNER JOIN works, but takes very long, and does not include those eventtypes that are not (yet) used, so it is not an acceptable solution. TNG version 10 did not do a LEFT JOIN for counting the events, so, this was not a problem in v10. Any ideas how to optimize the query to work / work fast? Thanks, Dietmar
  7. anderson.mc

    1900 Census Import Issue

    I have been importing multiple pages of census data for a couple of months now, no problems. Recently, I started having problems with importing 1900 census data. Using the same workflow I had been using, when I import the DOM I get the following table and data (see screenshot). I updated TNG to the latest v12.02. Upgraded Census Plus to the latest v12.0.0.7d. I still have the same problem. I deleted a previously imported 1900 DOM record, then reimported, and I had no issues. I have attempted to import about 6 different 1900 census DOM records and keep having the same problem. I imported a different year and had no issues. Does anyone have any experience with this? Is there something new about how Ancestry is handling 1900 DOM source files? Appreciate help from somebody who knows more than I do. Thank you.
  8. Without success from another source, I am posting here in hopes someone will tell me what I am doing wrong with the validation code AND answer the two questions at the end: I have added a field to the “newacctform.php” as follows (in the table) <tr><td valign="top"><?php echo $text['howrelate']; ?>*:</td><td><textarea cols="50" rows="4" name="howrelate"></textarea></td></tr> I have the text right and I believe everything else is correct. The form works fine until I go to try to “validate” the field. This is what (and where) I have currently: <script type="text/javascript"> function validateForm(form) { var rval = true; if( form.username.value.length == 0 ) { alert("<?php echo $text['enterusername']; ?>"); rval = false; } else if( form.password.value.length == 0 ) { alert("<?php echo $text['enterpassword']; ?>"); rval = false; } else if( form.password2.value.length == 0 ) { alert("<?php echo $text['enterpassword2']; ?>"); rval = false; } else if( form.password.value != form.password2.value ) { alert("<?php echo $text['pwdsmatch']; ?>"); rval = false; } else if( form.realname.value.length == 0 ) { alert("<?php echo $text['enterrealname']; ?>"); rval = false; } else if( form.<?php echo $_SESSION['tng_email']; ?>.value.length == 0 || !checkEmail(form.<?php echo $_SESSION['tng_email']; ?>.value)) { alert("<?php echo $text['enteremail']; ?>"); rval = false; } else if( form.em2.value.length == 0 ) { alert("<?php echo $text['enteremail2']; ?>"); rval = false; } else if( form.howrelate.value.length == 0 ) { alert("<?php echo $text['howrelatepop']; ?>"); rval = false; } else if( form.<?php echo $_SESSION['tng_email']; ?>.value != form.em2.value ) { alert("<?php echo $text['emailsmatch']; ?>"); rval = false; } return rval; } </script> I have tried to place the validation field in different locations but no matter where I put it, when I fill out the form and submit – I get the message that the “user name is already taken”. IF all I do is remove the validation statement, the form is working and submitting just fine, and everything works as designed. Is it possible to tell me where I am going wrong with the validation? Second – once I get this working, where do I need to go to tell the submittal to include the newly added field information when I go to review the new user. And finally, as an extra bit of question – When an error occurs such as “password does not match” an alert is generated which may be java script but I'm not certain. Where can I find this alert so I can change the part at the top that now says “my website name” – for example, your password doesn’t match or any other error has occurred.
  9. Bruce Roy

    Map pins do not show

    Having installed and then uninstalled Open Street Map, I find that my map pins did not show in OSM and now do not show with Google maps reinstalled. There is a "Link to Google Maps" where the pins should be. The link opens a new tab in google.com/maps. The map pins are in the img folder - they just don't show on the web page. Checking in Firefox/Web Developer/Console I get this message: uncaught exception: InvalidValueError: initMap is not a function Any advice appreciated. Bruce Roy https://royroyes.net
  10. Hello all, You can now make your menu selection restricted to logged-in users using a new parameter: https://tng.lythgoes.net/wiki/index.php?title=Custom_Menu_Hook#Logged_in_users // Custom menu $custommenulinks[$link_nr]['user'] = true; // Find menu $findmenulinks[$link_nr]['user'] = true; // etc It works the same way as the Admin parameter. The main reason for this is that it's recommended that the menu hook is added in customconfig.php but when that file is read, $currentuser is not known. Up to and including TNG v12.0.2 you have to use a very small mod that is found at the Custom Menu Hook page. Copy-and-paste. (Link above) I have today confirmed that the genlib.php file Darrin sent to me works, with the modification included, so it looks like it's a part of TNG from the next update. Enjoy! Erik
  11. Thanks to sterling efforts by Roger and Erik, my maps now appear where they should. But I still have a problem. When I select a map marker in a person's page, I think what is supposed to happen is that the map zooms in to that location. But when I select a marker it opens a new window with Google Maps, which searches for the coordinates for a place but decides to identify with a place name sometimes different from my record (but in the vicinity). Example: https://royroyes.net/getperson.php?personID=I916&amp;tree=rr_tree
  12. pdwight

    'Notes" link not working. Ver 12.02

    'Notes' for all Notes (General, Birth, Marriage etc,) for person is not working whether there is data in the section or not - any ideas? Data got in the Notes by import but can not get at the data. Gives me a different website. Also under Admin, Cemeteries Link. Can not display my website yet, working on it.
  13. I have released Citation Master versions 11.0.0.8 (TNG 11.0) , 11.1.0.8 (TNG 11.1), and 11.1.2.8 (TNG 11.1.2). This is a major update that adds: Formatted page references--Generated by getperson.php and suitable for copying by other genealogists. (Requested by Darryl Brady, Brian Larson, and Mark Middleton.) A new configuration file for the APA format, and updates to all other configuration files for the new page reference feature. The ability to prepend and append text to citation/source fields. (Requested by a few users who would like to add labels like 'Page:' to certain fields.) The ability to turn Citation Master's formatting engine on/off for citations, sources, references--controlled by mod parameters. (Requested by Darryl Brady and Bill Desjardin.) A new formatting instruction for inserting HTML breaks. (Requested by Ken Roy.) Improvements to the formatting engine's algorithm that eliminate some extra spacing that crept into sources and citations. Internationalization for 12 languages. In addition, the Citation Master Wiki page has been extensively updated to cover all the current features and provide additional examples and instructions on use. This version is recommended for all TNG 11 Citation Master users. Happy to help with any fine tuning of the configuration files. Bill Herndon Lindell-Herndon Genealogy
  14. I'm using Template 14 in TNG v12.0.1. Emails are not being sent from "Contact Us", "Suggest", or "New Account Requests". I followed the guidance in the wiki to set Send all mail from address above: to Yes because I am not getting emails, but I still get the following error: Fatal error: Uncaught exception 'phpmailerException' with message 'SMTP Error: Could not authenticate.' in /public_html/class.phpmailer.php:1692 Stack trace: #0 /public_html/class.phpmailer.php(1540): PHPMailer->smtpConnect(Array) #1 /public_html/class.phpmailer.php(1335): PHPMailer->smtpSend('...') #2 /public_html/class.phpmailer.php(1213): PHPMailer->postSend() #3 /public_html/tngmaillib.php(53): PHPMailer->send() #4 public_html/addnewacct.php(144): tng_sendmail('...') #5 {main} thrown in public_html/class.phpmailer.php on line 1692 I can send and receive emails from the account directly without a problem. Does anyone have a recommendation as to how to fix this?
  15. I'm interested in trying to enable "responsive fonts" in the template footer. When viewing in a mobile device, including iPad and iPad pro, while everything else on the page IS responsive, the text inside the footer is not and will not resize the font. Any suggestions appreciated. Larry
  16. So many questions - but progress is being made... When someone submits a "user registration request", Admin gets an email saying go to your Admin to Review. Once you approve the request, you have the option to send an email to the user notifying them that their account is active. In this block, the admin can type out a custom message to the new user BUT there is a built-in message somewhere. Either I'm getting too old or I just can't see anymore but - would someone kindly point me to where I can change the default text in that reply - Thanks L
  17. Bruce Roy

    Most Wanted issues

    I find that I cannot add/edit/delete Most Wanted entries - actually I can edit but cannot save the edited version. Bruce Roy roy-royes.net
  18. LJLachance

    Template 13 V12 - et al

    Again, Template 13, but I suspect this question would apply to any template. I want to remove the "register for new account" link and form from the index page in its entirety and republish it on a separate web page (same public html hierarchy but outside TNG). First I need to know how (from where) to remove the standard link and replace it with a link to "the other page" outside TNG, then I need to know how to link back to the "register form" inside TNG. (Where is this form?) I know how to make links, just not where to find these two pieces in V12. Thanks
  19. With Version 12 I am using/customizing Template 13 (a pre-V12 template). At the top of the index page is a nav bar image (nav.png I believe). The behavior for this image is defined in .artnav in the css for this template. I'd like to find someone who might know the css syntax to enable this image/nav bar to be responsive. Under usual circumstances I would simply have a ".responsive" statement but how to add this for this template is above my skill level. The reason for this request is that while everything else seems to resize just fine (whether using breakpoints or otherwise), this image does not, causing it to deploy in two sections at lower resolutions 480 or less. Anybody with ideas please let me know. Thanks
  20. wkenddad

    Layout of media change

    I have several people with Yearbook Entries I link the Jpegs of each page to a "Education" Event. When the persons page displays these Jpegs are in rows. is it possible to have these items display as columns in a single row or a table of 1 x 4 or 2 x 2? Or even better a MOD that allows several Items to be linked in a table format and that table be linked to the event. P.S. Is there anyway to have them display in order A-Z versus order of entry?
  21. Edit: find latest update at the end of this thread. -- Hi, if someone is interested, I just created the following code to have a link to FamilySearch-Search on any Person's page. It's quick and dirty, as I don't know PHP at all. If you want to make an addon out of it, please do so diff --git a/getperson.php b/getperson.php index 11c4126..1abc8b1 100644 --- a/getperson.php +++ b/getperson.php @@ -154,6 +154,21 @@ echo tng_DrawHeading( $photostr, $namestr, getYears( $row ) ); setEvent( array( "text"=>$text['born'], "fact"=>$stdex['BIRT'], "date"=>$row['birthdate'], "place"=>$row['birthplace'], "event"=>"BIRT", "entity"=>$personID, "type"=>"I" ), $row['birthdatetr'] ); setEvent( array( "text"=>$text['christened'], "fact"=>$stdex['CHR'], "date"=>$row['altbirthdate'], "place"=>$row['altbirthplace'], "event"=>"CHR", "entity"=>$personID, "type"=>"I" ), $row['altbirthdatetr'] ); } + // JPT search Familysearch + $searchparam="https://familysearch.org/search/record/results"; + $searchparam.="?count=20"; + $searchparam.="&query="; + + if( $row['firstname'] ) $searchparam.="%2Bgivenname%3A". $row['firstname']."~"; + if( $row['lastname'] ) $searchparam.="%20%2Bsurname%3A". $row['lastname']."~"; + if( $row['birthplace'] ) $searchparam.="%20%2Bbirth_place%3A".$row['birthplace']."~"; +// TODO if( ) $searchparam.="%20%2Bbirth_year%3A".$row['birthdatetr']."-".$row['birthdatetr']."~"; + if( $spouserow['firstname'] ) $searchparam.="%20%2Bspouse_givenname%3A".$spouserow['firstname']."~"; + if( $spouserow['lastname'] ) $searchparam.="%20%2Bspouse_surname%3A". $spouserow['lastname']."~"; + + setEvent( array( "text"=>"Search", "fact"=>"<a href=$searchparam target=\"_blank\">Familysearch</a>")); + if ( $row['sex'] == "M" ) { $sex = $text['male']; $spouse = "wife"; $self = "husband"; $spouseorder = "husborder"; }
  22. Problem with eventdate, eventdatetr and eventplace being empty during import I have imported a gedcom file into TNG. Now I noticed that on an individuals page the events like BIRTh, OCCUpation, RESIdence, EDUCation and DEATh are neatly presented in chronological order. However the events that have the tag "EVEN" in the admin's Custom Event Types pages are presented on the individual's page in a random order. So I looked in the tng_events table and noticed that the columns eventdate and eventplace are empty and eventdatetr is set to a default value of "0000-00-00" for all rows that contain the tag EVEN. I checked the file gedimport_misc.php contains this piece of code: $query = "INSERT INTO $events_table (eventtypeID, persfamID, eventdate, eventdatetr, eventplace, age, agency, cause, addressID, parenttag, info, gedcom) VALUES(\"$eventtypeID\", \"$persfamID\", \"" . $eventptr['DATE'] . "\", \"" . $eventptr['DATETR'] . "\", \"" . $eventptr['PLAC'] . "\", \"" . $eventptr['AGE'] . "\", \"" . $eventptr['AGNC'] . "\", \"" . $eventptr['CAUS'] . "\", \"" . $eventptr['ADDR'] . "\", \"" . $eventptr['parent'] . "\", \"$eventinfo\", \"$tree\")"; I then put in some echo statements and concluded that during import the variables $evendate , $eventdatetr, $eventplace are empty. One can change and update those events using the Edit Existing Person , Other Events table, but this seems a bit cumbersome as I have hundreds of those events. My question, has anyone seen this behaviour and more important, has anyone got a solution for me? Thanks Jan Wessel P.s. I did send an email to Darrin some weeks ago, but have not had a reply from him yet.
  23. During export via Gedcom from Legacy 9.0, I'm having trouble transferring geo-codes to TNG. I have examined the Gedcom-files, but cannot find latitudes or latitudes in the file ( and of course they are not shown in TNG after import, either). I have tried different sets of setups from Legacy (Legacy file and Gedcom 5.5), but when I examine the Gedcom-files, none of these have info on geo coordinates. If anyone out there can help a panicking Norwegian, I would greatly appreciate your feedback! Best regards Morten
  24. Masterhistorian

    New user: Temp 15 Error

    I am very new but Iam learning as i go. I was in admin setup and the whole right sidebar and underneath main photo just vanished. I t at the time messing with anything. I've compared index, and other files and they all match up. Ideas on what could have happened? Also were would I go to add background image to entire site. and would this be the appropriate code Background-image:url (); for the body
  25. Renze

    Google Adsense

    Anyone have experience with Google AdSense? Anyone have any tips where I should post the code? Is that in Getperson. php or somewhere else. Who can help? Would like to place an advertisement before Google Maps starts on the personal page
×