Skip to content

Facebook

Colin Robbins edited this page Aug 21, 2021 · 11 revisions

This feature compares the members of a private Facebook group with the data in SCM. It reports on members of the Facebook group that are not club members, or associated with club members (e.g., parent).

There are two modes of operation:

  • Interactive
  • File Interface

Usage

Windows GUI

Select the Analyse Facebook option for the Reports menu.

Command Line

scm --facebook

Configuration

Interactive

To use the Interactive mode you first need to configure Selenium. Then add the following to config.yaml:

facebook:
  groups:
    - https://www.facebook.com/groups/YourGroupName/

XPATH

(Requires SCM_HELPER version 1.7.5 or above)

In order to analyse a page, SCM_HELPER needs to know the XPATH to the data elements on the Facebook web page. Facebook occasionally change this, so it needs to be configured. To do so add the following to your config:

facebook:
  xpath:
    prefix: '//*[contains(@id,"mount_0_0")]'
    suffix: '//div/div/div[2]/div[1]/div/div/div[1]/span/span/span'
    elements:  "/a"
    elements2:  "/span"

DO NOT worry, about not understanding the above - this page will be updated with the latest config needed. If the Facebook interface does not work, come back here and add the latest config from above.

Using Interactive Mode

When you select Analyse Facebook a web browser will open up, accessing Facebook. SCM-Helper will pop up a message inviting you to login. You will need to logon to Facebook in the browser window. Once you have logged in, press Yes on the SCM-Helper pop-up window. SCM-Helper will now control the browser to access the data required.

File interface

There is a file based interface, in which you download the Facebook page to a file. The file is then processed. To use this mode use need to use a web browser.

Google Chrome

  1. Open chrome, and navigate to the Facebook group members page
  2. Scroll down and keep scrolling to you can see all members.
  3. Right click a select “inspect element”
  4. Select the body element of the HTML and right click to copy / copy element.
  5. Open a file an paste the text in. It will look a mess, but thats OK!
  6. Save to a file in the SCM config directory.
  7. Add the filename to config.yaml in the Facebook section
facebook:
  files:
    - downloaded_filename.html

NB. Using save page as html DOES NOT work, as it omits the scrolled data.

Other browsers

May be easier, not sure!

Clone this wiki locally