Any User Twitter Feed
Embed anyone’s Twitter Timeline using only their username, or display tweets based on a keyword. Fully compatible with the latest Twitter API and guaranteed to work even with the forthcoming twitter changes! Features: Embed timelines using only username Show tweets which contain a keyword Highly configurable, many visual options Using Twitter 1.1 API with authentication No JavaScript Go Pro and Get Many More Features! WordPress Any User Twitter Feed PRO PRO FEATURES! Embed timelines using only username New! Slider/Scroll Option (pro version only) New! Side Tab Option, so it is shown as a tab on the side of your screen! New! Slider speed control option (pro version only) New! follow me button, which can use any username of your choice. (pro version only) 6. New! Conflict switch to help it work with other jQuery plugins (pro version only) Show tweets which contain a keyword Highly configurable, many visual options Using Twitter 1.1 API with authentication GO PRO AND GET FREE TICKET SUPPORT!
Solr Search for WordPress
Search is critical for your site, but the default search for WordPress leaves a lot to be desired. Improve your user experience with the Apache Solr search engine for your WordPress website. Fast results, with better accuracy. Enables faceting on fields such as tags, categories, author, and page type. Indexing and faceting on custom fields. Drop-in support for WP_Query with the solr_integrate parameter set to true. Completely replaces default WordPress search, just install and configure. Completely integrated into default WordPress theme and search widget. Very developer-friendly: uses the modern Solarium library Development This plugin is under active development on GitHub: https://github.com/pantheon-systems/solr-power Please feel free to file issues there. Pull requests are also welcome! See CONTRIBUTING.md for information on contributing. For further documentation, such as available filters and working with the SolrPower_Api class directly, please see the project wiki: https://github.com/pantheon-systems/solr-power/wiki You may notice there are two sets of tests running, on two different services: PHPUnit test suite against a Solr instance. The Behat test suite against a Pantheon site, to ensure the plugin’s compatibility with the Pantheon platform. Both of these test suites can be run locally, with a varying amount of setup. PHPUnit requires the WordPress PHPUnit test suite, and access to a database with name wordpress_test. If you haven’t already configured the test suite locally, you can run bash bin/install-wp-tests.sh wordpress_test root '' localhost. You’ll also need access to a running Solr instance, in order to run the unit tests against Solr. Behat requires a Pantheon site with Solr enabled. Once you’ve created the site, you’ll need install Terminus, and set the TERMINUS_TOKEN, TERMINUS_SITE, and TERMINUS_ENV environment variables. Then, you can run ./bin/behat-prepare.sh to prepare the site for the test suite. Note that dependencies are installed via Composer and the vendor directory is not committed to the repository. You will need to run composer install locally for the plugin to function. You can read more about Composer here WP-CLI Support This plugin has WP-CLI support. All Solr Power related commands are grouped into the wp solr command, see an example: $ wp solr usage: wp solr check-server-settings or: wp solr delete [ ...] [--all] or: wp solr index [--batch= ] [--batch_size= ] [--post_type= ] or: wp solr info [--field= ] [--format= ] or: wp solr optimize-index or: wp solr repost-schema or: wp solr stats [--field= ] [--format= ] See 'wp help solr ' for more information on a specific command. You can see more details about the commands using wp help solr: **NAME** wp solr **DESCRIPTION** Perform a variety of actions against your Solr instance. **SYNOPSIS** wp solr **SUBCOMMANDS** check-server-settings Check server settings. delete Remove one or more posts from the index. index Index all posts for a site. info Report information about Solr Power configuration. optimize-index Optimize the Solr index. repost-schema Repost schema.xml to Solr. stats Report stats about indexed content. WP_Query Integration Use Solr in a custom WP_Query instead of querying a database. Add 'solr_integrate' => true to the query arguments. NOTE: Currently, only basic queries, tax_query, meta_query and date_query are supported. See examples/example.custom_WP_Query.php for an example. A meta_query can use the following compare operators: '=' '!=' '>' '>=' ' Boosting relevancy score by publish date The following guidance can be used to extend the Solr index and modify boosts beyond just this example. To support math functions on dates, you must add a custom schema.xml to Solr and reindex with the new schema. Add the following to schema.xml: --> --> Add the following to your functions.php file. post_date ); // Matches format required for TrieDateField $doc->setField( 'post_date_iso', gmdate( 'c\Z', $post_time ) ); return $doc; } add_filter( 'solr_build_document', 'my_solr_build_document', 10, 2 ); /** * Hooks into query processor, Dismax, to add publish date boost. * See: https://www.metaltoad.com/blog/date-boosting-solr-drupal-search-results */ function my_solr_dismax_query( $dismax ) { $dismax->setQueryParser( 'edismax' ); $dismax->setBoostQuery( 'recip(abs(ms(NOW/HOUR,post_date_iso),3.16e-11,1,1))' ); return $dismax; } add_filter( 'solr_dismax_query', 'my_solr_dismax_query' ); is_solr_query Filter The is_solr_query filter controls whether Solr should be used for a specific query. Parameters: $enabled (bool): Indicates whether Solr should be used for the query. Defaults to true if the query is a search or if solr_integrate is set in the query. $query (WP_Query): The current WordPress query object. Return: bool: true to enable Solr for the query, false to disable it. add_filter( ‘is_solr_query’, function( $enabled, $query ) { if ( $query->is_category( ‘news’ ) ) { return false; } return $enabled; }, 10, 2 ); Custom schema file path By default, custom schema is sourced from wp-content/uploads/solr-for-wordpress-on-pantheon/schema.xml. This can be overridden with an absolute path using the the solr_power_customer_schema_file_path filter. Parameters: * $custom_schema_file_path (string): Default path to a custom schema file Return: * string: Absolute path to a custom schema.xml file. add_filter('solr_power_customer_schema_file_path', function($custom_schema_file_path) { return '/absolute/path/to/schema.xml'; }); Common issues Failing to post the schema.xml will result in an error during indexing, “Missing post_date_iso field.” If you have the field and type in the schema, but don’t add the solr_build_document filter, you will get a similar error. If the post_date_iso field is missing from the index, Solr will ignore this boost and return regular results. Trying to use a regular date field for the boost query will result in an error in the request instead of results. Explicit Commit vs Autocommit Once solr has sent the data to the solr server, solr must COMMIT the data to the index and adjust the index and relevancy ratings accordingly before that data can appear in search results. By default, Solr Search for WordPress has auto-commit disabled. The index is committed when the uncommitted item is two minutes old, or the cron runs. By default, the cron runs on the Pantheon platform every hour. When autocommit is enabled, Solr Search for WordPress commits data when it sends every post. When running on Pantheon, we recommend leaving autocommit disabled to aid overall site performance. To enable autocommit, add the following to wp-config.php or an mu-plugin. define( 'SOLRPOWER_DISABLE_AUTOCOMMIT', false ); To force-commit data outside of a normal cron run, from the command line, you can run the command below or simply force a cron-run. wp solr commit