Developers

This section is code snippets, apps, etc, for developers. There is no warranty or guarantee, assume every thing in this section is protected under the DBAD License unless otherwise stated. I might specifically change a license from DBAD to MIT or another free license that offers greater protection for the consumers of the code. If you need something contained in here to be under a specific license for a project or something, contact me (you can send a PM to Michael) and I'll see about changing the license. 

5 files

  1. Free

    demo: https://codingjungle.com/phpdoc/index.html
    this is the doxygen of IPS 4's PHP files. i will try to keep it current with each new release.
    Instructions:
    download file, extra into your IPS root path.
    open browser, http://mysite.com/phpdoc
    *note: you can upload it to your server, but if you do local development, probably best to keep it there and the above link for demo will be updated with each release i do. 

    10 downloads

       (0 reviews)

    0 comments

    Updated

  2. Free

    Storm is a collection of development tools i've developed over the last few years, to help me work with IPS 4.
    Features:
    Profiler: profiles information about the inner works of the IPS suite and/or your application. logs DB Queries, Memory Usage, Execution time, Loaded Caches, Included files count, and the IPS Log. Dev Folder Recreation: can recreate the dev folders for Plugins and Applications, so no more tracking down these folders from other developers and or remembering where you stored them  (this allows a plugin to be installed with its XML while IN_DEV mode is enabled, something IPS does not do on its own). Proxyclass generator: due to the nature of the IPS 4 framework, not all the features of your IDE might be available (most notable would be autocomplete/hinting). this will create proxyclasses that your IDE can use to make these features available to you. HeaderDoc: creates a Header Document block for your PHP files. ACP/DevCenter/Framework Scaffolding: this includes adding a Sources and Dev Folder tab to your Dev center for your apps, Quick links to some of the most used features in the ACP. Debugger Class: offers several different types of debugger options, one of them being a universal Console Debugger (similar to how firePHP and chromePHP libs/extensions work, but without requiring those extensions or libs to be installed). advanced CSS/Template debugging options Bitbucket webhook PUSH Feature.  Dummy Content Generator for members, forums, topics, posts. i feel like i am leaving out some features, I might be. why don't you check it out, it is free  below is an image of the awesome profiler i made!

    1 download

       (0 reviews)

    0 comments

    Updated

  3. Free

    Any one who follows me over on IPS knows I have had many complaints about the forms and form helpers. Tired of sounds of crickets chirping while waiting for IPS to make improvements or take in considerations from the community, I built this class file for applications. 
     
    Usage:
    \IPS\myapp\Forms::i( $elements, $instancename, $form ) ( after $form, all the parameters are the same that you would find for \IPS\Helpers\Form\__construct method, but most of the time you will only need to set the $elements, $instancename is if you have multiple forms on the same page).
    $elements:
    tab, header, sidebar:
    'type' = tab|header|sidebar
    'name' =  used for all these to create them, if it is a lang/string, this is what is passed to the appropriate form command.
    example:
    $el[] = [ 'type' => 'tab|header|sidebar', 'name' => 'my_lang_string' ]; separator:
    'type' = 'separator'
    example:
    $el[] = [ 'type' => 'separator' ]; message: ->addMessage( $lang, $css='', $parse=TRUE, $_id=NULL)
    'type' = 'message'
    'msg' = this options is require for this type, the message you want to display
    optional:
    'css' = any additional css classes
    'parse' = default is true, set to false if msg is an already parsed lang string
    'id' = id of the element, default is null
    Example:
    $el[] = [ 'type' => 'message', 'msg' => 'my_message_lang_string' 'css' => 'myMessageClass myMessageClassWarning" ];
    helper:
    required:
    'name' = name of the element
    'class' = IPS Form Help Class (without the \IPS\Helpers\Form portion) or a FQN for a custom class.
    optional:
    'default' = the default value
    'required' = is it required or not
    'options' = an array of options for the class (identical to how options are set for form helpers)
    'validation' = validation method, can use a closure here, identical to how its set on the form helper.
    'prefix' = prefix for the form helper
    'suffix' = suffix for the form helper
    'id' = id for the form helper (if not set, the class will automatically configure name parameter with js_ prepend to it)
    'skip_id' = (bool) if 'id' isn't set, and you want it not to set it to js_name
    'label' = a lang string to use as the label instead of 'name'
    'description' => a lang string to use as an alternative description
    'appearRequired' => (bool) make the form helper appear required.
     
    Example:
    $el[] = [ 'class' => 'Select', 'name' => 'my_select_element', 'required' => true, 'options' => [ 'options' => [ 1, 2, 3, 4 ] ] ];  
    dummy: ->addDummy( $langKey, $value, $desc='', $warning='', $id='' )
    Required:
    'type' = 'dummy'
    'name' = name of the element
    'default' = value that will be display
    Optional:
    'desc' = description
    'warning' = warning
    'id' = html id (if not set, js_$name is used)
    Example:
    $el[] = [ 'type' => 'dummy', 'name' => 'my_dummy_element', 'default' => "content for the dummy element" ];  
    html: ->addHtml( $html )
    Required:
    'type' = 'html'
    'html' = the html to display
    Example:
    $el[] = [ 'type' => 'html', 'html' => "<a href='#'>some html</a>" ];  
    Matrix: ->addMatrix( $name, $matrix )
    Required:
    'type' = 'matrix'
    'matrix = must be an instance of \IPS\Helpers\Form\Matrix
    'name' = elements name.
    Example:
    $matrix = new \IPS\Helpers\Form\Matrix; $el[] = [ 'type' => 'matrix', 'matrix' => $matrix, 'name' => 'my_matrix_element' ];  
    i() method:
    public static function i( array $elements, $name = 'default', $form = null, $id = 'form', $submitLang = 'save', $action = null, $attributes = [] ) the instantiation method is pretty straight forward, you pass the array of elements to it, if you have multiple forms on the page, you can give the instance a name. if you have a form object already (like in nodes) just pass it Forms, the other parameters are for creating a new form, same parameters as \IPS\Form.
     
    Bringing it all together:
    $altDescription = "my_textarea_alt_desc"; $elements = [ [ 'type' => 'tab', 'name' => 'my_tab_1' ], [ 'class' => 'Text', 'name' => 'my_title', 'required' => true 'validation' => function( $data ){ if( !$data ) { throw new \InvalidArgumentException; } } ], [ 'class' => "Select", 'name' => "my_select', 'options' => [ 'options' => [ 1, 2, 3, 4 ] ] ], [ 'type' => 'tab', 'name' => 'my_tab_2' ], [ 'class' => "TexArea", 'name' => 'my_text_area', 'default' => 'im a default', 'description' => $altDescription ], [ 'type' => 'separator' ], [ 'class' => 'Text', 'name' => 'my_text_2' ] ]; $form = \IPS\myapp\Form::i( $elements ); \IPS\Output::i()->output = $form;  
    this will return an instance of \IPS\Form. 


    3 downloads

       (0 reviews)

    0 comments

    Updated

  4. Free

    download the file, directions are in there.

    3 downloads

       (0 reviews)

    0 comments

    Updated

  5. Free

    This tool is for developers who have files on the IPS market (or not, its not a requirement).
    Features:
    receives push notifications from IPS marketplace make pull request to the IPS marketplace for previous purchase/expirations/renewals generate invoices on the IPS marketplace File management (special features if you have downloads, you can link to files to retrieve information from it) News api (allows you to output news to your application if you want) Version checks (can manage update checks for applications/plugins, if you have downloads, create a custom field for "long versions" so all the info can be pulled from the download file) Create forum topics for push notifications Create Members for your site based on push notifications for purchases. (will send out an email to the user with username, password)

    0 downloads

       (0 reviews)

    0 comments

    Updated