WordPress.org

Plugin Directory

Changeset 157117


Ignore:
Timestamp:
09/22/09 23:24:52 (5 years ago)
Author:
ryelle
Message:

adding 1.9.0, see changelog for changes

Location:
post-from-site
Files:
8 added
5 edited

Legend:

Unmodified
Added
Removed
  • post-from-site/trunk/pfs_display.js

    r123267 r157117  
    1 function pfsopen(){ 
    2     document.getElementById('pfs_postbox').style.display = 'block'; 
     1/* Currently it's almost pointless to have this as an external file, 
     2 * but eventually I'll learn more about AJAX fanciness and will need 
     3 * the extra space. 'Til then, oh well. If it bothers you, then you 
     4 * probably know how to fix it. */ 
     5function getElementsByClassName(classname, node)  { 
     6    if(!node) node = document.getElementsByTagName("body")[0]; 
     7    var a = []; 
     8    var re = new RegExp('\\b' + classname + '\\b'); 
     9    var els = node.getElementsByTagName("*"); 
     10    for(var i=0,j=els.length; i<j; i++) 
     11        if(re.test(els[i].className))a.push(els[i]); 
     12    return a; 
     13} 
     14function pfsopen(id){ 
     15    postboxes = getElementsByClassName('pfs_postbox'); 
     16    for (i in postboxes){ 
     17        postboxes[i].style.display = 'none'; 
     18    } 
     19    document.getElementById('pfs_postbox'+id).style.display = 'block'; 
    320    return; 
    421} 
    522 
    6 function pfsclose(){ 
    7     document.getElementById('pfs_postbox').style.display = 'none'; 
     23function pfsclose(id){ 
     24    document.getElementById('pfs_postbox'+id).style.display = 'none'; 
    825    return; 
    926} 
  • post-from-site/trunk/pfs_style.php

    r123267 r157117  
    99?> 
    1010 
    11 #pfs_postbox{ 
     11.pfs_postbox{ 
    1212    position:absolute !important;  
    1313    top: 200px; 
    14     left: 200px; 
     14    left: 350px; 
    1515    z-index: 100000; 
    1616    width:600px; 
     
    2626    font-size:9pt; 
    2727} 
    28 #pfs_postbox #closex { 
     28.pfs_postbox #closex { 
    2929    float:right; 
    3030    margin:0; 
     
    3232    padding:0; 
    3333} 
    34 #pfs_postbox #closex a { 
     34.pfs_postbox #closex a { 
    3535    padding:2px 5px; 
    3636    text-decoration:none; 
     
    3939    background-color:#BBB; 
    4040} 
    41 #pfs_postbox #closex a:hover { 
     41.pfs_postbox #closex a:hover { 
    4242    background-color:#AAA; 
    4343} 
    44 #pfs_postbox textarea { 
     44.pfs_postbox textarea { 
    4545    width:550px; 
    4646    margin:5px 25px; 
    4747} 
    48 #pfs_postbox #pfs_span { 
     48.pfs_postbox #pfs_span { 
    4949    padding:7px 0; 
    5050    float:left; 
    5151} 
    52 #pfs_postbox #submit { 
     52.pfs_postbox #submit { 
    5353    float:right; 
    5454    padding:7px 25px; 
    5555} 
    56 #pfs_postbox h4 { 
     56.pfs_postbox h4 { 
    5757    display:inline; 
    5858    font-size:130%; 
    5959    <?php echo (''==$pfs_titlecolor)?"":"color:$pfs_titlecolor;"; ?> 
    6060} 
    61 #pfs_catchecks { 
    62     text-align:left; 
     61#pfs_catchecks, #pfs_tagchecks { 
     62    float:left; 
     63    width:40%; 
     64    text-align:center; 
    6365    padding:10px; 
    6466    padding-top:0; 
    6567    margin-left:35px; 
    6668} 
    67 #pfs_catchecks h4{ 
     69#pfs_meta h4 { 
     70    margin-bottom:0; 
    6871    margin-left:-35px; 
     72    display:block; 
     73    text-align:left; 
    6974} 
    70 #pfs_catchecks input, #pfs_catchecks label { 
     75#pfs_meta input, #pfs_meta label { 
    7176    margin:0; 
    72     padding:7px; 
    7377    margin-top:5px; 
    7478} 
  • post-from-site/trunk/post_from_site.php

    r128300 r157117  
    22/* 
    33 * Plugin Name: Post From Site 
    4  * Plugin URI: http://www.redradar.net/wp/?p=95 
     4 * Plugin URI: http://redradar.net/wp/2009/06/unveiling-post-from-site/ 
    55 * Description: Add a new post directly from your website - no need to go to the admin side. 
    66 * Author: Kelly Dwan 
    7  * Version: 1.6.20 
    8  * Date: 6.20.09 
     7 * Version: 1.9.0 
     8 * Date: 9.21.09 
    99 * Author URI: http://www.redradar.net/wp 
    1010 */ 
    11 /* * * 
    12  * TODO: 
    13  *      Tag support 
    14  *      additional media? 
    15  * SUGGESTIONS: 
    16  *      BuddyPress 
    17  *      non-registered users -> captcha and/or automatic pending status 
    18  *      horizontal category layout rather than vertical 
    19  * SEPERATE PLUGINS: 
    20  *      simple pulldown login box 
    21  *      forked pfs that just does images 
    22  */ 
    23 add_action('wp_head','pfs_includes'); 
     11/* We need the admin functions to use wp_create_category(). */ 
     12require_once(dirname(__FILE__).'/../../../wp-admin/includes/admin.php'); 
     13add_action('init','pfs_includes'); 
    2414function pfs_includes(){ 
    25 $path = split('wp',__FILE__,2); ?> 
    26 <!-- CSS/js added by post-from-site plugin --> 
    27 <script language='javascript' src='<?php echo get_bloginfo('url').dirname($path[1]); ?>/pfs_display.js'></script>  
    28 <link rel="stylesheet" type="text/css" media="screen" href='<?php echo get_bloginfo('url').dirname($path[1]); ?>/pfs_style.php' /> 
     15    $path = split('wp-content',__FILE__,2);  
     16    wp_enqueue_script( 'pfs_display', get_bloginfo('url').'/wp-content'.dirname($path[1]).'/pfs_display.js'); 
     17    wp_enqueue_style( 'pfs_style', get_bloginfo('url').'/wp-content'.dirname($path[1]).'/pfs_style.php'); 
     18?> 
    2919<?php } ?> 
    3020<?php  
     
    3626function post_from_site($cat = '', $linktext = ''){ 
    3727    if (''==$linktext) $linktext = get_option('pfs_linktext'); 
     28    $idtext = $cat.preg_replace('/[^A-Za-z0-9]/','',$linktext); 
     29    $linktext = htmlspecialchars(htmlspecialchars_decode(strip_tags($linktext))); 
    3830    // Javascript displays the box when the link is clicked  
    39     echo "<a id='postlink' onclick='pfsopen()'>$linktext</a><span id='pfs_proc'></span>"; ?> 
    40     <div id="pfs_postbox" style="display:none"> 
    41         <div id="closex"><a onclick="javascript:pfsclose()">x</a></div> 
     31    echo "<a id='postlink' onclick='pfsopen(\"$idtext\")'>$linktext</a><span id='pfs_proc'></span>"; ?> 
     32    <div class="pfs_postbox" id="pfs_postbox<?php echo "$idtext"; ?>" style="display:none" class="pfs_postbox"> 
     33        <div id="closex"><a onclick="javascript:pfsclose('<?php echo "$idtext"; ?>')">x</a></div> 
    4234        <form class="pfs" id="pfs_form" method="post" action="<?php echo ''; ?>" enctype='multipart/form-data'> 
    4335        <input type="hidden" name="MAX_FILE_SIZE" value="<?php echo get_option('pfs_maxfilesize');?>" /> 
    4436        <center><h4>Title:</h4> <input name="title" id="pfs_title" value="" size="50" /></center> 
    4537        <textarea id="postcontent" name="postcontent" rows="20" cols="50"></textarea><br /> 
    46         <?php if (True == get_option('pfs_allowimg')) echo "Image: <input type='file' name='image' id='pfs_image' size='50'>"; ?> 
     38        <?php if (get_option('pfs_allowimg')) echo "Image: <input type='file' name='image' id='pfs_image' size='50'>"; ?> 
     39        <br /> 
     40        <div id="pfs_meta"> 
    4741        <div id="pfs_catchecks"> 
    4842        <?php  
    4943        if (''==$cat){ 
    50             echo "<h4>Categories:</h4><br />"; 
     44            echo "<h4>Categories:</h4>"; 
    5145            $excats = get_option('pfs_excats'); 
    5246            $categories = wp_dropdown_categories("exclude=$excats&echo=0&hide_empty=0"); 
    5347            preg_match_all('/\s*<option class="(\S*)" value="(\S*)">(.*)<\/option>\s*/', $categories, $matches, PREG_SET_ORDER); 
    54             foreach ($matches as $match) 
    55                 echo '<input type="checkbox" name="cats[]" value="'.$match[2].'" class="'.$match[1].'" id="'.$match[1].$match[2].'" /><label for="'.$match[1].$match[2].'">'.$match[3].'</label><br />'; 
     48            echo "<select name='cats[]' size='2' multiple='multiple'>"; 
     49            foreach ($matches as $match){ 
     50                echo "<option value='{$match[2]}'>{$match[3]}</option>"; 
     51            } 
     52            echo "</select><br />\n"; 
     53            if (get_option('pfs_allowcat')) echo "<small>create new:</small><input type='text' name='newcats' value='' size='15' />"; 
    5654        } else { 
    57             echo "<h4>Posting to ".get_cat_name($cat)."</h4><br />"; 
     55            echo "<h4>Posting to ".get_cat_name($cat)." category</h4>"; 
    5856            echo "<input type='hidden' name='cats[]' value='$cat' />"; 
    5957        } 
     58        echo "</div>"; 
     59        echo "<div id='pfs_tagchecks'>"; 
     60        if (get_option('pfs_allowtag')){ 
     61            echo "<h4>Tags:</h4>"; 
     62            $tags = get_tags('get=all'); 
     63            if (''!=$tags) { 
     64                $i = 0; 
     65                echo "<select name='tags[]' size='2' multiple='multiple'>"; 
     66                foreach ($tags as $tag) { 
     67                    echo "<option value='{$tag->name}'>{$tag->name}</option>"; 
     68                } 
     69                echo "</select><br />\n"; 
     70            } 
     71            echo "<small>create new:</small><input type='text' name='newtags' value='' size='15' />"; 
     72        } 
     73        echo "</div></div>"; 
    6074        ?> 
    61         </div> 
     75        <div class="clear"></div> 
    6276        <input type="hidden" name="page" value="<?php get_option(''); ?>" /> 
    6377        <input type="submit" id="submit" name="submit" value="Post" /> 
    6478        </form> 
    6579        <div class="clear"></div> 
    66         <small>Powered by <a href="http://www.redradar.net/wp/?p=95">post-from-site</a> &amp; <a href="http://www.redradar.net/wp">rrn</a></small> 
     80        <small>Powered by <a href="http://www.redradar.net/wp/2009/06/unveiling-post-from-site/">post-from-site</a> &amp; <a href="http://www.redradar.net/wp">redradar</a></small> 
    6781    </div> 
    6882<?php 
    69     if (isset($_POST['submit'])){ 
     83    if (isset($_POST['submit'])){        
    7084        pfs_submit($_POST); 
     85        unset($_POST['submit']); 
    7186    }  
    7287} 
     
    7994function pfs_submit($pfs_data){ 
    8095    foreach($pfs_data as $key=>$value) ${$key} = $value; 
    81     echo "<script language=javascript>document.getElementById('pfs_proc').innerHTML='processing...'</script>"; 
     96    $imgAllowed = 0; 
     97    $success = False; 
    8298    if (is_user_logged_in()) {  
    8399        /* play with the image */ 
    84100        if(''!=$_FILES['image']['tmp_name']){ 
    85101            (getimagesize($_FILES['image']['tmp_name'])) ? $imgAllowed = 1 : $imgAllowed = (''==$_FILES['image']['name']); 
    86         } 
    87         if ($imgAllowed && (''!=$_FILES['image']['tmp_name'])){ 
    88             $upload = wp_upload_bits($_FILES["image"]["name"], null, file_get_contents($_FILES["image"]["tmp_name"])); 
    89             if (False === $upload['error']){ 
    90                 $success = True; 
     102            if ($imgAllowed){ 
     103                $upload = wp_upload_bits($_FILES["image"]["name"], null, file_get_contents($_FILES["image"]["tmp_name"])); 
     104                if (False === $upload['error']){ 
     105                    $success = True; 
     106                } else { 
     107                    echo "<div id=\"alert\">There was an error uploading the image: {$upload['error']}</div><br />"; 
     108                    return; 
     109                } 
    91110            } else { 
    92                 echo "<div id=\"alert\">There was an error uploading the image: {$upload['error']}</div><br />"; 
    93                 return; 
    94             } 
    95         }  
    96         if ($imgAllowed){ 
    97             if ($pfs_data['title'] != '' && $pfs_data['postcontent'] != '') { 
    98                 /* manipulate $pfs_data into proper post array */ 
    99                 global $user_ID; 
    100                 get_currentuserinfo(); 
    101                 $title = $pfs_data['title']; 
    102                 $content = $pfs_data['postcontent']; 
    103                 ($success)?$content .= "<br /><img src='{$upload['url']}' class='postimg' />":''; 
    104                 $categories = $pfs_data['cats']; 
    105                 $postarr = array(); 
    106                 $postarr['post_title'] = $title; 
    107                 $postarr['post_content'] = $content; 
    108                 $postarr['comment_status'] = get_option('pfs_comment_status'); 
    109                 $postarr['post_status'] = get_option('pfs_post_status'); 
    110                 $postarr['post_author'] = $user_ID; 
    111                 $postarr['post_category'] = $categories; 
    112                 $post_id = wp_insert_post($postarr); 
    113                 if (0 == $post_id) echo "<div id=\"alert\">Unable to insert post- unknown error.</div>"; 
    114             } else { 
    115                 echo "<div id=\"alert\">You've left either the title or content empty.</div>"; 
    116             } 
     111                echo "<div id=\"alert\">Only images (.gif, .png, .jpg, .jpeg) are allowed.</div>"; 
     112            } 
     113        } 
     114        /* manipulate $pfs_data into proper post array */ 
     115        if ($title != '' && $postcontent != '') { 
     116            $content = $postcontent; 
     117            global $user_ID; 
     118            get_currentuserinfo(); 
     119            $imgtag = '[!--image--]'; 
     120            if ($success){ 
     121                if (False === strpos($content,$imgtag)) $content .= "<br />$imgtag"; 
     122                $content = str_replace($imgtag, "<img src='{$upload['url']}' class='postimg' />", $content); 
     123            } 
     124            $categories = $cats; 
     125            $newcats = explode(',',$newcats); 
     126            foreach ($newcats as $cat) $categories[] = wp_insert_category(array('cat_name' => trim($cat), 'category_parent' => 0)); 
     127            $newtags = explode(',',$newtags); 
     128            foreach ($newtags as $tag) { 
     129                wp_create_tag(trim($tag)); 
     130                $tags[] = trim($tag); 
     131            } 
     132            $postarr = array(); 
     133            $postarr['post_title'] = $title; 
     134            $postarr['post_content'] = $content; 
     135            $postarr['comment_status'] = get_option('pfs_comment_status'); 
     136            $postarr['post_status'] = get_option('pfs_post_status'); 
     137            $postarr['post_author'] = $user_ID; 
     138            $postarr['post_category'] = $categories; 
     139            $postarr['tags_input'] = implode(',',$tags); 
     140            $postarr['post_type'] = 'post'; 
     141            $post_id = wp_insert_post($postarr); 
     142            if (0 == $post_id) echo "<div id=\"alert\">Unable to insert post- unknown error.</div>"; 
    117143        } else { 
    118             echo "<div id=\"alert\">Only images (.gif, .png, .jpg, .jpeg) are allowed.</div>"; 
     144            echo "<div id=\"alert\">You've left either the title or content empty.</div>"; 
    119145        } 
    120146    } else { 
    121         echo "<div id=\"alert\">You need to be logged in to post. <a href='http://www.redradar.net/wp/wp-login.php?redirect_to=$page'>Log in</a></div><br />"; 
    122     } 
    123     echo "<script language=javascript>document.getElementById('pfs_proc').innerHTML='';</script>"; 
     147        echo "<div id=\"alert\">You need to be logged in to post. <a href=".get_bloginfo('url')."/wp-login.php?redirect_to=$page'>Log in</a></div><br />"; 
     148    } 
    124149    return; 
    125150}  
     
    132157    add_option('pfs_excats', 0); 
    133158    add_option('pfs_allowimg', 0); 
     159    add_option('pfs_allowcat', 1); 
     160    add_option('pfs_allowtag', 1); 
    134161    add_option('pfs_post_status', 'publish'); 
    135162    add_option('pfs_comment_status', 'open'); 
     
    157184    var m = re.exec(document.getElementById('pfs_mfs').value); 
    158185    if (m == null) { 
    159         alert("Not a properly formatted filesize"); 
     186        //alert("Not a properly formatted filesize"); 
     187        document.getElementById('pfs_mfs').style.border="1px solid #880000"; 
     188        document.getElementById('filesize_alert').innerHTML='Default: 30MB<br />Not a valid filesize'; 
    160189    } else { 
    161190        var size = 0; 
     
    165194        else if (m[2] == 'GB') size = m[1]*1024*1024*1024; 
    166195        else if (m[2] == 'TB') size = m[1]*1024*1024*1024*1024; 
     196        document.getElementById('pfs_mfs').style.border="1px solid #DFDFDF"; 
     197        document.getElementById('filesize_alert').innerHTML='Default: 30MB'; 
    167198        document.getElementById('pfs_mfsHidden').value = size; 
    168199    } 
     
    170201function genCode(){ 
    171202    if (document.getElementById("cat").value == ''){cat = "''";} else {cat=document.getElementById("cat").value;} 
    172     document.getElementById('gendCode').innerHTML = "&lt;?php if (function_exists('post_from_site')) {post_from_site("+cat+",'"+document.getElementById('pfs_indlinktxt').value+"');} ?&gt;"; 
     203    linktext = document.getElementById('pfs_indlinktxt').value.replace(/'/g, "\\'"); 
     204    linktext = linktext.replace(/"/g, "&amp;quot;"); 
     205    document.getElementById('gendCode').innerHTML = "&lt;?php if (function_exists('post_from_site')) {post_from_site("+cat+",'"+linktext+"');} ?&gt;"; 
    173206} 
    174207</script> 
     
    191224 
    192225            <table class="form-table"> 
    193                 <tr><td>What text do you want do display as the link text?</td><td><input type='text' name='pfs_linktext' value='<?php echo get_option('pfs_linktext');?>' /></td></tr> 
     226                <tr><td>What text do you want do display as the link text?</td><td><input type='text' id='pfs_linktext' name='pfs_linktext' value='<?php echo get_option('pfs_linktext');?>' /></td></tr> 
    194227                <tr><th colspan='2'>User Permissions</th></tr> 
    195                 <tr><td>What categories can't quickpost users post to (ie, which to exclude)? <small>comma seperated values, please.</small></td><td><input type='text' name='pfs_excats' value='<?php echo get_option('pfs_excats');?>' /></td><td>Default: none</td></tr> 
    196                 <tr><td>Allow users to upload an image (will be attached to end of post)?</td><td><select name='pfs_allowimg'><option value='1' <?php echo (get_option('pfs_allowimg'))?'selected':'';?>>Yes</option><option value='0' <?php echo (get_option('pfs_allowimg'))?'':'selected';?>>No</option></select></td><td>Note: Images automatically uploaded to 'uploads' directory of wp-content -- just like uploading through the write-post/write-page pages.</td></tr> 
    197                 <tr><td>Maximum file size for uploaded images?</td><td><input type='text' id='pfs_mfs' onblur='javascript:filesize_bytes()' value='<?php echo display_filesize(get_option('pfs_maxfilesize'));?>' /></td><td>Default: 30MB</td></tr> 
     228                <tr><td>What categories can't quickpost users post to (ie, which to exclude)? <br /><small>use cat IDs, comma seperated values, please.</small></td><td><input type='text' name='pfs_excats' value='<?php echo get_option('pfs_excats');?>' /></td><td class='notes'>Default: none</td></tr> 
     229                <tr><td>Allow creation of new categories?</td><td><select name='pfs_allowcat'><option value='1' <?php echo (get_option('pfs_allowcat'))?'selected':'';?>>Yes</option><option value='0' <?php echo (get_option('pfs_allowcat'))?'':'selected';?>>No</option></select></td><td class='notes'></td></tr> 
     230                <tr><td>Allow post tags (includes ability to create new tags)?</td><td><select name='pfs_allowtag'><option value='1' <?php echo (get_option('pfs_allowtag'))?'selected':'';?>>Yes</option><option value='0' <?php echo (get_option('pfs_allowtag'))?'':'selected';?>>No</option></select></td><td class='notes'></td></tr> 
     231                <tr><td>Allow users to upload an image?</td><td><select name='pfs_allowimg'><option value='1' <?php echo (get_option('pfs_allowimg'))?'selected':'';?>>Yes</option><option value='0' <?php echo (get_option('pfs_allowimg'))?'':'selected';?>>No</option></select></td><td class='notes'>Note: Images automatically uploaded to 'uploads' directory of wp-content -- just like uploading through the write-post/write-page pages.<br />To put this in the post, use the tag [!--image--]. If you don't include this, but do upload an image, it will automatically be appended to the end of the post.</td></tr> 
     232                <tr><td>Maximum file size for uploaded images?</td><td><input type='text' id='pfs_mfs' onblur='javascript:filesize_bytes()' value='<?php echo display_filesize(get_option('pfs_maxfilesize'));?>' /></td><td class='notes' id="filesize_alert">Default: 30MB</td></tr> 
    198233                <input type="hidden" id='pfs_mfsHidden' name='pfs_maxfilesize' value='' /> 
    199234                <tr><td>Post status? (set to draft or pending if you don't want these posts seen before approval)</td><td><select name='pfs_post_status'> 
     
    201236                    <option value='pending'<?php echo ('pending'==get_option('pfs_post_status'))?'selected':'';?>>Pending</option> 
    202237                    <option value='publish' <?php echo ('publish'==get_option('pfs_post_status'))?'selected':'';?>>Publish</option> 
    203                 </select></td><td>Default: Publish</td></tr> 
     238                </select></td><td class='notes'>Default: Publish</td></tr> 
    204239                <tr><td>Comment status? (closed means no one can comment on these posts)</td><td><select name='pfs_comment_status'> 
    205240                    <option value='closed' <?php echo ('closed'==get_option('pfs_comment_status'))?'selected':'';?>>Closed</option> 
    206241                    <option value='open' <?php echo ('open'==get_option('pfs_comment_status'))?'selected':'';?>>Open</option> 
    207                 </select></td><td>Default: Open</td></tr> 
     242                </select></td><td class='notes'>Default: Open</td></tr> 
    208243                 
    209244                <tr><th colspan='2'>Post-box Style</th></tr> 
    210                 <tr><td>Container background color?</td><td><input type='text' name='pfs_bgcolor' value='<?php echo get_option('pfs_bgcolor');?>' /></td><td>Default: #EDF0CF</td></tr> 
    211                 <tr><td>Top-left corner image location? (path/to/filename.jpg)</td><td><input type='text' name='pfs_bgimg' value='<?php echo get_option('pfs_bgimg');?>' /></td><td>Default: pfs_title.png</td></tr> 
    212                 <tr><td>Title text color?</td><td><input type='text' name='pfs_titlecolor' value='<?php echo get_option('pfs_titlecolor');?>' /></td><td>Default: none (inherited)</td></tr> 
    213                 <tr><td>Regular text color?</td><td><input type='text' name='pfs_textcolor' value='<?php echo get_option('pfs_textcolor');?>' /></td><td>Default: black</td></tr> 
     245                <tr><td>Container background color?</td><td><input type='text' name='pfs_bgcolor' value='<?php echo get_option('pfs_bgcolor');?>' /></td><td class='notes'>Default: #EDF0CF</td></tr> 
     246                <tr><td>Top-left corner image location? (path/to/filename.jpg)<br /><small>relative to plugin folder</small></td><td><input type='text' name='pfs_bgimg' value='<?php echo get_option('pfs_bgimg');?>' /></td><td class='notes'>Default: pfs_title.png</td></tr> 
     247                <tr><td>Title text color?</td><td><input type='text' name='pfs_titlecolor' value='<?php echo get_option('pfs_titlecolor');?>' /></td><td class='notes'>Default: none (inherited)</td></tr> 
     248                <tr><td>Regular text color?</td><td><input type='text' name='pfs_textcolor' value='<?php echo get_option('pfs_textcolor');?>' /></td><td class='notes'>Default: black</td></tr> 
    214249                <tr><td>Add your own CSS:</td><td colspan='2'><textarea name='pfs_customcss' rows='5' cols='50'><?php echo get_option('pfs_customcss');?></textarea></td></tr> 
    215250            </table> 
    216251             
    217252            <input type="hidden" name="action" value="update" /> 
    218             <input type="hidden" name="page_options" value="pfs_linktext,pfs_excats,pfs_allowimg,pfs_post_status,pfs_comment_status,pfs_imagedir,pfs_maxfilesize,pfs_titlecolor,pfs_textcolor,pfs_bgcolor,pfs_bgimg,pfs_customcss" /> 
     253            <input type="hidden" name="page_options" value="pfs_linktext,pfs_excats,pfs_allowcat,pfs_allowtag,pfs_allowimg,pfs_post_status,pfs_comment_status,pfs_imagedir,pfs_maxfilesize,pfs_titlecolor,pfs_textcolor,pfs_bgcolor,pfs_bgimg,pfs_customcss" /> 
    219254 
    220255            <p class="submit"> 
  • post-from-site/trunk/readme.txt

    r130862 r157117  
    22Contributors: ryelle 
    33Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=YB5AWJMBLCCVC&lc=US&item_name=redradar%2enet&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted 
    4 Tags: quick post, frontend, insert post, post 
     4Tags: quick post, frontend, insert post, post, Post 
    55Requires at least: 2.7 
    6 Tested up to: 2.8 
    7 Stable tag: 1.6.21 
     6Tested up to: 2.9 
     7Stable tag: 1.9.0 
    88 
    9 This plugin allows you to post straight from your front-end (i.e. website) - perfect for a quick update! **If you're using v1.6.20, and it's not working, you should upgrade now** 
     9This plugin allows you to post straight from your front-end (i.e. website) - perfect for a quick update, or if you just don't want to deal with the backend. 
    1010 
    1111== Description == 
    1212 
    13 This new wordpress plugin allows you to post straight from your front-end (i.e. website) - perfect for a quick update! Also useful if you have multiple users and don’t need them to see the admin side of things. It creates a link on your website which, when clicked, will bring up a simple text-box. You can enter a post title, content, and add categories (more features in the works, such as media support).   
     13This new wordpress plugin allows you to post straight from your front-end (i.e. website) - perfect for a quick update! Also useful if you have multiple users and don’t need them to see the admin side of things. It creates a link on your website which, when clicked, will bring up a simple text-box. You can enter a post title, content, and add categories and tags, even upload an image. 
    1414 
    1515On the admin side, there is a settings page where you can edit the plugin to your preferences. You can customize the link text, post-box background color, title/text color, and even add your own CSS to tailor pfs to your site. 
    1616 
    17 As for permissions, you can limit the categories pfs can post to and allow/disallow uploading of images. If you’d rather have pfs’s posts approved before they are visible, you can set the post status to ‘pending’ or ‘draft’. Same with the comment status, it can default to ‘open’ (allowing comments) or ‘closed’ (not allowing comments). 
     17As for permissions, you can limit the categories pfs can post to and allow/disallow uploading of images (among other things). If you'd rather have pfs's posts approved before they are visible, you can set the post status to ‘pending’ or ‘draft’. Same with the comment status, it can default to ‘open’ (allowing comments) or ‘closed’ (not allowing comments). 
    1818 
    1919== Installation == 
     
    24241. Place `<?php if (function_exists('post_from_site')) {post_from_site();} ?>` in your templates where you want to see the link. 
    2525 
     26== Changelog == 
     271.9.0  
     28* fixes double posting;  
     29* better image support;  
     30* introduction of '[!--image--]' tag;  
     31* existing category/tag dropdown with multiple selection;   
     32* ability to create new categories/tags;   
     33* other minor adjustments 
     34 
     351.7.0 
     36* addition of tags  
     37* bugfixes 
     38 
     391.6.x 
     40* Initial releases 
     41 
    2642== Frequently Asked Questions == 
    2743 
     
    3046Check that you have the javascript and css files in the plugin's folder (`post-from-site`). A problem with the first version of this plugin was that the plugin was looking for the files in the wrong directory. This *should* be fixed with the newest version, so definitely let me know if this is still happening. 
    3147 
    32 [ask a question?](http://www.redradar.net/wp/?p=95)? 
     48[ask a question](http://www.redradar.net/wp/?p=95)? 
    3349 
    3450== Screenshots == 
Note: See TracChangeset for help on using the changeset viewer.