2017 © Pedro Peláez
 

symfony-bundle pnotify

Wrapper around the PNotify plugin

image

alex198710/pnotify

Wrapper around the PNotify plugin

  • Wednesday, July 23, 2014
  • by alex198710
  • Repository
  • 1 Watchers
  • 0 Stars
  • 27,482 Installations
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 17 % Grown

The README.md

pnotify

  • Wrapper around pnotify
  • PNotify 2.0.1 sciactive.com/pnotify/

Without Symfony

Include CSS:, (*1)

<link href="pnotify.custom.min.css" media="all" rel="stylesheet" type="text/css" />

Include JS:, (*2)

<script type="text/javascript" src="pnotify.custom.min.js"></script>

Use it like this:, (*3)

<script type="text/javascript">
$(function(){
    new PNotify({
        title: 'Regular Notice',
        text: 'Check me out! I\'m a notice.'
    });
});
</script>

With Symfony

Composer.json, (*4)

Add this line:
"alex198710/pnotify": "dev-master"

Config.yml, (*5)

assetic:
    assets:
        pnotify_js:
            inputs:
                - %kernel.root_dir%/../vendor/alex198710/pnotify/assets/js/pnotify.custom.min.js
            output: js/pnotify.js
            filters: [?yui_js]
        pnotify_css:
            inputs:
                - %kernel.root_dir%/../vendor/alex198710/pnotify/assets/css/pnotify.custom.min.css
            output: css/pnotify.css

Twig view:, (*6)

{% stylesheets '@pnotify_css' filter='cssrewrite' %}
    <link rel="stylesheet" href="{{ asset_url }}" />
{% endstylesheets %}
{% javascripts '@pnotify_js' %}
    <script type="text/javascript" src="{{ asset_url }}"></script>
{% endjavascripts %}


Then use it like this:
<script type="text/javascript"> $(function(){ new PNotify({ title: 'Regular Notice', text: 'Check me out! I\'m a notice.' }); }); </script>

The Versions

23/07 2014

dev-master

9999999-dev

Wrapper around the PNotify plugin

  Sources   Download

GPL-3.0+

The Requires

  • php >=5.3.2

 

by Avatar alex198710

notification pnotify