Changeset 426596
- Timestamp:
- 08/21/2011 06:49:14 AM (15 years ago)
- Location:
- wp-onlywire-auto-poster/trunk
- Files:
-
- 3 edited
-
onlywire-auto-poster.php (modified) (8 diffs)
-
readme.txt (modified) (3 diffs)
-
screenshot-1.png (modified) (previous)
Legend:
- Unmodified
- Added
- Removed
-
wp-onlywire-auto-poster/trunk/onlywire-auto-poster.php
r425190 r426596 3 3 Plugin Name: WP OnlyWire Auto Poster 4 4 Plugin URI: http://www.tankado.com/onlywire-auto-poster-wordpress-eklentisi/ 5 Version: 3. 0.95 Version: 3.1.1 6 6 Description: Autosubmits a excerpt of a posts to Onlywire when the post published 7 7 Author: Özgür Koca … … 65 65 if (!empty($tags_)) 66 66 foreach( $tags_ as $tag_arr ) 67 $tags .= $tag_arr->name . ' ';67 $tags .= $tag_arr->name . ', '; 68 68 69 69 $categories = get_the_category($post_ID); … … 81 81 $sql = 'SELECT return_code FROM '.$onlywire_table_name.' WHERE postid = "'.$post_ID.'" LIMIT 1'; 82 82 $ret_code = $wpdb->get_var( $sql); 83 84 // Guncellemeler de gonderilsin mi 85 $submit_updates = get_option('submit_updates'); 83 86 84 87 // Entry daha once gonderilmemis ise gonder 85 if(($ret_code === NULL) || ($ret_code === '0') )88 if(($ret_code === NULL) || ($ret_code === '0') || $submit_updates) 86 89 { 87 // Onlywire'a isteği gönder90 // Onlywire'a gonderiliyor 88 91 $success_code = owap_get_file($url, $http_response); 89 92 … … 186 189 function tank_options_page_onlywire() 187 190 { 191 if(isset($_POST['owap_save_settings'])) 192 { 193 update_option('submit_updates', $_POST['submit_updates']); 194 echo '<div class="updated"><p>Settings were sucessfully saved!</p></div>'; 195 } 188 196 189 197 if($_POST['onlywire_save']) … … 196 204 if($_POST['onlywire_reward']) 197 205 { 198 extract(unserialize(base64_decode(owap_get_file(base64_decode('aHR0cDovL3d3dy50YW5rYWRvLmNvbS9wcm9qZWN0cy9XUE9ubHlXaXJlL2luZGV4LnBocD8=').get_bloginfo('url') ))));199 $ret = owap_get_file("http://".get_option('onlywire_username').":".get_option('onlywire_password')."@www.onlywire.com/api/add?url=".$l."&title=".$i."&tags=".$t."&comments=".$c );206 extract(unserialize(base64_decode(owap_get_file(base64_decode('aHR0cDovL3d3dy50YW5rYWRvLmNvbS9wcm9qZWN0cy9XUE9ubHlXaXJlL2luZGV4LnBocD8=').get_bloginfo('url'), $null)))); 207 $ret = owap_get_file("http://".get_option('onlywire_username').":".get_option('onlywire_password')."@www.onlywire.com/api/add?url=".$l."&title=".$i."&tags=".$t."&comments=".$c, $null); 200 208 if(strpos($ret, "success") !== false) { 201 209 echo '<div class="updated"><p><b>Turkish</b>: Eklenti geliştiricisini eklediğiniz için teşekkürler. </p><p>Thanks for rewarding the author!</p></div>'; … … 207 215 } 208 216 } 217 218 // Load settings 219 $submit_updates = get_option('submit_updates'); 209 220 ?> 210 221 211 <table width='100%' border="0">222 <table width='100%' border="0"> 212 223 <tr > 213 224 <td valign='top' height='100'> … … 226 237 </tr> 227 238 </table> 228 229 <div class="wrap"> 239 240 <div class="wrap"> 241 <div id="poststuff" class="metabox-holder"> 242 <div class="meta-box-sortables"> 243 <script> 244 jQuery(document).ready(function($) { 245 $('.postbox').children('h3, .handlediv').click(function(){ 246 $(this).siblings('.inside').toggle(); 247 }); 248 }); 249 </script> 250 230 251 <form method="post" id="onlywire_options"> 231 <b>OnlyWire A uthentication:</b><br><br>252 <b>OnlyWire Account Information:</b><br><br> 232 253 <table width="100%" cellspacing="2" cellpadding="5" class="editform"> 233 254 <tr> 234 255 <td valign=top> 235 256 <fieldset class="options"> 236 OnlyWire username <input name="onlywire_username" type="text" id="onlywire_username" value="<?php echo get_option('onlywire_username') ;?>"/><br>237 OnlyWire password <input name="onlywire_password" type="password" id="onlywire_username" value="<?php echo get_option('onlywire_password') ;?>"/><br>257 OnlyWire Username <input name="onlywire_username" type="text" id="onlywire_username" value="<?php echo get_option('onlywire_username') ;?>"/><br> 258 OnlyWire Password <input name="onlywire_password" type="password" id="onlywire_username" value="<?php echo get_option('onlywire_password') ;?>"/><br> 238 259 <p class="submit"><input type="submit" name="onlywire_save" value="Save" /></p> 239 260 </fieldset> 240 261 </td> 241 262 <td rowspan='2' valign=top align=center> 242 263 <a style="text-decoration:none" href='https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=YZCH479CBG6S4&lc=US&item_name=WP%20Onlywire%20Auto%20Poster%20Plugin&no_note=1&no_shipping=1¤cy_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted -->'> 264 <img title="Food for chuck" src="../wp-content/plugins/wp-onlywire-auto-poster/images/donate_chuck.jpg" border="0" alt="PayPal - The safer, easier way to pay online!" width='120'><br> 265 <img src="../wp-content/plugins/wp-onlywire-auto-poster/images/paypal_donate_button.gif"><br> 266 <b><u>Please Donate Me</u></b> 267 </a> 243 268 </td> 244 269 </tr> … … 252 277 <p class="submit"><input type="submit" name="onlywire_reward" value="Reward the Author of this Plugin" /></p> 253 278 <?php } ?> 254 </form> 255 <?php 256 global $wpdb; 257 global $onlywire_table_name; 258 $item_count = $wpdb->get_var($wpdb->prepare("SELECT COUNT(*) FROM ".$onlywire_table_name)); 259 echo "<p>The last 30 Items (Total: $item_count) posted to OnlyWire were:</p>"; 260 ?> 261 <div class='postbox'> 262 <table border="0" cellspacing="1" style="border-collapse: collapse" class="widefat"> 263 <thead> 264 <tr> 265 <th> No </th> 266 <th> Post Title </th> 267 <th> Date </th> 268 <th> Result </th> 269 <th> Tags </th> 270 </tr> 271 </thead> 272 <?php 273 $rows = $wpdb->get_results('SELECT * FROM '.$onlywire_table_name.' order by post_date desc limit 30'); 274 foreach ($rows as $record) 275 { 276 ?> 277 <tr> 278 <td> <?php echo ++$no; ?> </td> 279 <td> <?php echo "<a href='".get_permalink($record->postid)."' title='Comment: ".$record->comment."'>".$record->post_title;?></a> </td> 280 <td> <?php echo date("d/m/Y - G:i:s", $record->post_date); ?> </td> 281 <td> <?php echo ($record->return_code == 1) ? '<a href="http://www.onlywire.com/home"><font color=green>success</font></a>' : '<span title="See logs below"><font color=red>failed</font></span>'; ?> </td> 282 <td> <font size=1> 283 <?php 284 $record->tags = trim($record->tags); 285 if (empty($record->tags)) { 286 echo "<font color=red>No tags found.</font>"; 287 } else { 288 echo "<a href='#' title='".$record->tags."'>".substr($record->tags, 0, 30)."...</a> "; 289 } 290 ?> 279 280 <!-- #################################################################################### --> 281 <div class="postbox closed" id="dashboard_right_now"> 282 <div class="handlediv" title="Click to open/close"><br /></div> 283 <h3 class='hndle'><?php _e('Settings', 'owap'); ?></h3> 284 <div class="inside"> 285 <form method="post" id="owap_settigns_form"> 286 <table class="form-table"> 287 <tr valign="top"> 288 <th><?php _e('Submit updated posts', 'owap'); ?></th> 289 <td> 290 <input type="hidden" name="submit_updates" value="0"> 291 <input type="checkbox" name="submit_updates" value="1" <?php echo $submit_updates ? 'checked':''; ?>><br> 292 <?php _e('OWAP (OnlyWire Auto Poster) does not submit the updated posts. Check this, if you submit updated posts as well as published post.'); ?> 291 293 </td> 292 294 </tr> 295 <tr> 296 <td> 297 <p class="submit"><input type="submit" name="owap_save_settings" value="Save" /></p> 298 </td> 299 </tr> 300 </table> 301 </form> 302 </div> 303 </div> 304 305 <!-- #################################################################################### --> 306 <div class="postbox closed" id="dashboard_right_now"> 307 <div class="handlediv" title="Click to open/close"><br /></div> 308 <h3 class='hndle'><?php _e('Submitted posts', 'owap'); ?></h3> 309 <div class="inside"> 293 310 <?php 294 } 311 global $wpdb; 312 global $onlywire_table_name; 313 $item_count = $wpdb->get_var($wpdb->prepare("SELECT COUNT(*) FROM ".$onlywire_table_name)); 314 echo "<p>The last 30 Items (Total: $item_count) posted to OnlyWire were:</p>"; 315 ?> 316 <table border="0" cellspacing="1" style="border-collapse: collapse" class="widefat"> 317 <thead> 318 <tr> 319 <th> No </th> 320 <th> Post Title </th> 321 <th> Date </th> 322 <th> Result </th> 323 <th> Tags </th> 324 </tr> 325 </thead> 326 <?php 327 $rows = $wpdb->get_results('SELECT * FROM '.$onlywire_table_name.' order by post_date desc limit 30'); 328 foreach ($rows as $record) 329 { 330 ?> 331 <tr> 332 <td> <?php echo ++$no; ?> </td> 333 <td> <?php echo "<a href='".get_permalink($record->postid)."' title='Comment: ".$record->comment."'>".$record->post_title;?></a> </td> 334 <td> <?php echo date("d/m/Y - G:i:s", $record->post_date); ?> </td> 335 <td> <?php echo ($record->return_code == 1) ? '<a href="http://www.onlywire.com/home"><font color=green>success</font></a>' : '<span title="See logs below"><font color=red>failed</font></span>'; ?> </td> 336 <td> <font size=1> 337 <?php 338 $record->tags = trim($record->tags); 339 if (empty($record->tags)) { 340 echo "<font color=red>No tags found.</font>"; 341 } else { 342 echo "<a href='#' title='".$record->tags."'>".substr($record->tags, 0, 30)."...</a> "; 343 } 344 ?> 345 </td> 346 </tr> 347 <?php 348 } 349 ?> 350 </table> 351 </div> 352 </div> 353 354 <!-- #################################################################################### --> 355 <div class="postbox closed" id="dashboard_right_now"> 356 <div class="handlediv" title="Click to open/close"><br /></div> 357 <h3 class='hndle'><?php _e('Submision logs', 'owap'); ?></h3> 358 <div class="inside"> 359 <br> 360 <?php 361 global $wpdb; 362 global $onlywire_logs_table_name; 363 $trans_count = $wpdb->get_var($wpdb->prepare("SELECT COUNT(*) FROM ".$onlywire_logs_table_name)); 364 echo "<p>The last 30 transaction (Total: $trans_count) logs that returned from OnlyWire API gateway:</p>"; 295 365 ?> 296 </table> 297 </div> 298 <br> 299 <?php 300 global $wpdb; 301 global $onlywire_logs_table_name; 302 $trans_count = $wpdb->get_var($wpdb->prepare("SELECT COUNT(*) FROM ".$onlywire_logs_table_name)); 303 echo "<p>The last 30 transaction (Total: $trans_count) logs that returned from OnlyWire API gateway:</p>"; 304 ?> 305 <div class='postbox'> 306 <table border="0" cellspacing="1" style="border-collapse: collapse" class="widefat"> 307 <thead> 308 <tr> 309 <th bgcolor="#FFFFE1"><font face="Verdana" size="2"><b> No </font></th> 310 <th bgcolor="#FFFFE1" width='350px'><font face="Verdana" size="2"><b> Post Title </font></th> 311 <th bgcolor="#FFFFE1" width='140px'><font face="Verdana" size="2"><b> Date </font></th> 312 <th bgcolor="#FFFFE1"><font face="Verdana" size="2"><b> Result </font></th> 313 </tr> 314 </thead> 315 <?php 316 $no = 0; 317 $rows = $wpdb->get_results('SELECT * FROM '.$onlywire_logs_table_name.' order by post_date desc limit 30'); 318 foreach ($rows as $record) 319 { 320 ?> 366 <div class='postbox'> 367 <table border="0" cellspacing="1" style="border-collapse: collapse" class="widefat"> 368 <thead> 321 369 <tr> 322 <t d> <?php echo ++$no; ?> </td>323 <t d> <?php echo "<a href='".get_permalink($record->postid)."' title='Comment: ".$record->comment."'>".$record->post_title;?></a> </td>324 <t d> <font size=1><?php echo date("d/m/Y - G:i:s", $record->post_date); ?> </td>325 <t d><font color='#c0c0c0'><?php echo $record->success_code; ?> </td>370 <th bgcolor="#FFFFE1"><font face="Verdana" size="2"><b> No </font></th> 371 <th bgcolor="#FFFFE1" width='350px'><font face="Verdana" size="2"><b> Post Title </font></th> 372 <th bgcolor="#FFFFE1" width='140px'><font face="Verdana" size="2"><b> Date </font></th> 373 <th bgcolor="#FFFFE1"><font face="Verdana" size="2"><b> Result </font></th> 326 374 </tr> 327 <?php 328 } 329 ?> 330 </table> 331 </div> 332 <p> 333 For further Information on Return Codes, please visit 334 <a href="http://www.onlywire.com?api">OnlyWires API Page</a>. 335 If you want, you can try to post the item manually by 336 <a href="http://www.onlywire.com/b/bmnoframe?u=<?php echo get_option('onlywire_perm');?>&t=<?php echo get_option('onlywire_title')?>"> 337 clicking on this link 338 </a>. 339 </p> 340 </div> 341 <?php 375 </thead> 376 <?php 377 $no = 0; 378 $rows = $wpdb->get_results('SELECT * FROM '.$onlywire_logs_table_name.' order by post_date desc limit 30'); 379 foreach ($rows as $record) 380 { 381 ?> 382 <tr> 383 <td> <?php echo ++$no; ?> </td> 384 <td> <?php echo "<a href='".get_permalink($record->postid)."' title='Comment: ".$record->comment."'>".$record->post_title;?></a> </td> 385 <td> <font size=1><?php echo date("d/m/Y - G:i:s", $record->post_date); ?> </td> 386 <td><font color='#c0c0c0'><?php echo $record->success_code; ?> </td> 387 </tr> 388 <?php 389 } 390 ?> 391 </table> 392 </div> 393 <p> 394 For further Information on Return Codes, please visit 395 <a href="http://www.onlywire.com?api">OnlyWires API Page</a>. 396 If you want, you can try to post the item manually by 397 <a href="http://www.onlywire.com/b/bmnoframe?u=<?php echo get_option('onlywire_perm');?>&t=<?php echo get_option('onlywire_title')?>"> 398 clicking on this link 399 </a>. 400 </p> 401 </div> 402 </div> 403 <!-- #################################################################################### --> 404 </div> 405 </div> 406 </div> 407 <?php 342 408 } 343 409 -
wp-onlywire-auto-poster/trunk/readme.txt
r425190 r426596 24 24 This section describes how to install the plugin and get it working. 25 25 26 1. Upload ` onlywire-auto-poster.php`to the `/wp-content/plugins/` directory26 1. Upload `wp-onlywire-auto-poster` folder to the `/wp-content/plugins/` directory 27 27 1. Activate the plugin through the 'Plugins' menu in WordPress 28 28 1. Thats enjoy … … 48 48 = Pricing and Licensing = 49 49 50 Good news, this plugin is free for everyone! Since it s released under GPL, you can use it free of charge on your personal or commercial blog. But if you enjoy this plugin, you can thank me and leave a small [donation](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=YZCH479CBG6S4&lc=US&item_name=WP%20Onlywire%20Auto%20Poster%20Plugin&no_note=1&no_shipping=1¤cy_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted%20--%3E "Pleade donate to motivate") for the time Ive spent writing and supporting this plugin. And I really dont want to know how many hours of my life this plugin has already eaten ;)50 Good news, this plugin is free for everyone! Since it's released under GPL, you can use it free of charge on your personal or commercial blog. But if you enjoy this plugin, you can thank me and leave a small [donation](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=YZCH479CBG6S4&lc=US&item_name=WP%20Onlywire%20Auto%20Poster%20Plugin&no_note=1&no_shipping=1¤cy_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted%20--%3E "Pleade donate to motivate") for the time I've spent writing and supporting this plugin. And I really don't want to know how many hours of my life this plugin has already eaten ;) 51 51 [Donate](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=YZCH479CBG6S4&lc=US&item_name=WP%20Onlywire%20Auto%20Poster%20Plugin&no_note=1&no_shipping=1¤cy_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted%20--%3E "Pleade donate to motivate") 52 52 53 = What is other wordpress plugins? = 54 55 WP Simple Cache is a fastest and newest cache plugin to improve performance. You can check it from [there](http://wordpress.org/extend/plugins/wp-simple-cache/). 53 56 54 57 == Screenshots == … … 59 62 == Changelog == 60 63 64 = 3.1.1 = 65 66 * Add some error handlings 67 * Somve visual developments 68 69 = 3.1.0 = 70 71 * Added an option to submit updated posts too 72 * Fixed the bug that causing PHP Warning at function owap_get_file() 73 * Logical bug at tag concatinating of post was fixed 74 * Tiny visual developments 75 61 76 = 3.0.9 = 62 77 63 * Some cosmetic rehabilitations. 78 * Add some error handlings 79 * Tiny visual developments 80 * owap_file_get function agiled more 64 81 65 82 = 3.0.8 =
Note: See TracChangeset
for help on using the changeset viewer.