rcain
Forum Replies Created
-
Hi Woodent – thanks for that.
finally managed to get it all fixed, plus also created an alternative layout + resizable/’stretchy’ image version of the css.
two files affected. you can find the updated code here::
promo_slider.js :: http://pastebin.com/KP5NDVpV – NOTE: look for my mod marks ‘mod jrc …’
slide.css :: http://pastebin.com/9JDPFas5 – NOTE: this is an alternative css file to try for those people who would like a different look and ‘stretchy’ style
i found a number of other bugs in your code i’m afraid, some of which have been raised already. they include::
http://wordpress.org/support/topic/plugin-promotion-slider-slider-duplicating-image?replies=2 – note: this was caused by unnecessary events firing and not getting queued properly in the stack (nested call-backs)
and
http://wordpress.org/support/topic/plugin-promotion-slider-slides-auto-advancing-at-varying-times?replies=4 – note: same underlying case as above.
also, the bugs raised by me in the first post above, vis::
– the ‘scroller jag’ bug
– the ‘progress’ event cascade bug (responsible for both of above)also, a couple of newly discovered bugs::
– ‘double click move-left/right causes unwanted browser select-text highlighting of panel content’
– slider ‘options’ not set/incorrectly set at plugin js init
all of which are now fixed and tested in Chrome 15.0, FF 8.0.1, IE 9.0, on MS Vista, and Safari 5.0.5 and FF 3.6.19 on Mac OSX10.5.8 – all ok.
please feel free to incorporate what’s sound in your next release.
ps. i’m also working on extending option to permit/swap-in jQuery ‘slider’ and ‘easing’ functions – make it even more sexy. drop me a line if you would like a copy of that code when i’m done.
best wishes
Rob Cain
SystemCore.co.ukSTOP PRESS:: the above fix for browser ‘jag’ does NOT quite work correctly yet – (it slowly ‘grows’ div height – not good). – will be back with a fix to the fix asap.
great stuff merganser – just trying it out now (see also my other thread). works great so far. many thanks. keep up the good work. 🙂
back…
just installed and tested your latest version V1.0.6 – all seems good so far, no breakages – well done and many thanks. (will continue testing).
one slight misbehaviour of admin,media categories, edit category, description – edit window refuses to accept/show input – unless you toggle visual/html mode first (also button graphix missing). but this is minor.
hi merganser,
sorry to take so long getting back – still catching up.
haven’t tried your latest yet – will do that right now.
just for completeness todate, here’s a pastebin of the mods i tried to V.05 of media-categories.php::
my mods are marked ‘mod jrc …’.
unfortuntely it (V0.5+fixes) still broke standard wp media manager uploads on my system (though fixed other probs), but i will now try your latest release… brb
Hi Anabelle
No worries – thanks for your response. Sorry for my delay also.
Heres a link to a pastebin of changes I made to: custom-menu-images.php, (v0.5) ::
my mods are marked ‘mod jrc …’ – 2 main purposes::
1) fix save_config() so it saves
2) moving all unnecessary css out from php and into my main theme css file (otherwise user cannot easily override these styles since they are included by your app at footer).hope these are of help, pleae get back to me if i can assist.
all best.
hi Merganser – thanks for reply and responses.
i do have a little experience of modifying the media uploader pop up – basically cribbing someone elses plugin that used this technique. its a bit fiddly too – ajax callbacks etc , as i recall.
also, i did run into problems with two plugins running simultaneously on same page, both invoking/using common js liraries. (as i recall i was forced to just commented out the 2nd plugins include eventually.)
raises the question of how best to package and ship such (js) dependencies. ie. whether to consider writing a single plugin to install/manage all required js libraries, etc. wp core does a lot of good stuff with ‘load order’ parameters and strict version dependencies, etc (where they are implemented) – but it could do with a little refinement i think.
i’ll see if i can dig up some more info.
good news youre planning to do taxonomies. keep up the good work.
hi merganser,
many thanks for your response. sorry i’ve bee out of the loop a little – extreamly busy here at present.
i will try out the new version and post to pastebin over the next day or so, and get back to you. (yes wp js dependency trees/lists seem a bit fussy to me also, so far.)
i’ll get back to you shorthly.
many thanks.
merganser – sure, will do. however, i still have a prob with it breaking post, insert media pop-ups (thumbnails dissappear + ‘show’ links become inactive). will post to pasetbin when i have a more relliable fix – unless you can beat me to it.
ps. the ‘mod jrc 260211’ marks above i my own, to indicate changed code (ie.: replacing
array('jquery142'),witharray('jquery'),.… as i thought, it was now objecting to the specified dependency on jquery142 in the same func (seems wp_enqueue_script deps arg means ‘exactly’ that version, rather than ‘that version or later’).
anyway, i made dependencies less specicfic (now just requires ‘any’ version of jquery loaded first). here’s the modded version of function add_admin_scripts (in media-categories.php), that seems to work ok::
[Code moderated as per the Forum Rules. Please use the pastebin]
sorry, spoke too soon. that fix above results in breaking the plugin’s choose-media drop down in edit media item screens.
will continue my investigation…
ok, i think i found the problem, and here is a fix that worked for me::
file: media-categories.php, function add_admin_scripts, around line 188 ::
change from:
wp_enqueue_script('jquery142', 'http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js', false);change to:
/*wp_enqueue_script('jquery142', 'http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js', false);*/– ie. just comment it out.
as far as I know, jquery is loaded by default anyway, so it shouldnt have beeen needed – it was certainly causing a conflict at the back-end, resulting in the symptoms posted above. works fine without.
(ps. this was further complicated on my system, since one of my other plugins had already replaced the standard jquery library with a slightly later (current) version, in order to give me access to the new jquery.easing and other fancy libraries. on investigation however, that plugin (scl_jquery_upgrade), didn’t seem responsible for the conflict that the media-library-categories plugin produced: ie. deactivating it alone, made no difference – rather suprising, since jquery142 was given as dependency, and i was using jquery144).
hope this helps someone.
would be great if –
a) plugin author could take a look at this and confirm change.
b) wordpress could ship current jquery version instead of v1.4.2.errata: that last line number should have been ‘around line 1220 ish’ – ie. still in the updatItem function.
addendum:
further down the line, i find that the above solution doesn’t quite work.
i think the problem lies in the fact that the original image widget JS code redefines (replaces) the standard wp send_to_editor function BUT does not restore it once it has has finished (running the click to upload event).
not such a problem if there are no other widgets using similar technique, but serious breakages if there are (as in my case).
indeed, having backed out all my changes, reverting to the kosha version of the plugin + deactivated all my oher widget plugins, i get the following strange behaviour, intermittently:
when selecting admin, appearance, widgets from the lhs menu, all widget sidebar areas (rhs of the screen), underneath the one containing the image widget, sometimes disappear! at the same time, none of the widgets anywhere on the page respond to click (open) or drag-n-drop. its as if the JS/JQuery is completely missing/broken. refreshing the browser whilst still on the widgets admin page sometimes make them appear again, and all behave properly.
As i add back more widget plugins the situation changes slightly, in that refreshing the browser (whilst on the widgets admin page), has the effect of toggling the error on and off – ie. refresh breaks it, refresh again, and everything works again, etc, etc.
invocation of the problem also seems slightly random (sometimes the widget admin screen behaves fine then, suddenly will break again as described above.)
just to complicate matters further, i have come across many reports of the core wp widget admin page breaking in a similar (though not identical) way, all on its own.
i’m about to try some further code changes (to restore original send_to_editor js funcs as i just suggested) and will report back any improved results.
it does seem however, there are some problems need addressing here in image-widget.js.
can anyone replicate these symptoms? fix them?
any feedback appreciated.