Forum Activity for @michael

michael
@michael
05/22/18 02:09:27AM
7,819 posts

1 Click Ban


Suggestions

Currently the Data Browser is the way we do it.
step1.jpg step1.jpg - 68KB
michael
@michael
05/21/18 12:11:55AM
7,819 posts

Tracker Module Privacy


Using Jamroom

1. for your skin adjust your {jrProfile_menu} to exclude the tracker so it doesn't show in the menu.

Docs: "{jrProfile_menu}"
https://www.jamroom.net/the-jamroom-network/documentation/module-developer-guide/1997/jrprofile-menu

2. Use the Form Designer to change the default of 'off' to 'on' for the private tracker button in the CREATE screen. (screenshot)

Docs: "Using the Form Designer"
https://www.jamroom.net/the-jamroom-network/documentation/jamroom-admin-handbook/1275/using-the-form-designer
tracker.jpg tracker.jpg - 145KB

updated by @michael: 05/21/18 12:12:33AM
michael
@michael
05/21/18 12:07:01AM
7,819 posts

500 errors after updating modules


Using Jamroom

All that function does for that URL is redirect to the 'system_update' location with a random number on the end to ensure the page is not cached.
http://yoursite.com/marketplace/system_update/r=5532

500 is a server error, check your server error logs for any other useful info.
michael
@michael
05/19/18 06:00:51AM
7,819 posts

Convert PHP file for use in Smarty template


Jamroom Developers

in jr3 there was {debug}. in jr6 there is still {debug}, its still just as useful. Really useful.

Docs: "{debug}"
https://www.jamroom.net/the-jamroom-network/documentation/module-developer-guide/1477/debug

Put that into any template you want to know what variables are available for.

$_user array is all the stuff of the user looking at the screen
$_post array is all the stuff coming in from the address bar or POST
$_profile array is sometimes avaliable depending on the template, but usually available when looking at a profile.

No, there are no file system files created.

JR6 has a thing called DATASTORES which are key => value database tables and are super useful.

Docs: "datastores"
https://www.jamroom.net/the-jamroom-network/documentation/module-developer-guide/1023/datastores

Any user can have multiple profiles and any profile can have multilple users managing it, so there is no 1:1 relationship.
michael
@michael
05/17/18 11:07:36PM
7,819 posts

Convert PHP file for use in Smarty template


Jamroom Developers

agreed. Ask for anything you get stuck at here. There is a lot to learn about how things connect, but once you get the hang of it its WAY more configurable than it every used to be.

There is a system called "Events and Listeners" that allow you to tap into data before it reaches the screen so you can override modules functionality without changing the module.

Docs: "Events and Listeners"
https://www.jamroom.net/the-jamroom-network/documentation/module-developer-guide/1011/events-and-listeners

and the module developers guide

Docs: "Module developers guide"
https://www.jamroom.net/the-jamroom-network/documentation/module-developer-guide
michael
@michael
05/17/18 11:04:37PM
7,819 posts

Unable to update modules


Installation and Configuration

The problem is with the server. Your server is saying NO when jamroom says "I just need to write this to the error log/ activity log/ (other) log". That's a serious issue that needs to be fixed.

In fixing that issue ( allowing the web user to write to the file system ) you will also fix the marketplace issue.

you can download the jamroom packages again via the "Download open source" button here:
https://www.jamroom.net/products
michael
@michael
05/17/18 02:22:32AM
7,819 posts

Convert PHP file for use in Smarty template


Jamroom Developers

There is already a module that posts to twitter, its called OneAll

Modules: OneAll
https://www.jamroom.net/the-jamroom-network/networkmarket/47/oneall-social

If you wanted to turn your existing php file into a jamroom module then you can do it that way too.

Yes, everything in jamroom is a module.

The most basic module has a directory, a changelog.txt an include.php and in your case, if you want it to control a URL then it needs an index.php

Example
* call your module xxPost and place it in /modules/xxPost/
/modules/xxPost/changelog.txt
/modules/xxPost/include.php
/modules/xxPost/index.php

/modules/xxPost/changelog.txt
Changelog for Post to Twitter module

Version 1.0.0
 - Initial Release

/modules/xxPost/include.php
<?php
/**
 * @copyright ..........................
 * @author ........ .......... <someone [at] somewhere [dot] com>
 */


// make sure we are not being called directly
defined('APP_DIR') or exit();

/**
 * meta
 */
function xxPost_meta(){
    $_tmp = array(
        'name'        => 'Post to Twitter',
        'url'         => 'post',
        'version'     => '1.0.0',
        'developer'   => 'Sombody Somwhere, ©' . strftime('%Y'),
        'description' => 'Somthing about your module here',
        'category'    => 'custom'
    );
    return $_tmp;
}

/**
 * init
 */
function xxPost_init(){
    return true;
}

That will get your module appearing in the ACP. If you cant see it run the INTEGRITY CHECK. Then go to the INFO tab of the module and check the checkbox to activate it.

Next make it do something
/modules/xxPost/index.php
<?php
/**
 * @copyright ..........................
 * @author ........ .......... <someone [at] somewhere [dot] com>
 */


// make sure we are not being called directly
defined('APP_DIR') or exit();

//------------------------------
// create
//------------------------------
function view_xxPost_message($_post, $_user, $_conf)
{ // the $_post array contains anything coming in on the URL and the _message part of this function is the url. // this function will fire when you visit example.com/post/message // So you can either have the url example.com/post/message/message=hello // then $_post['message'] will equal "hello" or you can skip the name and just use the url example.com/post/message/hello // and "hello" can be found on either $_post['_1'] or $_post['_2'] need to check. // put the contents of your PHP file in this function and return whatever you want echoed to the screen return 'all the processing has completed'; or to return to a different location: jrCore_location("{$_conf['jrCore_base_url']}/somewhere/you/want/to/redirect/to"); }


Docs: "Freelancers Read this"
https://www.jamroom.net/the-jamroom-network/documentation/module-developer-guide/3513/freelance-developers-read-this
updated by @michael: 05/17/18 02:24:21AM
michael
@michael
05/16/18 04:15:03PM
7,819 posts

Unable to update modules


Installation and Configuration

That's the problem, not all directories are writeable by the web user. Contact your hosting provider and ask them to correct the situation.
  128