Eric Mann
Forum Replies Created
-
Forum: Plugins
In reply to: [JS Banner Rotate] Confused? Banner rotation lengthollieford: Don’t hijack old, resolved topics. Start a new thread please.
Forum: Plugins
In reply to: [WP Publication Archive] Order by date in widgetThe widget was code contributed by another user. I’ll need to take a look to see why things aren’t working and whether or not there really is a drag and drop feature.
Forum: Plugins
In reply to: [WP Session Manager] On busy sites the plugin becomes very inefficientYes, the API did change a slightly.
In the older version, sessions were written on every page load, regardless if the data changed in them at all. I worked with some other developers to fix this so that sessions are only written if something changes.
In an ideal (i.e. high-traffic environment), this is what happens:
- When a new visitor hits your site, a new session is created for them and stored in the database. The session ID, exipiration, and “variant” is stored in a cookie in the user’s browser.
- When the user comes back to the site, the session is read into the cache (APC or Memcached or something else, depending on your configuration) if it’s still valid.
- If the session is unexpired, but past the timestamp recorded as a variant, the expiration is updated so things aren’t cleared out too quickly (This is 1 database write to update the exipiration. But it won’t occur on every page load … and you can set the timeout before it does happen through a filter.
- If nothing changes during this page load (i.e. nothing added to a cart, no options changed), then nothing further happens.
- When the user revisits your site, the session is loaded from the cache (no roundtrip to the database).
- If any session data changes, the session is marked as “dirty.”
- Dirty sessions are re-written to the database at the end of the request.
One big change did occur with the update – sessions are no longer explicitly available in the global namespace as
$wp_session. Instead, you’ll need to:- Explicitly define
$wp_session = WP_Session::get_instance();inside any session-dependent functions. - OR set a global
$wp_sessionequal toWP_Session::get_instance()inside a function hooked to eitherinitorwp_session_start.
The reasoning behind this change was primarily to keep the global namespace clean and to prevent installing any hidden dependencies in code. A lot of people freaked out that WP_Session was implemented as a singleton in the first place. A second chorus protested to storing it in a global variable as well. This qas a compromise.
Forum: Plugins
In reply to: [WP Publication Archive] Order by date in widgetYou are doing things just fine; there isn’t a feature to allow sorting by date yet.
I don’t know what you mean by the “second choice of manually (Drag / Drop)”
Forum: Plugins
In reply to: [WP Publication Archive] How to restrict other file uploads except pdfThere is no feature yet to allow restricting file type uploads. However, I can investigate that for a future version.
Also, this thread shows you’re running WordPress version 3.0.4. WP Publication Archive is not supported for that old of a WordPress version.
Forum: Plugins
In reply to: [JS Banner Rotate] Delay before banner appearsThe plugin currently has a minor performance bug, unfortunately that’s the bug you’re running in to.
The JavaScript attempts to prefetch all images in your banner before displaying anything. This is meant to make it so larger images don’t load in chunks (have you ever seen JPGs and PNGs load one line at a time? That’s what we’re preventing here).
I’m not sure how many images are in your banner, but each one is 1024x240px, which is rather large to begin with (>100KB). The delay is because the images are being loaded into the cache.
I’ll see what I can do to make it load the first image immediately (rather than waiting for all of them), but I don’t have an ETA for that fix. In the short run, you can try optimizing your images to decrease the image size. http://smush.it is a fairly good resource for optimizing what you already have. It should decrease most of your image filesizes by at least 10%.
Forum: Plugins
In reply to: [WP Publication Archive] Change archive layoutYes, you can do this. The layout (the output of the shortcode) is controlled by
template.wppa_publication_list.phpin the/includesdirectory. What you do is copy this file into your active theme, then edit your copy as much as you want to.The template file is heavily documented, so you can see what variables are set and what markup is being used. Just remember, do not edit the copy in the plugin folder as any updates will overwrite your changes. Copy the file into your theme first, then edit the copy there. The plugin will automatically detect the new file in the theme and load it instead.
Forum: Plugins
In reply to: [WP Session Manager] On busy sites the plugin becomes very inefficient>Because the session data is being stored as transients WordPress is attempting to auto load every single one when it starts.
No, the sessions are not stored as transients. They are stored as standard options with autoload set to “no” so that they’re not automatically loaded on every page load for every visitor.
See line 152 of
class-wp-session.php.There was a previous version of the plugin that did use transients, but things have since been rewritten to avoid transients to correct this exact problem. My question would be, which version of the plugin are you using?
Forum: Plugins
In reply to: [Absolute Privacy] WordPress 3.5.1 CompatibilityThe two year update notice is wrong, but not by much. The plugin was updated to fix a major security hole on 2/25/2012 (which was just over a year ago). However, the last version the plugin was explicitly tested with was version 3.3.2, so your mileage may vary with 3.5.1.
I actually fixed this bug to use the plugin for a client. You can find my “fixed” version on GitHub: https://github.com/ericmann/custom-permalinks/tree/dev
I’ve also sent the changes back to the original developer via email but have yet to hear back. I’ll pull in the latest release (that fixed a minor compatibility issue elsewhere) when I get the chance to the GitHub version is up to date.
It would be a nice enhancement if the number of links displayed was configurable through the WordPress Dashboard.
That’s certainly one approach, but one I specifically avoided as not not needlessly clutter the Dashboard any more than it already is.
Forum: Plugins
In reply to: [JS Banner Rotate] JS Banner Rotate plugin breaks Event Registration pluginActually, bringing this up with me is fine if you can tell me which event registration plugin is conflicting. If it’s open source (i.e. available on WordPress.org) I can take a look, find the conflict, and fix it.
A better solution will be for me to rename the mimetype class in the next version, which I will do. Then you won’t need to worry about a thing 🙂
Thanks for the head’s up!
Forum: Plugins
In reply to: [WP Publication Archive] Bulk Upload of DocumentsAt the moment, no. But I can look into that for a future version.
Forum: Plugins
In reply to: [WP Publication Archive] Group publications by date, similar to posts archiveAt the moment, no, but I’ll add this to my to-do list for potential future features.
https://github.com/ericmann/WP-Publication-Archive/issues/23