Now that this plugin has been closed, anyone interested in a family tree solution for WordPress is recommended to try TreePress https://www.ads-software.com/plugins/treepress/
]]>Any inspiration?
https://foo.com/wordpress/wp-admin/post-new.php
When I click Family tree under category, I don’t see any fields.
I’m wondering if I have forgotten how to use this? ??
I just found a simple solution to change the outer border box size in which is displayed the family tree.
Edit the file:
(WordPress Dir)/wp-content/plugins/wp-family-tree/styles.css
I only removed (did a comment on) the “width” value and now the width is automatic set perfectly depending on the screen size.
#borderBox {
position:relative;
border:1px solid grey;
width:/*630px*/;
height:630px;
overflow:hidden;
}
Hope this works also for you.
Cheers
]]>Is there a way to change the size of the box the family tree is displayed in? Where is the CSS and how can I access it?
]]>Hello,
Can you look at Khajehfatolah.com. He had three wives (or was married three times) and children from different wives. when I entered the wives and children the display is screwed up. Please take a look and advise.
Thanks,
Jamshid
I am having some trouble with the plugin, doesn′t let me grow and can′t go to pro. Will you update your information, your website, give support?
]]>is it any way to buy the pro version? +why your site is down?
]]>Is it possible to import family histories from any desktop programs?
]]>Wanted to check out the premium version, especially because of the extended family but noticed that your website is down and I have no other way to contact you.
]]>I have the following error when I try to publish family members.
How could I fix this?
Thank you.
Warning: fopen(/home/xxx/public_html/xxx.com/wp-content/plugins/family-tree//family_data/family_84.json) [function.fopen]: failed to open stream: No such file or directory in /home/xxx/public_html/xxx.com/wp-content/plugins/family-tree/includes/custom-meta-box.php on line 466
Cannot open file (/home/xxx/public_html/xxx.com/wp-content/plugins/family-tree//family_data/family_84.json)
]]>
The Tree Nav Link (tree image) on shows under the blog link (book image); therefore the names overlap the Tree Nav Link. In your screenshot the 2 links are side by side and the name under them… That would be ideal but not what I have.
]]>Hello guys. I installed the plugin but it is not showing up in the WordPress dashboard. Does anyone have any idea how can I fix this?
]]>https://www.morriscollection.librarycompany.org/family_tree/william-gibbons-rhoads-jr/
Why can we not see the family tree?
Nicole
]]>Having a problem figuring out where to add the root code. THanks.
]]>Hey there. I was wondering if there was a way to hide the featured image on a post for a family member but still have it show when I hover over the name on the family tree.
]]>Sorry to ask how to actually create the family tree? I have “family-tree” slug and created father & mother posts but have no idea how to generate a tree. Any help is greatly appreciated. Thank you.
]]>The top-most entry should be ‘John Doe’. The following posts have John Doe set as Mother: Vito Danisi, Eugenia Grumo, Giuseppe Sangirardi, and Angela Sblano.
I have a page called ‘Family Tree’ that contains [family-tree]. In WP Family Tree Options, I set ‘Link to page with family tree’ to /family-tree/
In Firefox, I shows John Doe as the root, but it draws a lot of duplicates, some overlapping.
In Chrome, the root starts with Vito Danisi and Eugenia Grumo. Not clear why.
I have provided screenshots:
]]>when i check it on my mobile it will not response. the width is still
very big
i get an error on my family tree page:
Warning: Illegal string offset ‘root’ in /homepages/22/d533421493/htdocs/wordpress/wp-content/plugins/wp-family-tree/family-tree.php on line 364
how can i fix it
]]>Hello,
I use the plugin WP Family Tree that matches as I want.
It works well, except for the page that displays the list of members –> I get an error message at the top of page: “Warning: Illegal string offset ‘root’ in C: \ wamp \ www \ xxxxxx \ wp-content \ plugins \ wp-family-tree \ family-Tree.php on line 373“
(I tried locally or online, it’s the same.)
Content normally appears below the message, but it’s embarrassing.
I looked at the family-Tree.php file on line 373: I see nothing wrong, but I’m not an expert coding.
Could you help me to remove this error message? Thank you in advance.
]]>Hi there… this is an awesome plugin, but as I’m still a rookie in the coding department, I was wondering how one would change the color and size of boxes that your family member’s names/dob are in?
]]>I’ve got everything else working, it’s a pretty easy plug in to get up and running (thanks!), but I can’t seem to get the roll over images to work. My family tree displays correctly, but I don’t see a camera icon. If I click on an individual and see their detailed information, I see the image loaded for them, but not on the tree view.
Sorry if this has been asked before, i looked through the list of topics and didn’t see it.
Thanks for any assistance.
]]>Hi – first, thank for this plug-in, which is a nice addition to our family website…
For several reasons, I prefer to have family members as Pages rather than Posts – and for the most part the plug-in handles this fine.
The only problem is in editing: the drop-down lists to link family members are empty, as they only look for Posts (get_posts() function used in family-tree.php, line 211)
To cure this, I have appended the condition “&post_type=any” to the query, and this works a treat, i.e.
line 211: $family = get_posts('category_name='.wpft_options::get_option('family_tree_category_key').'&numberposts=-1&orderby=title&order=asc&post_type=any');
Any chance of making this a more permanent feature of the plugin?
]]>I’m using the latest version of WP Family Tree, now I found out that a cousin marriage is still not supported. I found a support entry that is unanswered for a year and closed.
Can I hope that this bug will be fixed?
Here is the old support entry with a good example:
https://www.ads-software.com/support/topic/plugin-wp-family-tree-mariage-between-first-degree-cousins
How can i change color of thumbnail if i want Gender Male to be in red and female being green ?
]]>I’m not sure where I am getting double entries from?
On the right side of the 3rd level of the tree at: https://sabafamily.net/weblog/family-tree/ There are double entries. Not sure where it is getting the duplicate data.
Actually where is it reading the data from, many of the entries are not in the “Family” category so I’m not sure how they are showing up? ged file maybe? I can’t find my notes and it has been over a year since I’ve had time to work on the site.
Any assistance appreciated.
]]>In spite of this amazing plugin’s last update on 2013-11-18, why it is not compatible up 3.8?
Please make it compatible?
Thanks.
]]>I’m getting an error message on this page where I use the [family-tree] shortcode.
https://family2remember.us/family-tree-2/
Please help – I have no idea what to do. Here are some more details:
The entire error message is:
Warning: Illegal string offset ‘root’ in /home2/hookon/public_html/FAMILY2REMEMBER.US/wp-content/plugins/wp-family-tree/family-tree.php on line 364
Line 364 is:
$root = $atts[‘root’];
Here is the entire PHP file:
]]><?php
/**
* @package WP Family Tree
* @author Arvind Shah
* @version 1.0.5
*/
/*
Plugin Name: WP Family Tree
Plugin URI: https://www.wpfamilytree.com/
Description: Family Tree plugin
Author: Arvind Shah
Version: 1.0.5
Author URI: https://www.esscotti.com/Copyright (c) 2010 – 2013 Arvind Shah
WP Family Tree is released under the GNU General Public
License (GPL) https://www.gnu.org/licenses/gpl.txt*/
require_once(‘wpft_options.php’);
require_once(‘class.node.php’);
require_once(‘class.tree.php’);/* Render a list of nodes. */
function family_list() {wpft_options::check_options();
$the_family = tree::get_tree();
$html = “”;
// Print information about each family member…
foreach ($the_family as $fm) {
$html .= $fm->get_html($the_family);
$html .= ‘<hr>’;
}
return $html;
}/* Render the tree. */
function family_tree($root=”) {
$the_family = tree::get_tree();
$out = ”;
$ancestor = ”;if (!empty($_GET[‘ancestor’])) {
$ancestor = $_GET[‘ancestor’];
} else {
if (!empty($root)) {
$ancestor = $root;
} else {
$node = reset($the_family);
$ancestor = ($node!==false)?$node->post_id:’-1′;
}
}if (!is_numeric($ancestor)) {
// find post by post title and assigns the post id to ancestor
$ancestor = tree::get_id_by_name($ancestor, $the_family);
}$render_from_parent = true;
if ($render_from_parent) {
$node = tree::get_node_by_id($ancestor, $the_family);
if (!empty($node->father)) {
$ancestor = $node->father;
} else if (!empty($node->mother)) {
$ancestor = $node->mother;
}
}$out .= “<script type=’text/javascript’>”;
// Generate javascript tree text…
$tree_data_js = “var tree_txt = new Array(\n”;
$the_family = tree::get_tree();
$first = true;
foreach ($the_family as $node) {
if (!$first) {
$tree_data_js .= ‘,’.”\n”;
} else {
$first = false;
}
$str = ‘”EsscottiFTID=’.$node->post_id.'”,’.”\n”;
$str .= ‘”Name=’.addslashes($node->name).'”,’.”\n”;
if ($node->gender==’m’) {
$str .= ‘”Male”,’.”\n”;
} else if ($node->gender==’f’) {
$str .= ‘”Female”,’.”\n”;
}
$str .= ‘”Birthday=’.$node->born.'”,’.”\n”;
if (!empty($node->died) && $node->died != ‘-‘) {
$str .= ‘”Deathday=’.$node->died.'”,’.”\n”;
}if (isset($node->partners) && is_array($node->partners)) {
foreach ($node->partners as $partner) {
if (is_numeric($partner)) {
$str .= ‘”Spouse=’.$the_family[$partner]->post_id.'”,’.”\n”;
}
}
}$str .= ‘”Toolbar=toolbar’.$node->post_id.'”,’.”\n”;
$str .= ‘”Thumbnaildiv=thumbnail’.$node->post_id.'”,’.”\n”;$str .= ‘”Parent=’.$the_family[$node->mother]->post_id.'”,’.”\n”;
$str .= ‘”Parent=’.$the_family[$node->father]->post_id.'”‘;
$tree_data_js .= $str;
}
$tree_data_js .= ‘);’.”\n”;
$out .= $tree_data_js;
// End generate javascript tree text.// $out .= ‘AddOnload(add_drag);’.”\n”;
$out .= ‘BOX_LINE_Y_SIZE = “‘. wpft_options::get_option(‘generationheight’).'”;’.”\n”;
$out .= ‘canvasbgcol = “‘. wpft_options::get_option(‘canvasbgcol’).'”;’.”\n”;
$out .= ‘nodeoutlinecol = “‘.wpft_options::get_option(‘nodeoutlinecol’).'”;’.”\n”;
$out .= ‘nodefillcol = “‘. wpft_options::get_option(‘nodefillcol’).'”;’.”\n”;
$out .= ‘nodefillopacity = ‘.wpft_options::get_option(‘nodefillopacity’).’;’.”\n”;
$out .= ‘nodetextcolour = “‘.wpft_options::get_option(‘nodetextcolour’).'”;’.”\n”;
$out .= ‘setOneNamePerLine(‘.wpft_options::get_option(‘bOneNamePerLine’).’);’.”\n”;
$out .= ‘setOnlyFirstName(‘.wpft_options::get_option(‘bOnlyFirstName’).’);’.”\n”;
$out .= ‘setBirthAndDeathDates(‘.wpft_options::get_option(‘bBirthAndDeathDates’).’);’.”\n”;
$out .= ‘setConcealLivingDates(‘.wpft_options::get_option(‘bConcealLivingDates’).’);’.”\n”;
$out .= ‘setShowSpouse(‘.wpft_options::get_option(‘bShowSpouse’).’);’.”\n”;
$out .= ‘setShowOneSpouse(‘.wpft_options::get_option(‘bShowOneSpouse’).’);’.”\n”;
$out .= ‘setVerticalSpouses(‘.wpft_options::get_option(‘bVerticalSpouses’).’);’.”\n”;
$out .= ‘setMaidenName(‘.wpft_options::get_option(‘bMaidenName’).’);’.”\n”;
$out .= ‘setShowGender(‘.wpft_options::get_option(‘bShowGender’).’);’.”\n”;
$out .= ‘setDiagonalConnections(‘.wpft_options::get_option(‘bDiagonalConnections’).’);’.”\n”;
$out .= ‘setRefocusOnClick(‘.wpft_options::get_option(‘bRefocusOnClick’).’);’.”\n”;
$out .= ‘setShowToolbar(‘.wpft_options::get_option(‘bShowToolbar’).’);’.”\n”;
$out .= ‘setNodeRounding(‘.wpft_options::get_option(‘nodecornerradius’).’);’.”\n”;if (wpft_options::get_option(‘bShowToolbar’) == ‘true’) {
$out .= ‘setToolbarYPad(20);’.”\n”;
} else {
$out .= ‘setToolbarYPad(0);’.”\n”;
}
$out .= ‘setToolbarPos(true, 3, 3);’.”\n”;
$out .= ‘setMinBoxWidth(‘.wpft_options::get_option(‘nodeminwidth’).’);’.”\n”;$out .= ‘jQuery(document).ready(function($){‘.”\n”;
$out .= ‘ add_drag();’.”\n”;
$out .= ‘ familytreemain();’.”\n”;
$out .= ” var midpos = $(‘#familytree svg’).width()/2 – $(‘#borderBox’).width()/2;”.”\n”;
$out .= ” $(‘#dragableElement’).css(‘left’, -midpos);”.”\n”;
$out .= ‘});’.”\n”;$out .= ‘</script>’;
/*
setDeath = function(bState)
*/
$out .= ‘<input type=”hidden” size=”30″ name=”focusperson” id=”focusperson” value=”‘.$ancestor.'”>’.”\n”;$out .= ‘<div id=”borderBox”>’.”\n”;
$out .= ‘<div id=”dragableElement”>’;
$out .= ‘<div id=”tree-container”>’.”\n”;
$out .= ‘<div id=”toolbar-container”>’.”\n”;
foreach ($the_family as $node) {
$out .= $node->get_toolbar_div();
}
$out .= ‘</div>’.”\n”;
$out .= ‘<div id=”thumbnail-container”>’.”\n”;
foreach ($the_family as $node) {
$out .= $node->get_thumbnail_div();
}
$out .= ‘</div>’.”\n”;
$out .= ‘<div id=”familytree”></div>’.”\n”;
$out .= ‘<img name=”hoverimage” id=”hoverimage” style=”visibility:hidden;” >’.”\n”;
$out .= ‘</div>’.”\n”; // tree-container
$out .= ‘</div>’.”\n”; // borderBox
$out .= ‘</div>’.”\n”; // dragableElement
if (wpft_options::get_option(‘showcreditlink’) == ‘true’) {
$out .= ‘<p style=”text-align:left”><small>powered by WP Family Tree</small></p>’.”\n”;
}
/*
$out .='<script type=”text/javascript”>’;
$out .=’ var el = document.getElementById(\’tree-container\’);’;
$out .=’ var leftEdge = el.parentNode.clientWidth – el.clientWidth;’;
$out .=’ var topEdge = el.parentNode.clientHeight – el.clientHeight;’;
$out .=’ var dragObj = new dragObject(el, null, new Position(leftEdge, topEdge), new Position(0, 0));’;
$out .='</script>’;
*/
return $out;
}
function bio_data() {
global $post;
$ftlink = wpft_options::get_option(‘family_tree_link’);
if (strpos($ftlink, ‘?’) === false) {
echo ‘<p>post_title.'”>click here to view family tree‘;
} else {
echo ‘<p>post_title.'”>click here to view family tree‘;
}
}function family_tree_edit_page_form()
{
global $post;
?>
<div id=”ftdiv” class=”postbox”>
<h3>Family tree info (optional)</h3>
<div class=”inside”><table>
<?php$family = get_posts(‘category_name=’.wpft_options::get_option(‘family_tree_category_key’).’&numberposts=-1&orderby=title&order=asc’);
$males = array();
$females = array();
foreach ($family as $f) {
if ($f->ID != $post->ID) {
$postgender = get_post_meta($f->ID, ‘gender’, true);
if ($postgender == “m”) {
$males[] = $f;
} else if ($postgender = “f”) {
$females[] = $f;
} else {
$males[] = $f;
$females[] = $f;
}
}
}$gender = get_post_meta($post->ID, ‘gender’, true);
$mother = get_post_meta($post->ID, ‘mother’, true);
$father = get_post_meta($post->ID, ‘father’, true);
$spouse = get_post_meta($post->ID, ‘spouse’, true);
?>
<tr><td>Gender:</td><td>
<select name=”gender” id=”gender”>
<option value=”” <?php if (empty($gender)) echo “selected=\”selected\””; ?>></option>
<option value=”m” <?php if ($gender == “m”) echo “selected=\”selected\””; ?>>Male</option>
<option value=”f” <?php if ($gender == “f”) echo “selected=\”selected\””; ?>>Female</option>
</select></td></tr>
<tr><td>Born (YYYY-MM-DD):</td><td><input type=”text” name=”born” value=”<?php echo wp_specialchars(get_post_meta($post->ID, ‘born’, true), true) ?>” id=”born” size=”80″ /></td></tr>
<tr><td>Died (YYYY-MM-DD):</td><td><input type=”text” name=”died” value=”<?php echo wp_specialchars(get_post_meta($post->ID, ‘died’, true), true) ?>” id=”died” size=”80″ /></td></tr>
<tr><td>Mother:</td><td>
<select style=”width:200px” name=”mother” id=”mother”>
<option value=”” <?php if (empty($mother)) echo “selected=\”selected\””; ?>> </option>
<?php
foreach ($females as $f) {
echo ‘<option value=”‘.$f->ID.'” ‘;
if ($f->ID == $mother) echo “selected=\”selected\””;
echo ‘>’.$f->post_title.'</option>’;
}
?>
</select>
</td></tr><tr><td>Father:</td><td>
<select style=”width:200px” name=”father” id=”father”>
<option value=”” <?php if (empty($father)) echo “selected=\”selected\””; ?>> </option>
<?php
foreach ($males as $f) {
echo ‘<option value=”‘.$f->ID.'” ‘;
if ($f->ID == $father) echo “selected=\”selected\””;
echo ‘>’.$f->post_title.'</option>’;
}
?>
</select>
</td></tr><tr><td>Spouse:</td><td>
<select style=”width:200px” name=”spouse” id=”spouse”>
<option value=”-” <?php if (empty($spouse) || $spouse==”-“) echo “selected=\”selected\””; ?>> </option>
<?php
/*
if ($gender == “f”) {
foreach ($males as $f) {
echo ‘<option value=”‘.$f->ID.'” ‘;
if ($f->ID == $spouse) echo “selected=\”selected\””;
echo ‘>’.$f->post_title.'</option>’;
}
} else if ($gender == “m”) {
foreach ($females as $f) {
echo ‘<option value=”‘.$f->ID.'” ‘;
if ($f->ID == $spouse) echo “selected=\”selected\””;
echo ‘>’.$f->post_title.'</option>’;
}
} else {
*/
foreach ($family as $f) {
echo ‘<option value=”‘.$f->ID.'” ‘;
if ($f->ID == $spouse) echo “selected=\”selected\””;
echo ‘>’.$f->post_title.'</option>’;
}
// }
?>
</select>
</td></tr></table>
</div>
</div>
<?php
}// Javascript data picker
// Facebook page, skype id, IM etc
// Occupation
// Locations: birthplace, died at, current location
// Spousefunction family_tree_update_post($id)
{
$born = stripslashes(strip_tags($_POST[‘born’]));
$died = stripslashes(strip_tags($_POST[‘died’]));
$mother = stripslashes(strip_tags($_POST[‘mother’]));
$father = stripslashes(strip_tags($_POST[‘father’]));
$spouse = stripslashes(strip_tags($_POST[‘spouse’]));
$gender = stripslashes(strip_tags($_POST[‘gender’]));if (!empty($born)) { delete_post_meta($id, ‘born’); add_post_meta($id, ‘born’, $born); } //else { add_post_meta($id, ‘born’, $born); }
if (!empty($died)) { delete_post_meta($id, ‘died’); add_post_meta($id, ‘died’, $died); } //else { add_post_meta($id, ‘died’, $died); }
if (!empty($mother)) { delete_post_meta($id, ‘mother’); add_post_meta($id, ‘mother’, $mother); } //else ( add_post_meta($id, ‘mother’, $mother); }
if (!empty($father)) { delete_post_meta($id, ‘father’); add_post_meta($id, ‘father’, $father); } //else { add_post_meta($id, ‘father’, $father); }
if (!empty($spouse)) { delete_post_meta($id, ‘spouse’); add_post_meta($id, ‘spouse’, $spouse); } //else { add_post_meta($id, ‘father’, $father); }
if (!empty($gender)) { delete_post_meta($id, ‘gender’); add_post_meta($id, ‘gender’, $gender); } //else { add_post_meta($id, ‘gender’, $gender); }
}// Function to deal with showing the family tree on pages
function family_list_insert($content) {
if (preg_match(‘{FAMILY-MEMBERS}’,$content)) {
$ft_output = family_list();
$content = str_replace(‘{FAMILY-MEMBERS}’, $ft_output, $content);
}
return $content;
}
// Function to deal with showing the family tree on pages
function family_tree_insert($content) {
if (preg_match(‘{FAMILY-TREE}’,$content)) {
$ft_output = family_tree();
$content = str_replace(‘{FAMILY-TREE}’, $ft_output, $content);
}
return $content;
}
// Function to deal with showing biodata on posts
function bio_data_insert($content) {
global $post;
$category = wpft_options::get_option(‘family_tree_category_key’);
$cats = get_the_category(); // get array of category objects that apply to this post
foreach ($cats as $cat) {
if ($cat->slug == $category || $cat->name == $category) {
// This post is a family member post so do the work…
$the_family = tree::get_tree();
if (isset($the_family[$post->ID])) {
$html = $the_family[$post->ID]->get_html($the_family);
$content = $html.$content;
}
break;
}
}
return $content;
}function wpft_family_tree_shortcode($atts, $content=NULL) {
$root = $atts[‘root’];
$ft_output = family_tree($root);wpft_options::check_options();
return $ft_output;
}function wpft_family_members_shortcode($atts, $content=NULL) {
$root = $atts[‘root’];
$ft_output = family_tree($root);
$ft_output = family_list();wpft_options::check_options();
return $ft_output;
}add_shortcode(‘family-tree’, ‘wpft_family_tree_shortcode’);
add_shortcode(‘family-members’, ‘wpft_family_members_shortcode’);add_action(‘admin_menu’, ‘family_tree_options_page’);
function wpft_addHeaderCode() {
$plugloc = WP_PLUGIN_URL.’/’.str_replace(basename( __FILE__),””,plugin_basename(__FILE__));
wp_enqueue_script(‘jquery’);
wp_enqueue_script(‘raphael’, $plugloc.’raphael.js’);
wp_enqueue_script(‘familytree’, $plugloc.’familytree.js’);
wp_enqueue_script(‘dragobject’, $plugloc.’dragobject.js’);
wp_enqueue_script(‘onload’, $plugloc.’onload.js’);
wp_enqueue_style(‘ft-style’, $plugloc.’styles.css’);
}
function addFooterCode() {}
// Enable the ability for the family tree to be loaded from pages
add_filter(‘the_content’,’family_list_insert’);
add_filter(‘the_content’,’family_tree_insert’);if (wpft_options::get_option(‘show_biodata_on_posts_page’) == ‘true’) {
add_filter(‘the_content’,’bio_data_insert’);
}add_action(‘init’, ‘wpft_addHeaderCode’);
add_action(‘edit_post’, ‘family_tree_update_post’);
add_action(‘save_post’, ‘family_tree_update_post’);
add_action(‘publish_post’, ‘family_tree_update_post’);add_action(‘edit_page_form’, ‘family_tree_edit_page_form’);
add_action(‘edit_form_advanced’, ‘family_tree_edit_page_form’);
add_action(‘simple_edit_form’, ‘family_tree_edit_page_form’);?>
I attempted to reply to the support post of the same name, but it was closed. I am experiencing this issue as well. The dropdowns for mother, father, and spouse are empty, even though there are other posts in the same category
The posts for my mother, father, and spouse exist in the web site. The WP Family Tree plugin is the only one activated. The site is a clean install of WP 3.6.1. I am using twentythirteen as the theme. The category is “family” as is the category selected in the WP Family Tree settings.
Please advise.
]]>Hi there,
I was wondering if your plugin could support multiple family trees.
We are developing a “social site” and we want members to have the opportunity to develop their family tree within their own private area with an option to share.
Happy to pay for some development cost…
]]>