Drupal Feed Aggregator and Twitter integration - drupal

I am currently using the Drupal feed aggregator built-in module to aggregate a bunch of RSS feeds. I also have the Twitter module installed. I want to set things up so that all the new posts from the feed aggregator get sent out to twitter, but unfortunately the twitter module doesn't allow for that right now. Does any one know of another way to do this or a work around? I know I can create a custom module to do this but didn't want to go down that road unless I had to

My understanding of the Twitter module (it's been a while since I've used it) is that it will send out notifications to Twitter on new node creation or update. Would you be interested in the Feeds module as an alternative to the core aggregator in Drupal? That would create nodes from each feed item, instead of the Aggregator, which only creates database entries that expire. The Feeds module approach would create nodes, which would then theoretically automatically ping Twitter. See also http://drupal.org/node/403274 which I think is a similar feature request.

Related

Separate plugins or one giant plugin on WP

I’m building a WP plugin to enhance a website, and come to an interrogation with the workflow.
Basically, I have to create a custom post type, assorted with several custom taxonomies, which will be used/displayed on the frontend and backend, and create a backend section in order to interact with our CRM, and Supabase via their respective APIs (service centralisation).
All of the second part is only intended to be used/displayed on the admin section, to logged users.
However, when creating/saving a custom post type, or when viewing it from the frontend, I have to make a GET request to the CRM to fetch some data and store it in JSON somewhere (24h cache).
That I can do.
At the moment, I worked on the CPT part, and made a class to interact with the CRM, with credentials stored in wp_options. I now have to work on the backend part.
My question is: what are the best practices here? Keep it in a single plugin or divide into several plugins?
And if I divide, how should I turn it? 2 plugins, one for the CPT and one for the backend? Or go even deeper, and get the CRM and Supabase their own simple plugin, and call their methods to make my requests?
I am short of ideas here, so if you encountered this situation, could you enlighten me?

How to create rss status filter

I've seen the bluemix status rss feed on
https://status.eu-gb.bluemix.net/api/feed/notifications/feed.rss
and I've seen the same feed and dashboard on https://status.eu-gb.bluemix.net/
However, on the dashboard it's possible to filter the feed.
Is it possible to filter the rss feed as well?
For example "/feed/notifications/feed.rss?type=incident&region=eu-gb"
Or alternatively are there individual feed sources for each region/type/etc?
Can't find this documented anywhere -- even when using the powerful google machine
Unfortunately, this functionality is not available because the RSS feed does not differentiate by notification type nor region. If this functionality would help you, you can add it to the IBM Bluemix Ideas site, which is available at the following URL: https://ibm-bluemix.uservoice.com/forums/311383-ibm-bluemix-ideas

How to create an offline form for submitting WP posts

You may have seen WP plugins that allow guests to submit posts. Those submissions proceed to the WP posts area where the admin can edit/publish them.
I want to create a form like this that I can install on my (and other people's) computers, so they can fill out the form fields for a WP post, save offline, then send to my WP site when ready.
Can anyone tell me the steps involved, and, if there is a description for what type of thing this is, please let me know to aid my search.
I am learning code at present and want to learn while building tools.
Thanks
Hi hope I can give you some hints with this answer.
I don't know what programming language you would like to use, but for the communication with your Wordpress blog you could use the WP API to create a post over REST API. It offers a API to create and edit your Wordpress Posts over HTTP.
Your programm just have to check if an connection is possible and then execute the API calls.
You could use an database to store all created post and then call the Create Post Task with the POST Method over HTTP for each post saved offline.
When the creation was successful you could update your offline database, so that the post is marked as already created.

Moodle and Drupal 7 integration

I would like to display a list of available Moodle courses and available places for each of the corses on a Drupal site.
Is there a simple way of integrating Moodle and Drupal so that when a Max enrolled users is set in Moodle, the Drupal enrolment form witll display the number of available places, and disable the ability of users enrolling in to courses which have no places left?
There is authentication plugin available moodle-drupalservices for SSO between both systems
You can read more about it from module document
If you want to fetch detail of moodle courses in drupal then web service is the best way to achieve it, you just need to create web services client in drupal to consume moodle services
http://docs.moodle.org/dev/Category:Web_Services
use core_course_get_courses web service function don't need to pass any value to it, it will fetch all available courses detail from moodle.
There is a module for moodle integration in drupal - Moodle Connector. There are some other related module to which enhance the integration further like Commerce Moodle, which let you sell the course & you get drupal commerce to handle your selling..great right?
But if you are working in D6, then you will have to check another module Moodleconnect, but it's still in DEV version, so may be you will have to work on it.
https://www.drupal.org/project/issues/moodle_views will allow you to list courses using a Drupal View. This module doesn't (yet) allow you to display the places available, but if you still need this functionality I could probably add it relatively easily.

Wordpress XMLRPC advice needed

I have been tasked with creating an API for retrieving and adding content to Wordpress from a flash application and legacy CMS (non-PHP). My plan is to utilise the existing default xmlrpc endpoint and add any additional functionality by creating a plugin which hooks into xmlrpc_methods.
A previous attempt had been made by another developer based on the following code:
http://blog.5ubliminal.com/posts/remote-control-wordpress-blog-xmlrpc-api/
This code looks unwieldy and poorly documented to me and my preference would be to use this approach:
http://kovshenin.com/archives/custom-xml-rpc-methods-in-wordpress/
I would be grateful if anyone with experience in this area could confirm that:
I will be able to distinguish between separate blogs in an MU installation when both retrieving and posting data via XMLRPC
I will be able to retrieve and post to custom fields
writing a plugin is the way to go.
We do not have the option of using Wordpress 3 as it is still in Beta and we are under time pressure.
I would greatly appreciate appreciate any input / advice.
Many thanks,
I've worked with WordPress' XMLRPC system before (using a WP-Hive installation with multiple separate blogs similar to a WPMU set-up). The new approach you're using is definitely simpler and easier to implement (I tried the 5ubliminal one as well the first time).
Whether or not you can distinguish between separate blogs in a MU installation depends entirely on how you build your handler function. You can build it to distinguish the separate blogs, to only function on specific blogs, or to treat the entire system as a single WordPress site. It's all up to you.
By "handler function" I mean a custom function you define to handle XMLRPC requests that call a specific, custom method (not necessarily the default WordPress methods). For example, I use XMLRPC in all my plug-ins to report back installation progress and errors -
each plug-in makes an XMLRPC call to a custom handler (method) on my server.
Yes, you can retrieve and post to custom fields.
Absolutely writing a plug-in is the way to go. The only other options are to change core files (BAD idea) or to build it into your theme, in which case it could ONLY be used on MU sites using that theme. Build it as a site-wide MU plug-in that can be controlled on a site-by-site basis by the global admin.
Wordpress XMLRPC offers various functionalities which can be harvested easily. I have used IXR_Library to parse the XML requests/responses. Currently with very small piece of code i can easily posts, fetch, edit and delete Posts in Wordpress based blogs either self hosted or on wordpress.com sites.
http://www.hurricanesoftwares.com/wordpress-xmlrpc-posting-content-from-outside-wordpress-admin-panel/ (reference)
When you have multiple blogs hosted via MU you will need site ID of all those blogs which will become the first parameter for $params (in our case 0 should be replaced with site_id).
In the reference i gave above you will see the option to fetch and post to all created custom fields (unfortunately, you can't create custom fields on the fly from my script)
You are welcome to write a WP plugin to do all of this, be my guest and let me know if you need my help. I have used the same technique to post to blogger, tumblr, Wordpress and Posterous using their API's. I hope this helps.

Resources