1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Submit 3.5

Discussion in 'Plugins' started by Nick, Aug 1, 2009.

  1. Nick

    Nick Well-Known Member

    Submit
    Version: 3.5
    Author: Nick Ramsay
    Created: 2009/07
    Last Updated:
    2013/06/04
    Tested on: Hotaru 1.3.0 ~ 1.5.1
    Plugins Required: None
    Plug & Play: Yes
    Supported: Yes

    Description
    Post and view stories, automatically fetch the title, preview and modify your submission, edit posts, enable which components to show (e.g. description, author, date), filter posts to selected users and if the plugins are activated, tags and categories, too. Option to disable the submit form without disabling the plugin. Includes submission moderation options with email notification for moderators. Recent additions include post archiving and editorials, i.e. posts without a link.

    Instructions
    1. Upload the "submit" folder to your plugins folder.
    2. Install it from Plugin Management in Admin.
    3. Edit settings by clicking "Submit" in the Admin sidebar.

    Revision History
    v.3.5 2013/06/03 - shibuya246 - Add id for form name
    v.3.4 2013/05/29 - shibuya246 - Added daily limit in addition to 24 hr period limit
    v.3.3 2013/05/18 - Nick - Prevent default pages title being used in post title
    v.3.2 2010/08/12 - Nick - Fixed edit post redirect so you're returned to Post Manager if that's where you came from
    - Nick - Replaced "logged in" tests with submission permission checks instead
    - Nick - Minor fix for & in urls when redirecting from login to submit step 2
    v.3.1 2010/08/01 - Nick - Fixed an undefined index error and truncated source urls to prevent sidebar overlap
    v.3.0 2010/07/20 - Nick - Redirects logged out users to the login page and returns them to submit step 2
    v.3.0 2010/07/20 - Nick - Fix for truncated titles and French accents on submit step 2
    v.2.9 2010/07/10 - Nick - CSS Fixes for form item widths.
    v.2.8 2010/05/22 - Nick - Removed requirement to have SB Base installed
    v.2.7 2010/05/09 - Nick - Fixes for "invalid url" error with non-roman characters in urls
    v.2.6 2010/05/07 - Damon - Fix for clearing the temporary data table during post submission
    v.2.5 2010/04/26 - Nick - If the story being submitted already exists, the user is redirected to it
    Nick - Renamed httprequest file and class to avoid clash with a PHP extension
    v.2.4 2010/04/01 - Nick - Split theme_index_top into multiple functions for easier extending (no templates/css/js changes)
    v.2.3 2010/03/28 - Nick - New plugin hook in Submit step 1 error checking
    v.2.2 2010/03/21 - Nick - Updated for Hotaru 1.1.3 (no templates/css/js changes)
    v.2.1 2010/02/15 - Nick - Removed CSRF check from submission step 1
    v.2.0 2010/02/11 - Nick - Bug fixes for character problems and stripped HTML
    v.1.9 2009/12/16 - Nick - Updated for compatibility with Hotaru 1.0
    v.1.8 2009/11/29 - Nick - Added plugin hooks in post descriptions
    v.1.7 2009/11/27 - Nick - Bug fix for wrong order of sidebar posts. Ability to block domain extensions, e.g. .ru
    v.1.6 2009/11/26 - Nick - Bug fix for default user settings plus user option for links opening source or post urls
    v.1.5 2009/11/25 - Nick - New hook in submit_edit_post.php (used by Comments 1.1)
    v.1.4 2009/11/03 - Nick - Post archiving, editorials, and improved filtering
    v.1.3 2009/10/28 - Nick - Bug fix for sending trackbacks
    v.1.2 2009/10/24 - Nick - Bug fix for strange symbols in fetched titles in Submit step 2
    v.1.1 2009/10/23 - Nick - Users under moderation get their posts sent to 'pending'
    v.1.0 2009/10/22 - Nick - New plugin hook for Akismet compatibility
    v.0.9 2009/10/17 - Nick - Updates for compatibility with Post Manager plugin
    v.0.8 2009/10/15 - Nick - Bug fixes for missing post url and slashed apostrophes, and new hook
    v.0.7 2009/10/04 - Nick - Updates for compatibility with Hotaru 0.7
    v.0.6 2009/10/01 - Nick - Updates for compatibility with Hotaru 0.6
    v.0.5 2009/08/31 - Nick - Made changes to accommodate the Search plugin
    v.0.4 2009/08/30 - Nick - Combined settings into a single database record
    v.0.3 2009/08/28 - Nick - Updates for compatibility with Hotaru 0.5
    v.0.2 2009/08/19 - Nick - Added breadcrumb navigation, allowable HTML tags, posts per page option, and more.
    v.0.1 2009/08/13 - Nick - Released first version

    Please click "Rate Thread" and give this plugin a rating. Thank you.

     

    Attached Files:

    Last edited by a moderator: Feb 6, 2010
    vulcangz, Sv9t, skorpyo and 2 others like this.
  2. davidshq

    davidshq Member

    Does this automatically grab trackbacks?
     
  3. Nick

    Nick Well-Known Member

    You bet it does! :D
     
  4. angolanmade

    angolanmade Well-Known Member

    I just noticed that after changing a story status from "new" or "top" to "pending" or "buried" the story still displays itself under the category that it was posted under. Also how/where do we manage pending, buried stories?
     
    Last edited: Oct 15, 2009
  5. Nick

    Nick Well-Known Member

    Yeah, I still have work to do on that, and there's no Post Manager yet. :eek:

    Update: All fixed and done. Post Manager is here.
     
  6. JonH

    JonH Admin & Design

    I did a test story with link breaks or what we used to call carriage returns and the text was still all together after submit. Maybe the next version could use the nl2br() function.

    http://www.w3schools.com/PHP/func_string_nl2br.asp

    EDIT: This feature might mess up the flow of the story summary page, maybe make it optional or only featured on the story page only.
    I think SWCMS is like this?
     
    Nick likes this.
  7. Nick

    Nick Well-Known Member

    Attention theme designers! Version 1.6 of Submit includes changes to the list.php template:

    Change 1 (approx.line 28):
    Before:
    PHP:
    if ($hotaru->current_user->vars['settings']['new_tab']) { $target 'target="_blank"'; }
    After:
    PHP:
    if ($hotaru->current_user->vars['settings']['new_tab']) { $target 'target="_blank"'; }
    if (
    $hotaru->current_user->vars['settings']['link_action']) { $open 'source'; }
    Change 2 (approx.line 65):
    Before:
    PHP:
    <a href='<?php echo $hotaru->post->origUrl?><?php echo $target?>><?php echo $hotaru->post->title?></a>
    After:
    PHP:
    <?php if ($open == 'source') { ?>
         <a href='<?php echo $hotaru->post->origUrl?><?php echo $target?>><?php echo $hotaru->post->title?></a>
    <?php } else { ?>
         <a href='<?php echo $hotaru->url(array('page'=>$hotaru->post->id)); ?><?php echo $target?>><?php echo $hotaru->post->title?></a>
    <?php ?>
    That's because of a new setting which lets users choose how links should open - whether they should go to the source url or the post page on your site.
     
  8. Nick

    Nick Well-Known Member

    Updated: v.2.2 2009/03/31 - Nick - Updated for Hotaru 1.1.3 (no templates/css/js changes)
     
  9. Nick

    Nick Well-Known Member

    Updated: v.2.3 2010/03/28 - Nick - New plugin hook in Submit step 1 error checking

    I was surprised I hadn't already put a hook in the checkErrors1 function, but now that I have, you can make a whole range of plugins to allow or restrict post submission at the first step. For example, my Ego Squasher plugin (coming very soon)!
     
  10. Nick

    Nick Well-Known Member

    Updated: v.2.4 2010/04/01 - Nick - Split theme_index_top into multiple functions for easier extending (no templates/css/js changes)
     
  11. pablo

    pablo New Member

    Hi Nick,

    I noticed that if my description is too long I get "Nothing submitted" error. But I think it should tell you the reason it was not submitted, and at the moment it doesn't.

    Thanks,
    Pablo
     
  12. Nick

    Nick Well-Known Member

    I haven't seen that problem before. The Submit plugin doesn't have a maximum length for descriptions, and the maximum you can store in the database is 65535 characters. That's pretty big!

    So please provide all the information for the post you are trying to submit. There must be a different reason for the error.

    Thanks.
     
  13. shibuya246

    shibuya246 Hotaru Developer Staff Member Admin

    Updated v.2.5 2010/04/26 - Nick - If the story being submitted already exists, the user is redirected to it
    Nick - Renamed httprequest file and class to avoid clash with a PHP extension
    [Hotaru 1.2]
     
  14. Nick

    Nick Well-Known Member

    Updated again! :D v.2.6 2010/05/07 - Damon - Fix for clearing the temporary data table during post submission (Hotaru 1.2)
     
  15. richrf

    richrf New Member

    I would like the ability to Submit a story that links to Journal entry. Currently I have to submit without a URL and then hack the database with a URL link. Doable but tedious. I hope you consider this increased functionality in some future release of this plugin. Thanks.

    Rich
     
  16. adriansonline

    adriansonline New Member

    Noticed an issue. If you disable "post submission" checkbox in Submit Plugin admin cannot edit posts.
     
  17. adriansonline

    adriansonline New Member

    Anyone found a fix for this...really stumped. I would also suggest a way for only editor to add submissions from the backend. Is there maybe an easy way to remove submit from the menu bar?
     
    Last edited: Sep 19, 2010
  18. Nick

    Nick Well-Known Member

    Okay, it's a minor bug, but easily worked around. Just give submit and edit post permissions to the user groups you want to be able to submit posts. Do that from User Manager -> Edit Default Permissions.
     
    adriansonline likes this.
  19. RSP

    RSP New Member

    Hello,

    This doesn't happen all the time but quite often, when submitting a bookmark I got this error:

    Notice: unserialize() [function.unserialize]: Error at offset 200 of 255 bytes in /home/****/****/******/public_html/content/plugins/submit/libs/SubmitFunctions.php on line 296.

    And when I try it again (without reload) I got this error:
    Notice: Undefined index: submit_editorial in /home/****/*****/******/public_html/content/plugins/submit/submit.php on line 560

    Notice: Undefined index: submit_orig_url in /home/******/*****/*****/public_html/content/plugins/submit/submit.php on line 561

    Any solution?

    thanks in advance!
     
  20. Nick

    Nick Well-Known Member

    Hi RSP, I'll need more information, especially your site url and an example of a link that generates the error. Thanks.
     

Share This Page