<![CDATA[ Support for PubWarner - My Forums]]> https://forums.modx.com/thread/?thread=98602 <![CDATA[Support for PubWarner]]> https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-533188
this is the official support channel for PubWarner for MODX revolution. As you found it, I assume you have an issue with it.

Link to MODX repository: http://modx.com/extras/package/pubwarner
Current Version: 1.0.0-pl
Works with: any version of Revolution, I guess

What does Pubwarner do?
It displays a red bar on top if you do two things at the same time:

  1. be logged into the manager
  2. view a ressource in the frontend that is NOT published yet (but you can see it as you are logged in)

Hot do I get help?
Please let me know what you are trying to do, how you noticed that it doesnt work the way you want it to and what you have tried until this moment to solve it.

Cheers!]]>
gallenkamp Oct 14, 2015, 12:56 PM https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-533188
<![CDATA[Re: Support for PubWarner]]> https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534519
I think that after the Expo I'll play with this a bit to have it use a chunk and getChunk instead of being hard-coded. Maybe even add its own assets/components/pubwarner/css/ for styling, something like the QuickBar snippet.]]>
sottwell Nov 18, 2015, 03:14 AM https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534519
<![CDATA[Re: Support for PubWarner]]> https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534234
I have a Git Bash terminal set up inside PhpStorm (I don't use PhpStorm's Build-in Git features). I can pop open the terminal window and do whatever I want with Git, including pushing stuff to GitHub.

Since I'm using MyComponent, everything I do is in a file and it's easy to run or debug unit tests inside PhpStorm. I've just been working on UpgradeMODX and the ability to step through all its code in a unit test and watch the variables change saved me *many* hours of frustration.

If Git, MyComponent, or PhpStorm went away tomorrow, I'd have to shoot myself. I don't know how to work without them.]]>
BobRay Nov 10, 2015, 05:15 PM https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534234
<![CDATA[Re: Support for PubWarner]]> https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534229
I understand the usefulness of collaboration, but Github lingo has been one of the worst experiences I have come across in terms of workflow and getting things uploaded peacefully.
I am still trying to learn the stupid thing.]]>
donshakespeare Nov 10, 2015, 02:28 PM https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534229
<![CDATA[Re: Support for PubWarner]]> https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534227
I am still trying to figure out a workflow for me to get my code to github and back to the repository. I've bee a single player for most of my projects smiley]]>
gallenkamp Nov 10, 2015, 02:23 PM https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534227
<![CDATA[Re: Support for PubWarner]]> https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534151
<?php
# Plugin to display a warning that the viewed resource will not be visible when the user logs out of the manager.
# Fires on: OnLoadWebDucument
# Author: [email protected]

if (!$modx->resource->get('published')&&$modx->user->hasSessionContext('mgr')) {
    $modx->getService('lexicon','modLexicon');
    $modx->lexicon->load('resource');
    if ($modx->lexicon('resource_unpublished')) {
        $message = $modx->lexicon('resource_unpublished');
    }
    else {
        $message = "Page is not published";
    }
    
    // add "Publish Now" button, clear cache and refresh page
    // 8 Nov 2015 sottwell
    $button = '';
    if($modx->hasPermission('publish')) {
      $button = '<form action="" method="post" style="display:inline-block;"><input type="submit" id="pubnow" name="pubnow" value="Publish Now"></form>';
      if(isset($_POST['pubnow']) && ($_POST['pubnow'] == 'Publish Now')) {
        $rid = $modx->resource->get('id');
        $result = $modx->runProcessor('resource/publish', array('id' => $rid));
        $url = $modx->makeURL($rid);
        $modx->sendRedirect($url);
      }
    }
    
    $modx->regClientHTMLBlock('
    <div style="position: fixed; top: 0; width:100%; height: 50px; background-color: #f33; opacity: 0.6;">
    <div style="padding: 15px; margin: 0 auto; width: 800px; color: #fff; text-shadow: 1px 1px 5px #000">'.$message . ' - ' . $button . '</div>
    </div>
    ');
}
]]>
sottwell Nov 08, 2015, 11:27 AM https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-534151
<![CDATA[Re: Support for PubWarner]]> https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-533211
Hmmm... could add a "Publish Now" button to that. User's group would need to have "publish" permission for the context for the button to show.

That's 'resource_unpublished'

GitHub!!! Please!!!]]>
sottwell Oct 14, 2015, 09:55 PM https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-533211
<![CDATA[Re: Support for PubWarner]]> https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-533191
Check the Database(s) this add-on supports. If you aren’t sure, skip this.
?
smiley Done! Thank you]]>
gallenkamp Oct 14, 2015, 02:53 PM https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-533191
<![CDATA[Re: Support for PubWarner]]> https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-533190 markh Oct 14, 2015, 02:40 PM https://forums.modx.com/thread/98602/support-for-pubwarner#dis-post-533190