Forum Replies Created

Viewing 15 replies - 46 through 60 (of 268 total)
  • Thread Starter Mark

    (@codeispoetry)

    Yes! Thank you, I was not aware of those legacy multisite settings and your pointer to wp-config was right on the money.

    Thread Starter Mark

    (@codeispoetry)

    Sorry for mucking about, but I found I do have access so (1) I’ve commented out those lines above in wp-config.php, and (2) added a proper ms-files statement to .htaccess as specified in the Network Setup dialog. This does solve one problem I had on the blog (uploaded images wouldn’t display) so I’ll keep it this way (bringing it closer to a vanilla multisite setup).

    But I can still see that the matomo.js file is being sought in a subfolder (where it doesn’t reside) instead of where you’d expect it, and I don’t know where that URL is generated.

    Thread Starter Mark

    (@codeispoetry)

    Unfortunately I have admin access to WP but not SFTP access to the file system in this install, so I can’t answer the wp-config question. But patching was possible through the WP plugin editor, so that’s now done.

    Update: I can view the file though. This is the most relevant code:

    
    define('SUBDOMAIN_INSTALL', false);
    $base = '/';
    

    (snip)

    
    // fix file upload location?
    define( 'UPLOADBLOGSDIR', 'wp-content/uploads/sites' );
    
    function stupid_ms_files_rewriting() {
            $url = '/wp-content/uploads/sites/' . get_current_blog_id();
            define( 'BLOGUPLOADDIR', $url );
    }
    add_action('init','stupid_ms_files_rewriting');
    

    I’m including the latter part since you mentioned the upload dir. I’m not responsible for the server but some sysadmin apparently had to add a function for a feature they didn’t like? 😉

    • This reply was modified 5 years, 2 months ago by Mark.
    Thread Starter Mark

    (@codeispoetry)

    I conclude from this that the limitation lies in how TransIP configures its virtual hosting for WordPress. Would that be correct? The only way they allow subdomains to be added to the certificate is by actually creating them in their webhosting interface. But doing so creates corresponding subfolders, which in turn causes WordPress to stop understanding that mysite1.mydomain.org should be resolved by the WP installation at mydomain.org (instead, mysite1.mydomain.org now serves what’s in \www\subdomains\mysite1\).

    It is likely my limited understanding of the notion of a “wildcard” certificate, but I don’t really get how something can be described as a wildcard *.mydomain.org if you still have to add subdomains to the certificate manually. Anyway I appreciate the reply and conclude that Really Simple SSL doesn’t help me solve this problem…

    Thread Starter Mark

    (@codeispoetry)

    No worries, this one’s easy to work around!

    Thread Starter Mark

    (@codeispoetry)

    Thank you! I see, I guess this is because filename is a property of attachment items and that requires a separate request. (What I don’t understand is how you’re able to find out the content type in one go, which you already do; somehow I assumed the filename was also within reach then.)

    I guess if the data can be cached like most metadata seems to be this would have a negligible effect on first load only; already I find it’s pretty very fast, for instance it takes only a few secs to retrieve everything anew when refreshing the cache. So I’m looking forward to seeing how this works out!

    (And if multiple requests really turn out too slow I suppose the alternative I mentioned, of cobbling up a more informative name on the fly based on the metadata you do know, might be a useful workaround. Sth like author_year.pdf or for more disambiguation Author_year_First_five_words_of_title.pdf or even (uglier but unique) author_year_itemid.pdf would already be more user-friendly than the current format.)

    Thanks so much for your work on this, I very much look forward to the updates!

    • This reply was modified 5 years, 3 months ago by Mark.
    Thread Starter Mark

    (@codeispoetry)

    Still hoping that this might be relatively straightforward for @kseaborn … Mucking around in the ZotPress code myself I haven’t been able to retrieve the original attachment filename but it sure would be available somewhere?

    Thread Starter Mark

    (@codeispoetry)

    Whoah it does! I may not have tested it before just because it wasn’t in the docs, or I may have misunderstood how “inclusive” works (I get it now, but it still feels slightly counterintuitive to say “inclusive=’no'” for when I want to include items with all of these tags). Thank you, this does solve this particular need, which is excellent!

    • This reply was modified 5 years, 4 months ago by Mark.
    • This reply was modified 5 years, 4 months ago by Mark.
    Thread Starter Mark

    (@codeispoetry)

    Lovely, thank you!

    Thread Starter Mark

    (@codeispoetry)

    I probably don’t get it but even though inclusive=no works for the other case (which is awesome!), it doesn’t seem to address the use case where I’d want to exclude some set of items that have a particular tag or tags. So the request is to be able to do sth like this:

    [zotpress author="Roberts" tagsexclude="rubbish"]

    With the resulting list being all publications by Alice except those tagged as rubbish.
    The more general case would be to allow items to be excluded from a list based on whatever feature (e.g. item type, like preprints, or collection); but I was hoping tags would be an obvious first solution.

    • This reply was modified 5 years, 4 months ago by Mark.
    Mark

    (@codeispoetry)

    I’m afraid not…

    Mark

    (@codeispoetry)

    No, it can also be at the level of abstract, as there is no limit to the amount of toggles you can have. E.g. the toggle could be a placeholder “Abstract”.

    I suppose folks more well-versed in Javascript could also fix it that way; it doesn’t need to be CSS. The main thing I’m saying is that it’s probably not a great idea to do it at the level of WordPress content filters, as they necessitate a new database query (and hence page load) every time a new abstract is needed; whereas loading them all at once and then manipulating their visibility is going to be faster, easier to cache, etc.

    • This reply was modified 5 years, 4 months ago by Mark.
    Mark

    (@codeispoetry)

    I think you could do the hiding and showing with CSS alone along the lines of this solution: https://dabblet.com/gist/1506530

    So you’d load all of the abstracts without filtering, then display:none with CSS, and use a toggle to set the display status. This would require no filtering at WordPress level.

    Mark

    (@codeispoetry)

    If you want to see immediate effect, clearing the cache is indeed the only method. But I have noticed that updates to my Zotero (group) libraries do show up within a day, and do not require manually clearing the cache. There may be a difference in adding items vs. changing some aspects of items that I’m not aware of (I’m talking mainly about adding new items).

    Mark

    (@codeispoetry)

    We can’t see what you see. You’ll need to share more about your basic setup, what you’ve tried, which shortcodes you’re using, before anybody here can try to help out.

Viewing 15 replies - 46 through 60 (of 268 total)