Skip to content

Commit

Permalink
added menu-order, removed query limit, added usage to readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Christoph S. Ackermann committed Jan 19, 2019
1 parent ae96002 commit 0e891b9
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 13 deletions.
35 changes: 29 additions & 6 deletions README.md
Expand Up @@ -4,6 +4,15 @@

Add Social Media Post Type to WordPress

## Usage

Just add shortcode [some-accounts] to your content.

Or within a template:
``` php
<?php echo do_shortcode( '[some-accounts]' ); ?>
```

## Filters

* Allows you to extend social media options
Expand All @@ -15,20 +24,34 @@ function add_kununu( $options ) {
add_filter( 'some_options', 'add_kununu' );
```

## Version: 0.1
## Version: 1.1.0

## Person Responsible

Pascal Knecht @pascalknecht
Christoph S. Ackermann @acki

## Contributors

* Pascal Knecht @pascalknecht

## Functionality
* Christoph S. Ackermann @acki
* Lucas Schnüriger
* Sven von Arx
* Pascal Knecht

## Changelog

### 1.1.0 2019-01-19

* Added usage section to README
* Added menu-order to Query and removed post limit (was 5)

### 1.0.1 2017-07-12

* Added composer.json

### 1.0.0 2017-03-01

* Added README and filter

### 0.1

* Added filter to add custom some accounts
* Added filter to add custom some accounts
5 changes: 4 additions & 1 deletion templates/social-shortcode.php
Expand Up @@ -3,6 +3,9 @@
global $wp_query;
$social = get_posts(array(
'post_type' => 'someaccs',
'orderby' => 'menu_order',
'order' => 'ASC',
'numberposts' => -1,
));

foreach($social as $acc) :
Expand All @@ -13,4 +16,4 @@

<a class="some-link" href="<?=$link[0];?>" title="<?=$title;?>" target="_blank"><i class="fa fa-<?=$icon[0];?>"></i><span class="some-title"><?=$title;?></span></a>
<?php endforeach; ?>
<?php wp_reset_postdata();?>
<?php wp_reset_postdata();?>
12 changes: 6 additions & 6 deletions wpplugin.some-accounts.php
@@ -1,11 +1,11 @@
<?php
/*
Plugin Name: cubetech Wordpress SoMe Accounts
Plugin URI: http://cubetech.ch
Description: A plugin to add your social media accounts
Version: 1.0
Author: Lucas Schnüriger
Author URI: http://cubetech.ch
Plugin Name: cubetech WordPress SoMe Accounts
Plugin URI: https://github.com/cubetech/wpplugin.some-accounts
Description: A plugin to add your social media accounts to your theme or content
Version: 1.1.0
Author: cubetech GmbH
Author URI: https://www.cubetech.ch
*/

if ( !defined( 'RWMB_VER' ) ) {
Expand Down

0 comments on commit 0e891b9

Please sign in to comment.