Download the PHP package janwebdev/symfony-social-post-bundle without Composer

On this page you can find all versions of the php package janwebdev/symfony-social-post-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package symfony-social-post-bundle

Latest Stable Version Total Downloads

What's this?

This is a Symfony bundle written in PHP 8.1 that wraps janwebdev/social-post - an easy way for simultaneous publishing to Facebook and Twitter. It was cloned from this repo and refactored to support PHP 8.1+ and Symfony 6.4 LTS and upper.


How to install it?

Recommended way is through Composer

composer require janwebdev/symfony-social-post-bundle

Integration with Symfony

Add social networks configuration

# Usually part of config.yml
social_post:
    publish_on: [facebook, twitter]         # List which Social networks you will be publishing to and configure your access to them as shown below
    providers:
        facebook:
            app_id: "YOUR-FACEBOOK-APP-ID"
            app_secret: "YOUR-FACEBOOK-APP-SECRET"
            default_access_token: "YOUR-FACEBOOK-NON-EXPIRING-PAGE-ACCESS-TOKEN"
            page_id: "YOUR-FACEBOOK-PAGE-ID"
            enable_beta_mode: true
            default_graph_version: "v15.0"
            persistent_data_handler: "memory"         # Optional, also supports "session". Default is "memory".
            pseudo_random_string_generator: "openssl" # Optional, also supports "mcrypt" and "urandom". Default is "openssl".
            http_client_handler: "curl"               # Optional, also supports "stream" and "guzzle". Default is "curl".
        twitter:
            consumer_key: "YOUR-TWITTER-APP-CONSUMER-KEY"
            consumer_secret: "YOUR-TWITTER-APP-CONSUMER-SECRET"
            access_token: "YOUR-TWITTER-ACCESS-TOKEN"
            access_token_secret: "YOUR-TWITTER-ACCESS-TOKEN-SECRET"

Register the bundle

# Usually your app/AppKernel.php
<?php
// ...
class AppKernel extends Kernel
{
    public function registerBundles()
    {
        $bundles = [
            // ...
            new \Janwebdev\SocialPostBundle\SocialPostBundle(),
        ];
        return $bundles;
    }
    // ...
}

Post a test message

# Some Symfony container aware class
<?php
//...
$message = new \Janwebdev\SocialPost\Message('your test message');
$container->get('social_post')->publish($message);

Additional help

Facebook doesn't support non-expiring user access tokens. Instead, you can obtain a permanent page access token. When using such tokens you can act and post as the page itself. More information about the page access tokens from the official Facebook documentation. Some Stackoverflow answers (here and here) also can of help.


License

This package is licensed under the MIT License.


All versions of symfony-social-post-bundle with dependencies

PHP Build Version
Package Version
Requires php Version >=8.1
janwebdev/social-post Version ^2.0
symfony/framework-bundle Version >=v6.4.0
symfony/yaml Version >=v6.4.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package janwebdev/symfony-social-post-bundle contains the following files

Loading the files please wait ....