tony

Forum Replies Created

Viewing 15 replies - 7,741 through 7,755 (of 7,981 total)
  • Author
    Replies
  • in reply to: afterSubmit HowTo #82377
    tony
    Keymaster

    I think yes.
    The name of function is wrong. It should be handle_register.
    Second this function must return at least array with one value

    Regards
    Tony

    in reply to: Dynamically populate editortype select (json) #82376
    tony
    Keymaster

    Ok,
    There seems that this should be explained.
    First lets think what we should do to obtain the select values from db with the grid request (url option).
    – We need to make additional query for this. The query should return a value name from table.
    – These values can be merged in userdata option.
    – Let suppose that after the additional query the result can be mergead into the string of type s = val1:name1;val2:name2….

    then before to send the request back to jqGrid we can constuct a userdata this way (xml example)

    echo s;

    Then we can use loadComplete

    loadComplete: function () {
    var udata = $(“#mygrid”).getUserData();
    $(“#mygrid”).setColProp(‘myselect_box’,editoptions:{value:udata.mylist});

    }

    Hope this help
    Regards
    Tony

    in reply to: editoptions with array #82375
    tony
    Keymaster

    Currently no example, but if you see haw userdata can be manipulated you can easy construct this.

    Regards
    Tony

    tony
    Keymaster

    Thank you for this information

    Regards
    Tony

    in reply to: Cannot save to MySQL #82373
    tony
    Keymaster

    Ioannis,

    IMHO I think that you mix updating with selecting.
    To update values in the db you must first obtain the posted values, analyze them and after that update the DB table(s).
    If you have set a editurl then, you must first use something like


    $name = $_POST;
    ...

    then
    SQL = "UPDATE mytable SET name=".$name ...

    Regards
    Tony

    in reply to: FCKeditor #82363
    tony
    Keymaster

    Hi,
    It seems that on hidden fields fck does not work.
    You can do this without to change the formedit code. Simply use a one trick with afterShowForm event.
    Let suppose you defined textarea field in colModel.
    In edit options add this for these fielfds editoptions:{class:’fck’…}
    Since afterShowForm is called every time you click on edit or create button you should call it only once. For this purpose define global variable something like

    var aftershowcnt = false
    then

    afterShowForm : function(form_id) {
    if (!aftershowcnt ) {
    $(‘.fck’,form_id).fck( options )
    aftershowcnt = true;
    }

    }

    Regards
    Tony

    in reply to: save row #82358
    tony
    Keymaster

    Not this, but this

    var minver = true;

    Set it to false to use the new version

    Regards
    Tony

    in reply to: FCKeditor #82356
    tony
    Keymaster

    You should add fckeditor in filData function too.
    something like:
    ….
    case “text”:
    case “textarea”:
    case “fckeditor”:
    $(“#”+nm,”#”+frmtb).val(tmp);
    break;
    ….

    in reply to: FCKeditor #82355
    tony
    Keymaster

    This is the right way to do that, bu I think that the right code should be:

    function createEl(eltype,options,vl) {
    var elem = ””;
    switch (eltype)
    {
    case ”fckeditor” :
    elem = document.createElement(”textarea”);
    $(elem).attr(options);
    $(elem).html(vl);
    //fckeditor call using jquer.FCKEditor.js
    $(elem).fck({ path: “/fckeditor/”,toolbar: ’Basic’, height: 100, width:300});
    break;

    If you have FireBug see what is happen

    Regards

    P.S. If I have time I will test this

    in reply to: Required field #82354
    tony
    Keymaster

    I plan to implement some features such as required, number, minValue maxValue and etc.

    in reply to: Upload file #82353
    tony
    Keymaster

    Little difficult. Actually we do not submit form directly – i.e. using the url in the action. Data is send via ajax post method.

    in reply to: save row #82352
    tony
    Keymaster

    Open jquery.jqGrid.js and see which .js files are you use. Maybe you use minified files. Change the paths to right files.

    Regards
    Tony

    in reply to: clickable cells #82351
    tony
    Keymaster

    Search this topic on how to insert HTML content

    Regards

    in reply to: Fixed Column #82346
    tony
    Keymaster

    You mean freeze columns.

    Not in current plan, but will add this in the list

    Regards
    Tony

    in reply to: save row #82345
    tony
    Keymaster

    Please upgrage to 3.2. This bug is corrected. Actually this is only in IE.

    Regards
    Tony

Viewing 15 replies - 7,741 through 7,755 (of 7,981 total)

Stay connected with us in your favorite flavor!