• Hi!

    I installed the 1.0.9 plugin on a WP3.1.2 and I keep having “Player not added” in the “Player” menu. I even followed Brent Gabel’s tuto see if I haven’t missed anything…

    I added manually into the player table through phpmyadmin.
    Player added but does not show in player list to edit, but shows in players to add to season.

    Shame as it’s a great plugin (actually, it’s the only one) for managing baseball roster.

    Any chance to get a fix (and perhaps, manage multiple teams), please?
    Many thanks for your help !

    Olivier.
    “It’s baseball everywhere !”

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author nick50119

    (@nick50119)

    Hi Olivier,
    I may need some help from you troubleshooting as I cannot duplicate the issue. A couple of things to check first.

    First, try to add a basic player. Make sure that the following are included.
    First Name, Last Name, Team, Season and see if that works. If not, I will need to have you add some debug statements to help me see what you are seeing.

    Thread Starter olivieric911

    (@olivieric911)

    Hi!
    Wow, that was quick ??
    I already tried to add a basic user (First, Last, birth, Team & Season). No luck.

    I’ve just set WP_DEBUG to True.
    Waiting for your instructions, mate ??

    Plugin Author nick50119

    (@nick50119)

    Olivier,
    Please try this, this will give the details of the issue.
    Make the following changes in edit bbnuke-functions.php
    1) Find the function bbnuke_add_player()
    2) at the bottom of the function, add the following echo statements as shown below
    ` $result = mysql_query($query);
    if ($result)
    $ret = true;
    echo $query;
    echo mysql_error();
    else
    $ret = false;
    echo $query;
    echo mysql_error();`
    3) save and try to add a player, then send me the error.

    Thread Starter olivieric911

    (@olivieric911)

    Nick,
    I’m having this error after modifying the function through a text editor:
    Parse error: syntax error, unexpected T_ELSE in …\wp-content\plugins\baseballnuke\bbnuke-functions.php (line ‘ELSE’ statement).
    Here’s the complete function:
    function bbnuke_add_player()
    {
    global $wpdb;

    // get post data
    $firstname = $_POST[‘bbnuke_player_edit_fname’];
    $middlename = $_POST[‘bbnuke_player_edit_mname’];
    $lastname = $_POST[‘bbnuke_player_edit_lname’];
    $profile = $_POST[‘bbnuke_player_edit_pprofile’];
    $positions = $_POST[‘bbnuke_player_edit_position’];
    $bats = $_POST[‘bbnuke_player_edit_bats’];
    $throws = $_POST[‘bbnuke_player_edit_throws’];
    $height = $_POST[‘bbnuke_player_edit_height’];
    $teamname = $_POST[‘bbnuke_player_edit_team’];
    $season = $_POST[‘bbnuke_player_edit_season’];
    $weight = $_POST[‘bbnuke_player_edit_weight’];
    $bdate = $_POST[‘bbnuke_player_edit_bdate’];
    $address = $_POST[‘bbnuke_player_edit_address’];
    $city = $_POST[‘bbnuke_player_edit_city’];
    $state = $_POST[‘bbnuke_player_edit_state’];
    $zip = $_POST[‘bbnuke_player_edit_zip’];
    $homephone = $_POST[‘bbnuke_player_edit_hphone’];
    $cellphone = $_POST[‘bbnuke_player_edit_cphone’];
    $workphone = $_POST[‘bbnuke_player_edit_wphone’];
    $jerseynum = $_POST[‘bbnuke_player_edit_jerseynum’];
    $email = $_POST[‘bbnuke_player_edit_email’];
    $school = $_POST[‘bbnuke_player_edit_school’];
    $piclocation = $_POST[‘bbnuke_player_edit_pictureloc’];

    $query = “INSERT INTO ” . $wpdb->prefix . “baseballNuke_players SET teamName=’$teamname’,
    firstname=’$firstname’,middlename=’$middlename’,
    lastname=’$lastname’,positions=’$positions’,
    bats=’$bats’,throws=’$throws’,height=’$height’,weight=’$weight’,
    address=’$address’,city=’$city’,state=’$state’,zip=’$zip’,
    homePhone=’$homephone’,workPhone=’$workphone’,
    cellphone=’$cellphone’,jerseyNum=’$jerseynum’,
    picLocation=’$piclocation’,season=’$season’,
    profile=’$profile’,email=’$email’,school=’$school’,bdate=’$bdate'”;
    $result = mysql_query($query);
    if ($result)
    $ret = true;
    //
    echo $query;
    echo mysql_error();
    else
    $ret = false;
    //
    echo $query;
    echo mysql_error();

    return $ret;
    }

    Modifying through WP editor, I get this:

    Notice: Use of undefined constant bbnuke_topbatters – assumed ‘bbnuke_topbatters’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1582 Notice: Use of undefined constant bbnuke_widget_top_batters – assumed ‘bbnuke_widget_top_batters’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1582 Notice: Use of undefined constant bbnuke_toppitchers – assumed ‘bbnuke_toppitchers’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1583 Notice: Use of undefined constant bbnuke_widget_top_pitchers – assumed ‘bbnuke_widget_top_pitchers’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1583 Notice: Use of undefined constant bbnuke_lastgame – assumed ‘bbnuke_lastgame’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1584 Notice: Use of undefined constant bbnuke_widget_lastgame – assumed ‘bbnuke_widget_lastgame’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1584 Notice: Use of undefined constant bbnuke_nextgame – assumed ‘bbnuke_nextgame’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1585 Notice: Use of undefined constant bbnuke_widget_nextgame – assumed ‘bbnuke_widget_nextgame’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1585 Notice: Use of undefined constant bbnuke_batstats – assumed ‘bbnuke_batstats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1586 Notice: Use of undefined constant bbnuke_widget_batstats – assumed ‘bbnuke_widget_batstats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1586 Notice: Use of undefined constant bbnuke_roster – assumed ‘bbnuke_roster’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1587 Notice: Use of undefined constant bbnuke_widget_roster – assumed ‘bbnuke_widget_roster’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1587 Notice: Use of undefined constant bbnuke_pitchstats – assumed ‘bbnuke_pitchstats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1588 Notice: Use of undefined constant bbnuke_widget_pitchstats – assumed ‘bbnuke_widget_pitchstats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1588 Notice: Use of undefined constant bbnuke_fieldstats – assumed ‘bbnuke_fieldstats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1589 Notice: Use of undefined constant bbnuke_widget_fieldstats – assumed ‘bbnuke_widget_fieldstats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1589 Notice: Use of undefined constant bbnuke_playerstats – assumed ‘bbnuke_playerstats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1590 Notice: Use of undefined constant bbnuke_widget_playerstats – assumed ‘bbnuke_widget_playerstats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1590 Notice: Use of undefined constant bbnuke_top5stats – assumed ‘bbnuke_top5stats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1591 Notice: Use of undefined constant bbnuke_widget_top5stats – assumed ‘bbnuke_widget_top5stats’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1591 Notice: Use of undefined constant bbnuke_schedule – assumed ‘bbnuke_schedule’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1592 Notice: Use of undefined constant bbnuke_widget_team_schedule – assumed ‘bbnuke_widget_team_schedule’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1592 Notice: Use of undefined constant bbnuke_practice – assumed ‘bbnuke_practice’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1593 Notice: Use of undefined constant bbnuke_widget_team_practices – assumed ‘bbnuke_widget_team_practices’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1593 Notice: Use of undefined constant bbnuke_tournament – assumed ‘bbnuke_tournament’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1594 Notice: Use of undefined constant bbnuke_widget_team_tournament – assumed ‘bbnuke_widget_team_tournament’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1594 Notice: Use of undefined constant bbnuke_fields – assumed ‘bbnuke_fields’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1595 Notice: Use of undefined constant bbnuke_widget_locations_info – assumed ‘bbnuke_widget_locations_info’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1595 Notice: Use of undefined constant bbnuke_gameresults – assumed ‘bbnuke_gameresults’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1596 Notice: Use of undefined constant bbnuke_widget_game_results – assumed ‘bbnuke_widget_game_results’ in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1596 Notice: load_plugin_textdomain was called with an argument that is deprecated since version 2.7 with no alternative available. in F:\wwwroot\squales\wp-includes\functions.php on line 3389 Notice: register_sidebar_widget est d??pr??ci?? depuis la version 2.8! Utilisez wp_register_sidebar_widget() ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3303 Notice: register_widget_control est d??pr??ci?? depuis la version 2.8! Utilisez wp_register_widget_control() ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3303 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Notice: Use of undefined constant XCloner – assumed ‘XCloner’ in F:\wwwroot\squales\wp-content\plugins\xcloner-backup-and-restore\xcloner.php on line 28 Notice: Use of undefined constant XCloner – assumed ‘XCloner’ in F:\wwwroot\squales\wp-content\plugins\xcloner-backup-and-restore\xcloner.php on line 28 Notice: has_cap est appel?? avec un argument qui est d??pr??ci?? depuis la version 2.0 ! L’utilisation des niveaux d’utilisateur par les extensions et th?¨mes est d??sormais interdite. Utiliser les r?′les et capacit??s ? la place. in F:\wwwroot\squales\wp-includes\functions.php on line 3387 Warning: Cannot modify header information – headers already sent by (output started at F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php:1593) in F:\wwwroot\squales\wp-includes\pluggable.php on line 897

    Hope this helps…

    Plugin Author nick50119

    (@nick50119)

    Can you kill the wordpress debug and try again with just the echo statements?

    Thread Starter olivieric911

    (@olivieric911)

    same issue:
    Parse error: syntax error, unexpected T_ELSE in F:\wwwroot\squales\wp-content\plugins\baseballnuke\bbnuke-functions.php on line 1030 (at the ELSE). ??

    Thread Starter olivieric911

    (@olivieric911)

    Hi Nick!
    Fixed the issue with { } around each case.

    I finally got the error requested :

    INSERT INTO wp_baseballNuke_players SET teamName=’Flying Dogs’, firstname=’toto’,middlename=”, lastname=’titi’,positions=”, bats=”,throws=”,height=”,weight=”, address=”,city=”,state=”,zip=”, homePhone=”,workPhone=”, cellphone=”,jerseyNum=’35’, picLocation=”,season=’2008′, profile=”,email=”,school=”,bdate=”Incorrect integer value: ” for column ‘height’ at row 1

    Seems to be a missing value for the height.
    By the way, what’s the expecte value (meter or feet)?

    Many thanks in advance !

    Plugin Author nick50119

    (@nick50119)

    That is interesting that it does not allow the height value to be blank. On mine it doesnt have an issue, I wonder if it has to do with the mysql version.

    The height field is an integer, if entered it will display on the user profile page. It is expected to be in inches(feet), I will be looking at making it more useful for international users soon

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘[baseballnuke] cannot add player’ is closed to new replies.