Forum Activity for @ultrajam

SteveX
@ultrajam
12/17/13 05:39:29AM
2,589 posts

Adding a js function to a form Cancel button


Jamroom Developers

The problem is that without being able to specify an onclick, you can control what happens on form submit in the submit save php function, and when you have done that you find that you are stuck with a choice of a broken cancel button, or no cancel button at all.

I guess it would be another elseif for any js function to be placed in the onclick:
elseif (isset($cancel_url) && strlen($cancel_url) > 1) {
            $html .= '   input type="button" id="' . $_form['form_params']['name'] . '_cancel" class="form_button" value="' . $cancel_value . '" onclick="' . $cancel_url . '" ';
        }
I've taken out the for the input - the forum didn't print the inputs in the code block in my first post.
SteveX
@ultrajam
12/15/13 05:38:10AM
2,589 posts

Adding a js function to a form Cancel button


Jamroom Developers

I want to add different javascript to the cancel button.

It works fine in a modal, but my form is ajaxed in and I need to run a different js function when the Cancel button is clicked.

It looks like the only js option for the cancel button is to close a simple-modal.

Is there any other way to add a js function to the cancel button during form creation?

Thanks

line 3370 of form.php:

   // and cancel button
    if ($cancel_value || $cancel_url) {
        if (!$cancel_value) {
            $cancel_value = $_lang['jrCore'][2];
        }
        if ($cancel_url == 'referrer') {
            $cancel_url = jrCore_get_local_referrer();
        }
        if ($cancel_url == '$.modal.close();') {
            $html .= '  ';
        }
        elseif (jrCore_checktype($cancel_url, 'url')) {
            $html .= '  ';
        }
        else {
            $cancel_url = jrCore_get_last_history_url();
            $html .= '  ';
        }

What I want to be able to do is:
    $cancel = "myModule_update_div();";
    $_tmp = array(
        'submit_value' => '13,
        'cancel'       => $cancel,
        'values'       => $_rt
    );
    jrCore_form_create($_tmp);

updated by @ultrajam: 01/19/14 04:27:56PM
SteveX
@ultrajam
12/12/13 06:19:50AM
2,589 posts

Sections not correct in forms


Using Jamroom

It's in an enormous form.

I'll try reducing it to the bones later and see if I still see the reordering.
SteveX
@ultrajam
12/12/13 02:40:45AM
2,589 posts

Sections not correct in forms


Using Jamroom

I've jsut updated to 5.1.5 and fields are appearing out of order again on custom module forms with sections.

I haven't tried taking it back down to a simple form again, but jsut wondered if anyone else is seeing this?

Thanks
updated by @ultrajam: 12/12/13 02:41:49AM
SteveX
@ultrajam
12/07/13 02:45:02PM
2,589 posts

Jamroom Core 5.1.4 + PayPal Buy It Now


Announcements

Thanks Paul, but you can always get a like from an english man by mentioning a cup of tea.

I don't really like like it buttons, although the module is pretty cool.
SteveX
@ultrajam
12/07/13 12:56:58PM
2,589 posts

Problem with Projam 5 theme


Using Jamroom

Are you seeing cached content?

Use jrDeveloper to turn off the cache for css and js - check "run in developer mode" in config.

And set cache time to 0 in global config.
SteveX
@ultrajam
12/07/13 12:23:35PM
2,589 posts

Jamroom Core 5.1.4 + PayPal Buy It Now


Announcements

brian:
smith.kyle:
Can't tell you how much I love upgrading via the marketplace!

Awesome - glad to hear that :)

Thanks!

Me too Kyle.

I want to post how awesome it is each time I do it, but that impulse is fleeting, short-lived - click the button and it's done, not even enough spare time for a post or a cup of tea. (ftp = tea time)

I count it as a perfect new JR feature: I barely even have time to notice how awesome it is. AWESOME!!!

So I (slightly creepily) just say a little thankyou in the front of my mind to Brian and the Team each time I use it. Posting every time would be very creepy.

I'm not drinking enough tea though - is that a bug? Please fix it.
updated by @ultrajam: 12/07/13 12:25:17PM
SteveX
@ultrajam
12/07/13 02:32:41AM
2,589 posts

multiple sites


Installation and Configuration

I think it already works how you want it to.

You need to delete the modules from the first site to free the license, it then becomes available to install on the third site. You can install the module using the free license from the marketplace as long as the site you are installing on uses the same marketplace id.
updated by @ultrajam: 12/07/13 02:33:35AM
SteveX
@ultrajam
12/04/13 02:01:12AM
2,589 posts

Query Error after upgrade to 5.1.4


Using Jamroom

I fixed this by copying the jr_jrcore_play_key table from another dev site in phpmyadmin.
  221