Changeset 1267707
- Timestamp:
- 10/17/2015 01:07:22 AM (10 years ago)
- Location:
- my-optional-modules/trunk
- Files:
-
- 6 edited
-
class.mom-mediaembed.php (modified) (2 diffs)
-
class.mom-reddit.php (modified) (2 diffs)
-
function.functions.php (modified) (1 diff)
-
includes/css/css.css (modified) (1 diff)
-
plugin.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
my-optional-modules/trunk/class.mom-mediaembed.php
r1263667 r1267707 21 21 22 22 $myoptionalmodules_pluginscript = sanitize_text_field ( get_option ( 'myoptionalmodules_pluginscript' ) ); 23 24 $close = null; 25 $div = null; 23 26 24 27 if ( filter_var ( $url , FILTER_VALIDATE_URL ) !== false ): … … 265 268 if ( $output ): 266 269 if ( 'user_info_image' != $class ): 267 echo "<div class='embed'>"; 268 echo $output; 270 $div .= "<div class='embed'>"; 269 271 else: 270 echo'<div class="user_info_image">';271 echo $output;272 endif;273 echo '</div>';272 $div .= '<div class="user_info_image">'; 273 endif; 274 $close .= '</div>'; 275 return $div . $output . $close; 274 276 else: 275 277 if ( true == $display_text ): 276 echo "<div class='gumboard_content_comment'><p><a rel='nofollow' href='{$url}'>Attached link</a> <small>(<a href='//{$host}'>{$host}</a>)</small></p></div>"; 278 $output .= "<div class='gumboard_content_comment'><p><a rel='nofollow' href='{$url}'>Attached link</a> <small>(<a href='//{$host}'>{$host}</a>)</small></p></div>"; 279 return $output; 277 280 endif; 278 281 endif; -
my-optional-modules/trunk/class.mom-reddit.php
r1264763 r1267707 114 114 115 115 if ( $sub ): 116 $url = "https://reddit.com/r/{$sub}/.json?limit={$amount}&t={$from}";117 $ json = json_decode ( file_get_contents ( $url ) );116 $url_1 = "https://reddit.com/r/{$sub}/"; 117 $url_2 = "https://reddit.com/r/{$sub}/.json?limit={$amount}&t={$from}"; 118 118 elseif ( $thread ): 119 $url = "https://reddit.com/comments/{$thread}/.json";120 $ json = json_decode ( file_get_contents ( $url ) );119 $url_1 = "https://reddit.com/comments/{$thread}/"; 120 $url_2 = "https://reddit.com/comments/{$thread}/.json"; 121 121 elseif ( $search ): 122 122 if ( $sub ): … … 125 125 $restrict = null; 126 126 endif; 127 $url = "https://www.reddit.com/search.json?q={$search}&limit={$amount}&t={$from}&sort={$sort}{$restrict}"; 128 $json = json_decode ( file_get_contents ( $url ) ); 129 endif; 127 $url_1 = "https://www.reddit.com/search.json?q={$search}"; 128 $url_2 = "https://www.reddit.com/search.json?q={$search}&limit={$amount}&t={$from}&sort={$sort}{$restrict}"; 129 endif; 130 131 if ( $url_1 && $url_2 ): 132 $json = json_decode ( @file_get_contents ( $url_2 ) ); 133 endif; 134 135 130 136 131 137 if ( $header ): -
my-optional-modules/trunk/function.functions.php
r1264465 r1267707 43 43 return $rtrn; 44 44 } 45 46 function mom_url_headers ( $url ) { 47 $headers = get_headers ( $url ); 48 return substr ( $headers [ 0 ] , 9 , 3 ); 49 } -
my-optional-modules/trunk/includes/css/css.css
r1264584 r1267707 129 129 top: 5%; 130 130 width: 14%; 131 } 132 .myoptionalmodules-subreddit .reddit-item-listing .feed { 133 padding: 5px; 134 width: 45%; 131 135 } 132 136 .myoptionalmodules-subreddit .reddit-item-listing .listing-date { -
my-optional-modules/trunk/plugin.php
r1264761 r1267707 3 3 Plugin Name: My Optional Modules 4 4 Description: Optional modules and additions for Wordpress. 5 Version: 11.1.6 6 Author: boyevul 5 Version: 11.1.7 6 Author: sodapopgun 7 Github Plugin URI: sodapopgun/my-optional-modules 8 Github Branch: master 7 9 */ 8 10 -
my-optional-modules/trunk/readme.txt
r1264761 r1267707 1 1 === My Optional Modules === 2 Contributors: boyevul2 Contributors: sodapopgun 3 3 Tags: reddit, meta, og, twitter, facebook, google, description, title, 404, comments, version, pingbacks, author, date, archives, disable, horizontal, galleries, font awesome, share, RSS, DNSBL, garbage, removal, trash, footer, exclude, remove, hide, front page, search results, authors, categories, tags, single post, miniloop, attachment, media, embedder, oEmbed 4 4 Requires at least: 4.1 5 5 Tested up to: 4.3.2 6 Stable tag: 11.1. 66 Stable tag: 11.1.7 7 7 8 8 An assortment of functions to enhance WordPress. … … 151 151 152 152 == Changelog == 153 = 11.1.7 = 154 * *Release Date - 16th, October, 2015* 155 * Author update 156 * @error suppression for file_get_contents on [mom_reddit] .json feeds in the off-chance the linked feed should stop working (for whatever reason) 157 153 158 = 11.1.6 = 154 159 * *Release Date - 13th, October, 2015*
Note: See TracChangeset
for help on using the changeset viewer.