Help me test my latest mod under development; sNews polls, with Ajax
filed under: sNews CMS
Once again, I'm back at MOD'ing sNews. This time around I've gotten pretty ambitious and starting writing an Ajax polls mod for sNews. Why? Well, all the other CMS's seem to have them, plus I've been devouring the pages of my Ajax book and really starting to learn javascript in general.
Thus far I think I've completed a nice looking front-end, seen here. This is a "ground up" script, meaning I've written everything from scratch on this one, there has been no shoe-horning/cramming/stuffing exiting code into sNews.
For that reason, I will probably need a considerable amount of time to get the admin section working in sNews. I would like you to test these polls and let me know if you encounter anything kludgey.
The code has been written to degrade gracefully, aka it's "unobtrusive", if you disable javascript in your browser, you won't (shouldn't) have any problem voting or viewing results, it just won't be as smooth as with Ajax, and you can only view/vote on one poll per page at a time, whereas with Ajax you can vote on unlimited numbers.
Again, this is only the front-end, while I'm writing the admin section, please help me test, vote, leave me a comment and let me know if it worked as expected, what browser & OS you're using, etc. Especially let me know if it doesn't work as expected. Remember, I can only make a mod as good as the feedback I receive, I can't fix problems that I'm not aware of. :)
OK, with all the begging and pleading out of the way, here is a list of the currently implemented features;
- Each poll is unique, and you can add as many polls to a page or article as you like.
- Polls can be placed into articles, pages "extras", or hard-coded into your index.php page.
- Polls prevent multiple voting by both IP check, as well as cookies.
- Poll styling can easily be controlled by a separate stylesheet. The bars are drawn with percentages and will always expand accordingly.
- Does not require jQuery, while I love jQuery personally, I'm aware that many people are apprehensive about adding the large-ish libraries to their sites.
Again, this is only for testing at this point, please don't ask me when it will be completed, because the answer is always "when it's ready" :)
19 comments
Commenting is closed at this time.
Commenting is closed at this time.
Categories
Recent Entries
Recent Comments
- Dede (I checked it today in a shop. GT2 had some troubles with six ...)
- Matt (Bintang, You need to re-direct the url, try ...)
- jesth (Ohh.. why didn't I think of that, thanks alot.)
- Matt (Dede, I don't have Gran Turismo 2, any of the 2nd+ generation ...)
- Matt (Jesth, Just change the if condition, instead of looking for ...)
- jesth (Hi (again) Was wondering, is it possible to make it ...)
- Bintang Sembilan (Matt, thanks for your modd. I have apply it to my ...)
- Dede (Hello there. Can you check something for me? I want to buy ...)
- Matt (I think it's a driver issue Terrence, or it was a driver issue. ...)
Popular Entries
- Light-weight related articles mod for sNews 1.7 (4.5/5)
- Image / math hybrid captcha version 2, vastly improved (4.42/5)
- 1024x600 netbook wallpapers of Evangeline Lilly (4.4/5)
- Compact archives for sNews 1.7 (4.4/5)
- sNews Ajax Polls mod now available (4.38/5)
- Pretty date and comments bars in sNews CMS (4.35/5)
- Page caching mod for sNews 1.7 (4.33/5)
- Gravatar mod for sNews 1.7 (4.29/5)
- An improved tag cloud for sNews 1.7 (4.29/5)
May 1st, 2009 at 5:10 pm
Congratz for this mod :)
May 2nd, 2009 at 3:02 pm
Awsome mod, really usefull, I always wondered when someone would try make a mod like this.
Can't wait for it to be finished, keep up the good work.
May 3rd, 2009 at 12:11 am
Matt, all vote boxes looks good and works swimmingly in Safari 4 (Public Beta) on Mac OS X 10.5.6/Intel iMac. Nice job.
May 3rd, 2009 at 1:57 pm
The AJAX Poll mod is looking first-rate so far Matt. I am looking forward to this being released once you get the Admin system done.
May 3rd, 2009 at 2:00 pm
Forgot to note - Completed the polls with IE7 on an XP machine - performed and displayed perfectly.
May 3rd, 2009 at 9:58 pm
Thanks everyone! I took the weekend off, my little one's 3rd birthday today :D, but I hope to get back hacking away on the admin section some more this week.
I'll post any major updates here.
May 4th, 2009 at 3:46 am
Hello Matt
1 star more for this Mod to come.
In some where explanations for the voter is needed will you provide a link to the explanation page (displaying the results too?)
May 4th, 2009 at 6:43 am
Oh oh.
I've upgraded IE to IE8 ans there's a problem: after having voted the box result disappears.
May 4th, 2009 at 7:54 am
Sven, what OS, Vista or XP? I just upgraded my XP Pro machine here to IE8, rebooted and the polls/voting all works perfect.
I'll try my Vista machine tonight.
May 4th, 2009 at 12:23 pm
On XP, Matt.
I just tried again.
1st vote: correct.
2nd vote: box disappear.
3rd vote: ok but 2nd vote box still away.
May 4th, 2009 at 12:25 pm
Reloading the page makes the box re-appears but the previous vote wasn't recorded as it proposes to re-vote.
May 4th, 2009 at 12:46 pm
It's my special "Sven clause" I build into all my scripts;
if ($user === 'Sven') { do_something_buggy(); }lol... I will look into it
May 4th, 2009 at 2:43 pm
UPDATE:
The basic admin is done, overview, create new poll, edit existing polls, reset votes, and deleting polls.
Added poll code embed function to the buttons menu, you just need the ID of the poll, also added the embed code for inserting into articles, pages, etc, like youtube embed links, etc.
Now I have to get some odd bits of language into the lang file.
May 5th, 2009 at 2:26 am
:-D :-D :-D
You don't have to. When IE interprets JS it's always buggy. And this morning I re-tried after having deleted cache and cookies: second box is still out.
May 5th, 2009 at 2:56 am
Worst then IE for java script is only Opera.That browsers cant do nothing.Hey Matt Happy Birthday to your little one!
May 5th, 2009 at 7:13 am
Thanks Sasha, funny thing is it works fine in Opera when I tested it.
Sven, so it's showing you the vote form, and when you try to vote it shows you the results, but doesn't record your vote? Does it give you the "back to poll" link, or only when you refresh the page does it show the voting form again?
May 5th, 2009 at 11:27 am
Re-tried: same issue.
After my vote the 2nd box is not displayed at all.
If I reload the page the 2nd box is being displayed but doesn't show the results as my vote not been recorded.
See this HC:
http://lemesle.free.fr/nomasis/matt's-poll.png
May 5th, 2009 at 11:47 am
Sven, I think IE8 is just clunky. I've installed the latest release of it on all 3 of my machines now and the voting works just fine, but I can't log into the admin using IE8 on my XP Pro machine.
The fact it worked fine on the other 2 polls kind of rules out the code, b/c the code is identical.
I will add a few more polls to the article to test with.
May 6th, 2009 at 1:46 am
eh eh...
this morning it works. All votes are registered and box are displayed.