Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
plugins-topic
SimplePress 5 - CubePoints Integration Plugin
Avatar
cubehouse
Member
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 3:15 am

Tada!

Good API, was a little tricky to get the hang of, but all works in the end 🙂

Would like to know how to make "nice" error messages when CubePoints isn't detected.

http://cubehouse.org/blog/wp-c.....Points.zip

Thoughts/Feedback/Testing appreciated 🙂

 

Officially the first third-party Simple:Press 5 plugin 😀

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 10:50 am

I was hoping you were working on that!   outstanding!  have to give this a shot a bit later - but dont have cubepoints [Image Can Not Be Found]

so plenty of hooks and filters for you?

what do you mean by nice message?  where do you want it?  in the admin? on plugin page?  banner at top?  please advise and we can help

Avatar
cubehouse
Member
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 1:27 pm

Howdy!
When cubePoints isn't installed, wanted a nice error message above the options menu in the admin area. At the moment just some bold text. Don't know if there is a function to make Simple:press style admin error messages or alerts.

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 1:49 pm

we do have a admin panel header area you can add messages... I just committed a change with a hook when its done so you can add stuff... after svn up, you will want

sph_admin_panel_header

Avatar
cubehouse
Member
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 1:53 pm

Great, will play with that later. 🙂
Funny rally, my idea was to make a WordPress point plugin and I was going to call it cubePoints because of my username... but somebody already made one... with the same name... So, I made this instead!

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 1:56 pm

well, arent you the guy who did the earlier integration of cubepoints and simple:press? for the 4.x version?  it was a bit limited given the api we had...

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 2:00 pm

couple questions on the plugin...

how do you deal with posts in moderation? or do you just get at point of post?  wonder if we have a hook/action when the moderation occurs?

do you subtract points for deleted post?

looks good!

Avatar
cubehouse
Member
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 2:18 pm

Nope! Never been involved with Simple:Press until recently. Just picked cubePoints because I'm planning on using it on my site in the near future. Mark me a Simple:Press noob with significant PHP/WordPress debugging skills 😉

Only deal with new post/topic at the moment.Is only basic so far. Not sure how to deal with eleted posts, since if you change the number of points for a new post, then delete it, the users loses more points... will probably add it in under the assumption admins dont reglarly change point values.

Don't know how moderation stuff works yet, when it's approved, does it call a different action then? Currently just picking out data from the $newpost object from the new post action hook.Basing the points added on $newpost->action == "topic" etc. (is it action/type? on my tablet atm... you know what I mean...)

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 2:25 pm

yeah just add a hook for when posts approved... was there but not very friendly... new one is:

sph_post_approved

an array of approved posts since you can approve all posts in a topic at once...

so yeah when creating the post topic, if post_status == 0, it needs moderation, ie approval..

but you are hooked (its a filter) into: sph_new_forum_post

I would probably hook (an action) into: sph_post_create

which is actually after the topic or post has been created... you are currently before so it might get rejected as spam or other... you will still get $newpost passed to you...

if post_status == 1 then award points... if post_status == 0 then might wait for the post approval hook to actually award the points...

just food for thought...

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jul 6, 2011 - 2:27 pm

and just for reference...

https://simple-press.com/suppo.....tegration/

Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 619
Members: 17362
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10127
Posts: 79625