Forum Replies Created

Viewing 14 replies - 1 through 14 (of 14 total)
  • Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Subscribing for updates. Ignore this message.

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Subscribing for email notifications. Ignore this post.

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    So the problem with zotpress working on my main site and not on my subsite was that, in fact, there *was* more state left behind when I tried to clean out my installation entirely. Dropping the wp_zotpress* tables was *not* enough. The reason is that there are four entries in the wp_options table (and in the wp_<n>_options table for each subsite) with version information about each of the four tables zotpress creates. When I deleted all the tables, those entries in “options” were left behind. And, wouldn’t you know it, the code to create tables skips table creation if those entries indicate up-to-date table structures.

    So that was that problem.

    Once that was solved, I re-installed the plug-in and activated on my subsite. No go. So I deactivated and deleted the plug-in. Discover: Deleting the plugin does remove tables from the main site, but *not* from the sub-sites. I left those tables in place, added the plug-in, activated on the main site (network activation) and now, finally, I have a *half* working install on my sub-site, where I need it.

    There are two remaining problems. The javascript acknowledgements of various actions, such as validating an account, deleting an account, creating and account, setting one of the accounts to default, etc. is still not working. The actions are actually being carried out, but for some reason not yet determined the nice javascripty messages and page updates aren’t working. Browser “console” window shows an error message about there being white space before XML data. Not sure if that’s relevant.

    I’d also note that sometimes when I add a citation to my zotero database, sync from zotero online to zotpress just stops working (spinning wheel). I really have no idea what specific conditions trigger this problem. Deleting the entries from Zotero (stand alone), then syncing to Zotero (online), and finally resynching to zotpress so far has cleared up the problem. These are simple bib entries, to which, at least sometimes, I’ve added a PDF “underneath”. I don’t know if that’s relevant.

    Last point: There seems to be latency between the time when Zotero online updates and when doing a sync in Zotpress actually pulls in the most recent additions. I’m not sure if the “problem” here is that the Zotero web page and the Zotero API are out of sync, or if Zotpress is somehow deciding not to pull in the most recent posts immediately. It’s usually some tens or more of seconds, and several tries, before Zotpress pulls down the most recent uploads. Would be good to know why.

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Ok, more information. One problem is that while Zotpress is creating tables for site 1, the main site, on my multi-site set-up, it’s not creating its tables when I activate or use the plug-in on a sub-site. So it’s at least 1/2 working on the main site, but not at all on the sub-site. And the WordPress debug.log file confirms that the error when I try to add an account on the subsite is that the tables for the subsite (wp_6_zotpress, etc) are missing, the subsite being site 6.

    I’ve completed deleted and reinstalled the plugin, and it consistently (1) creates tables for site=1, and (2) refuses to create tables for site=6, whether I activate network-wide and just try to use it on site=6, or whether I install it and activate it on site=6. Even the latter fails to create the required tables.

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Katie,

    Pardon me. Yes, you did reply. Thank you. Thanks for confirming that uninstall deletes everything. Not sure where to go from here. It’s working on another site of mine. If you have any suggestions for debugging, I’m open. E.g., what line of code might I add to my local zotpress install to write something to the screen or to a log so that I can see that, e.g., the code for adding an account is even being called.

    ====

    Hi Kevin

    Zotpress should uninstall everything. I think there might be something else going on. “Browse” only shows the top-level items in your library. If you’re not using Collections, then everything should be loaded there. It can take several minutes depending on the size of your library; at the bottom, there should be more pages added as it loads. If you want to display items associated with a tag, then use the attribute tag=”the+tag+name” where spaces are plus signs.

    Best,
    Katie

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Thank you. I will try and report back. (Also, I note that the numbers within the square brackets are all [1]. Is that also Zotero-induced?)

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    By the way, I’m working with a just-created Zotero repo, with one group, and just one bibliographic entry. I’m confident I’ve created and entered the app id and key correctly.

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Thanks, everyone, I appreciate the responses and support. A few points:

    * I’ve looked around (including pay plugins) and haven’t yet found anything better
    * So I’m using a work-around for now: go to the main site admin to edit group pages
    * I’d encourage the community to adopt simple wording to create up-front awareness
    * Perhaps, Tammy, if you issue a pull request (equivalent) for you changes, they could be considered for integration into BP; that’d be a benefit to you in the long run, as you would avoid having to merge your changes into each subsequent release of the software

    I am impressed with the response to my message. It speaks well of the people committed to this code. As a matter of professional judgement, I guess I’d stand by the position that there’s a basic, if not design flaw with respect Multisite F, then at least a real architectural mismatch between what BP tries to offer and how WP is designed.

    The most urgent need is simply to let people know not to go down this rathole. I will think, and I see that others already have, about solutions. I’ll certainly update my stars as we make progress.

    Thank you, all. Happy to hear your further thoughts.

    Forum: Plugins
    In reply to: [Zotpress] Loading …
    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Resolved (without fix)

    Forum: Plugins
    In reply to: [Zotpress] Loading …
    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Ok, indeed, the problem is that the logic broken when there are no collections / tags yet defined. It was sufficient (not sure if it was entirely necessary) to define at least one collection and one tag. The suggested fix is to detect situations (in the code I quoted) where the collection set or tag set is empty, and then replace “Loading …” with text that indicates “No tags yet defined” or “No collections yet defined” or something like that. Otherwise it’s super-confusing for someone just starting out with this software. The documentation, as far as I can tell, isn’t enough, you gotta read the code to see where the program is going wrong (at least as far as useful messaging is concerned).

    Forum: Plugins
    In reply to: [Zotpress] Loading …
    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Looks like this is the relevant code. Weird that “Loading …” doesn’t appear as a string anywhere in the code base (I’m looking on GitHub.) I guess the message is rendered as an image! In any case, it looks like the box is meant to list selectable tags (and the first box to list selectable collections). I have no collections defined and only one tag. Is that the problem … that what I’m seeing is the contents of the list as initialized and never overwritten because, for some reason, the system isn’t finding any tags (even tho I have defined at least one)?

    <div id=”zp-Browse-Tags”>
    <label for=”zp-List-Tags”><span>Tags</span></label>
    <select id=”zp-List-Tags” name=”zp-List-Tags”<?php if ( $tag_id ) { ?> class=”active”<?php } ?>>
    <?php if ( !$tag_id ) { ?><option id=”zp-List-Tags-Select” name=”zp-List-Tags-Select”>No tag selected</option><?php } ?>
    <?php

    //$zp_tags = get_terms( ‘zp_tags’, array( ‘hide_empty’ => false ) );
    $zp_tags = $wpdb->get_results(“SELECT * FROM “.$wpdb->prefix.”zotpress_zoteroTags WHERE api_user_id='”.$api_user_id.”‘ ORDER BY title ASC”, OBJECT);

    foreach ( $zp_tags as $zp_tag )
    {
    //if ( get_option( ‘zp_tag-‘.$zp_tag->term_id.’-api_user_id’ ) != $account_id ) continue;

    echo “<option class=’zp-List-Tag’ rel='”.$zp_tag->id.”‘”;
    if ( $tag_id == $zp_tag->id ) echo ” selected=’selected'”;
    echo “>”.$zp_tag->title.” (“.$zp_tag->numItems.”)”;
    echo “</option>\n”;
    }

    ?>
    </select>
    </div>

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    I haven’t double checked but I’ll consider this resolved for now.

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Well, actually the article *is* in my library. I don’t know then why the in-text citation didn’t expand properly.

    Thread Starter drkevinsullivan

    (@drkevinsullivan)

    Embedding this shortcode — [zotpressInText item=”{ABCD2345}”] — within the text of a post results in a spinning wheel. However embedding this shortcode at the end of a post –[zotpress items=”ABCD2345″ style=”ieee”] — does insert the proper reference. As I said, though, browsing my library via Zotpress does not show the article to be in my library.

Viewing 14 replies - 1 through 14 (of 14 total)