Support » Fixing WordPress » moving old plugin to new server

  • I have an old 4.0.21 installation where i have a custom developed plugin (by someone else). I’ve moved it to my new server which is 4.9.1 and i do have 2 different questions:

    1. When i activate the plugin i get the error message:
    “The plugin generated 3 characters of unexpected output during activation. If you notice “headers already sent” messages, problems with syndication feeds or other issues, try deactivating or removing this plugin.”

    2. I cant figure out how to get the output from the plugin onto a page. In the plugin i can see this function which seems to list the entries in the database. But how do i call this function from a page?

    // function to
    function show_campusmap()
    global $wpdb;

    $tenants = $wpdb->get_results( “SELECT * FROM tenants ORDER BY name ASC” ); // .mysql_real_escape_string(intval($_GET[‘page’]), $wpdb->dbh) );
    $num_tenants = $wpdb->num_rows;

    <div style=”position:relative;z-index:2;width:412px;float:left;padding-top:0;padding-left:10px;”>
    <table cellspacing=”0″ style=”float:left;margin-top:10px;”>
    $i = 0;
    foreach($tenants as $tenant)
    if( $i == intval($num_tenants / 2) )
    <table cellspacing=”0″ style=”float:right;margin-top:10px;”>

Viewing 1 replies (of 1 total)
  • Issue #1 can be caused by a number of things:

    1) There could be whitespace before the opening or after the closing php tag.
    2) A file could be encoded wrong (UTF-8).
    3) The plugin could be calling the wrong function.

    Issue #2: Did you have this working on your old site? Since this isn’t a publicly available plugin and we have absolutely no access to the code other than what you’ve posted, and we’ve no idea what this plugin is supposed to do, it’s almost impossible to say. Is it hosted on GitHub or some other public repo? If not, your best bet is to contact the original developer.

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.