The MU forums have moved to WordPress.org

WPMU and Structured Blogging Plug-in (14 posts)

  1. conoro
    Member
    Posted 17 years ago #

    I got a question on my blog about a post I did on the Structured Blogging plug-in. The person pointed out that the plug-in does not work with WPMU.

    Has anyone on the WPMU dev side had a look at it at all?

    I've posted the same question on the SB mailing list to see if any of them have looked at it from their side.

    I think it would be a huge win for both if they were compatible and the plug-in could get rolled out onto wordpress.com

    Conor
    http://www.argolon.com

  2. saderd
    Member
    Posted 17 years ago #

    2 steps for "massaging" it into WPMU, I think. Only the first I've completed.
    First Step: open the plugin in a text editor and find all "post.php" and replace with "post-new.php".
    Result: no errors and dashboard shows the plugin where it should. However, every click on a microcontent tab sends me to my homepage. Therefore, . . .
    Second Step: edit htaccess.

    Need help now.

  3. saderd
    Member
    Posted 17 years ago #

    I'm such a dummy. Don't REPLACE ALL! Find exactly the "post.php". I changed all my "sb-post.php" to "sb-post-new.php." Changed them back. All's well, mostly.

    Now I'm creating the microcontent but the admin header/footers are borked.

    No edits to htaccess.

  4. saderd
    Member
    Posted 17 years ago #

    Still no edits to htaccess, although I think that would have been simpler. (And may be the only fix in a user.yoursite.org set up. Mine is a http://www.mysite.org/user/ install only)

    So, since my wpmu site is in an atypical no vhosts install, I've replaced the php calls for the style sheet, javas, gifs, etc with the actual urls. So far so good.

    Look for these lines in structuredblogging.php:

    First: change this

    $stylesheetpath = get_settings('siteurl') . "/wpsb-files/wpsb-style.css";

    into

    $stylesheetpath = "http://blog.yourblog.org/wp-inst/wpsb-files/wpsb-style.css";

    And this

    <link rel="stylesheet" type="text/css" href="<?php echo get_settings('siteurl')?>/wpsb-files/wpsb-admin.css" />
    <link rel="stylesheet" type="text/css" href="<?php echo get_settings('siteurl')?>/wpsb-files/wpsb-style.css" />
    <script type="text/javascript" src="<?php echo get_settings('siteurl')?>/wpsb-files/prototype.js"></script>
    <script type="text/javascript" src="<?php echo get_settings('siteurl')?>/wpsb-files/scriptaculous.js"></script>
    <script type="text/javascript" src="<?php echo get_settings('siteurl')?>/wpsb-files/sb-lookup.js"></script>

    change to

    <link rel="stylesheet" type="text/css" href="http://blog.yourblog.org/wp-inst/wpsb-files/wpsb-admin.css" />
    <link rel="stylesheet" type="text/css" href="http://blog.yourblog.org/wp-inst/wpsb-files/wpsb-style.css" />
    <script type="text/javascript" src="http://blog.yourblog.org/wp-inst/wpsb-files/prototype.js"></script>
    <script type="text/javascript" src="http://blog.yourblog.org/wp-inst/wpsb-files/scriptaculous.js"></script>
    <script type="text/javascript" src="http://blog.yourblog.org/wp-inst/wpsb-files/sb-lookup.js"></script>

    put your url instead of blog.yourblog.org, duh.

    saderd

  5. saderd
    Member
    Posted 17 years ago #

    One small side effect remains. The darkest blue admin submenu vanishes when editing any microcontent. I have to click the "Write" menu anytime I want to switch from microcontent node to another node. I don't get an "activity error" showing what is not found, however.

    Likely a simple fix, but I'm pleased with results so far. Needles, haystacks, yada yada.

    All nodes publish, all styles intact, no "Activity Errors." Never touched htaccess.

    Not bad for a Sunday project, I must say. I'll unleash the plugin to my bloggers and ask for their feedback tomorrow.

    D. Sader

  6. saderd
    Member
    Posted 17 years ago #

    I just stuck it in the mu-plugins and it works! Again, the only non-fatal side-effect is the appearing/disappearing dark blue dashboard sub menu. Tolerable.

    D. Sader

  7. saderd
    Member
    Posted 17 years ago #

    UPDATE Solved the disappearing dark blue admin menu disapearing.

    Open sb-post-common.php

    replace the couple "post.php" with "post-new.php" being careful not to turn "sb-post.php" into sb-post-new.php.

    Voila.

  8. saderd
    Member
    Posted 17 years ago #

    Many bloggers ooed and awed about new microcontent types. But, YIKES, all users upload to same images folder when using the microcontent upload file forms. Here's what I did to stop that. Sledgehammer solution, no doubt.

    Edit mc-renderers.php to disable the media upload functions(all user images were dumping into the same images folder in wp-inst directory and I uploaded one mp3 file as a test and still can't find it). Users can simply upload to their file directory using the post/page upload until/if I figure out something else.

    changed this :

    $result = $this->displayData($dataValue);
    $result .= '<input type="file" name="sb_action_upload_file_name'. $this->_encodeFieldName($contentPath) .
    '" value="Choose File" size="35"/>
    ';
    $result .= '<input type="submit" name="sb_action_upload_file' . $this->_encodeFieldName($contentPath) .
    '" value="Upload '.ucfirst($this->fileType).'"/>';
    $result .= ' or enter URL: <input type="text" size="11" id="image-upload-data" name="' . $this->_encodeFieldName($contentPath) . '" value="' . $dataValue . '"/>';

    return $result;

    into this:

    $result = $this->displayData($dataValue);
    $result .= '<input type="submit" name="sb_action_upload_file' . $this->_encodeFieldName($contentPath) .
    '" value="Enter URL to '.ucfirst($this->fileType).'"/>';
    $result .= ' : <input type="text" size="11" id="image-upload-data" name="' . $this->_encodeFieldName($contentPath) . '" value="' . $dataValue . '"/>';

    return $result;

    Edit sb-options.php next to disable uploads:
    deleted this:
    </fieldset>
    <fieldset class="options">
    <legend><?php _e('File Upload Locations'); ?></legend>

    Some Structured Blogging post types allow you to upload files and images to be included in the post. For this to work you must provide
    a directory where the files can be uploaded and the URL location where that directory is accessible via the web.

    <table width="100%" cellspacing="2" cellpadding="5" class="editform">
    <tr valign="top">
    <td><?php _e('File Upload Directory'); ?>:</td>
    <td><input name="sb-file-upload-directory" type="text" id="sb-file-upload-directory" value="<?php form_option('sb-file-upload-directory'); ?>" size="20" /></td>
    </tr>
    <tr valign="top">
    <td><?php _e('URL of Upload Location'); ?>:</td>
    <td><input name="sb-file-upload-url" type="text" id="sb-file-upload-directory" value="<?php form_option('sb-file-upload-url'); ?>" size="20" /></td>

    </td>
    </tr>
    </table>

    All's well till the next hack.

    D Sader

  9. Conmiweb
    Member
    Posted 17 years ago #

    It's working?

  10. vibhash
    Member
    Posted 17 years ago #

    Any one got this working perfectly?

  11. dsader
    Member
    Posted 17 years ago #

    I haven't tried very hard with the new(er) version:

    http://mu.wordpress.org/forums/topic.php?id=3250&replies=14

  12. Farms2
    Member
    Posted 17 years ago #

    Have a look at nook.com.au

  13. dsader
    Member
    Posted 17 years ago #

    How on earth does one do a front page as slick as that?

    How can I learn to call Movie Reviews, from the entire site, in one click from a sidebar?

  14. dsader
    Member
    Posted 17 years ago #

    I think I've figured it out. The categories appear to be hardwired. Every blog seems to have the same categories.

    Even non "structured blogging" posts are tagged. My excitement has abated.

    I was hoping there was a way to syphon only sb posts simply by their xml type.

About this Topic