containers plugin - 1.8

i've just uploaded a simple plugin to github that allows containers to be chosen on save/edit forms..

https://github.com/propertunist/containers

the only bug i know of is with bookmarks - for some unknown reason the containers are not saving.. the other mods are fine. if anyone wants to test this and/or maybe find the cause of the bug, then you are welcome to.

  • How you plan to, what is sinificance of 'contai8ners ' for you and yrb usage ?

  • the idea is to allow:

    new entities to be created and added to groups without needing to go to the 'add new' page for the specific group first.
    and
    existing entities to be moved between containers - which is essentially between groups and your own profile presently.

    i'd much prefer multiple containers to be allowed - so i can post one video to my own profile and to multiple containers.. elgg is not supporting that presently, perhaps due to the way commenting is implemented.

  • ;-) got it !dl'd to my droid, unzippede, now to study the code.... lolz...

  • I ll write details later after Sunday @ home.
    Then you ll see the why s re: me
    B.C. I plan my global MediaMall similar but
    Mucho ++ ,Powerz

  • ok, i've pushed some more changes to github - fixed a bug..
    the bookmark issue is that bookmarks save ok, but when i edit one and change the container, the change of of container doesn't save; yet other changes do save. !?

  • ElggEntity.php

    Function save()
    See what code does to yr Cont#
    For create New and update Existing....

    Might be somethangz inside.there.....

  • nope.. nothing in function save() of note..
    i did see that the 'prepare_from_vars' function in bookmarks is pretty different to blogs - which doesn't make much sense to me - except that maybe they were coded in different periods, so different styles were applied. so maybe the cause is in there somehow, someway.

  • Does bookmarks save action actually grab the form container guid field value ?

  • the logic i am seeing in the bookmark save actions is a bit strange.. ;)
    it grabs the container_guid using:

    $container_guid = get_input('container_guid', elgg_get_logged_in_user_guid());

    and then does nothing with it..

    another line appears further in:

    $bookmark->container_guid = (int)get_input('container_guid', $_SESSION['user']->getGUID());

    so i am imagining bookmarks hasn't had much coder love for a while.

    so anyway, to answer your question - yes the save action does grab the field. the field does get saved in some circumstances.. and not in others.
    specifically it is saved correctly with a new bookmark and not when an edit is done to an existing bookmark - though no error message appears.