Is this OpenSource or not?

Is this OpenSource or not?

[Deleted User][Deleted User] Posts: 0Questions: 2Answers: 0

So, Datatables is OpenSource, right?
But why do we need purchase Datatables Editor? There are many alternatives, but support is minimal and Datatables support team makes it impossible to get.
There are many simple questions according editing datasource with backend_??.php but there are no answers.

A little fee is acceptable but $100 is too much for individual non-commerce or volunteering developer.

Best regards,
Jorma Hytonen
StMichel, Finland
jorma.hytonen@gmail.com

Answers

  • tangerinetangerine Posts: 3,365Questions: 39Answers: 395
    edited June 2017

    But why do we need purchase Datatables Editor?

    Why should a huge amount of someone's time, effort and ability be handed over to you at no cost?

    There are many alternatives

    What do you mean by "alternatives"?

    support is minimal and Datatables support team makes it impossible to get.

    Absolute nonsense. DataTables' level of support is second to none.

    There are many simple questions ....... but there are no answers.

    Do you actually have a question? Complaining before you even asked is not a good start.

    A little fee is acceptable but $100 is too much for individual non-commerce or volunteering developer.

    I am an "individual non-commerce developer". If I can't code stuff myself, I expect to pay someone else.

  • [Deleted User][Deleted User] Posts: 0Questions: 2Answers: 0

    _"Why should a huge amount of someone's time, effort and ability be handed over to you at no cost?"

    It's called as OpenSource!

  • [Deleted User][Deleted User] Posts: 0Questions: 2Answers: 0

    What do you mean by "alternatives"?
    There are some altervative and free Datatables Editors (CRUD)

  • tangerinetangerine Posts: 3,365Questions: 39Answers: 395

    It's called as OpenSource!

    No, the Editor is not OpenSource.

    There are some altervative and free Datatables Editors (CRUD)

    Are you using one of them, then?

  • [Deleted User][Deleted User] Posts: 0Questions: 2Answers: 0

    "Do you actually have a question? Complaining before you even asked is not a good start."

    THIS is exactly what I mean for. You ever even read my post. And You complain to me if I need help! It's same forum question than user need help for Linux and Moderator answer is: Why do you not purchase Windows!

    So, this is my question:
    How can I implement $.ajax() call using jQuery Modal popup and redirect that call to another php-page to editing ONE column?

    I have an example where I use an other jQuery library:
    $("#search").click(function(s) {
    s.preventDefault();
    var modal = new DataQuery.Modal();
    modal.onClosed = function(args) {
    loadEvents();
    };
    modal.height = 640;
    modal.width = 780;
    modal.showUrl("search_panel.php?do=search");
    });

    And THIS is the new start:
    var table = $('#namedays-grid').DataTable();
    $('#namedays-grid tbody td').on('click', 'tr', function () {
    var data = table.row( this ).data();
    alert( 'You clicked on '+data[2]+'\'s row' );
    $.ajax({
    method: "POST",
    url: "dialog.php",
    data: {"row_id": data[0] },
    })
    .done(function( msg ) {
    alert( "Data Saved: " + msg );
    });
    });

    The response is some mess incl all HTML code in dialog.php

  • [Deleted User][Deleted User] Posts: 0Questions: 2Answers: 0

    Are you using one of them, then?
    Yes! I am. And very success. But I want to merge them!

    So, I'm forget using DataTables and change more OpenSource product.
    It's shame, because core of Datatable is nice.

    Very thank's for support and Goodbye!

  • tangerinetangerine Posts: 3,365Questions: 39Answers: 395

    THIS is exactly what I mean for.

    I have no idea what you are talking about.

    You ever even read my post.

    So how did I manage to respond to it in detail?

    And You complain to me if I need help!

    Where am I complaining to you, and where did you say you needed help?

    It's same forum question than user need help for Linux and Moderator answer is: Why do you not purchase Windows!

    Again, I have no idea what you are talking about.

  • [Deleted User][Deleted User] Posts: 0Questions: 2Answers: 0

    Ok. Can You please read me post?

    How can I implement $.ajax() call using jQuery Modal popup and redirect that call to another php-page to editing ONE column, selected Datatable row.

    I have an (alternative) example where I use an other jQuery library:
    $("#search").click(function(s) {
    s.preventDefault();
    var modal = new DataQuery.Modal();
    modal.onClosed = function(args) {
    loadEvents();
    };
    modal.height = 640;
    modal.width = 780;
    modal.showUrl("search.php?do=search");
    });

    Code above opens Modal dialog to Edit row content.
    And return response of search.php

    -- oo --

    But above code does NOT work with DataTables

    I try THIS:
    var table = $('#namedays-grid').DataTable();
    $('#namedays-grid tbody td').on('click', 'tr', function () {
    var data = table.row( this ).data();
    alert( 'You clicked on '+data[2]+'\'s row' );
    $.ajax({
    method: "POST",
    url: "search.php",
    data: {"row_id": data[0] },
    })
    .done(function( msg ) {
    alert( "Data Saved: " + msg );
    });
    });

    The response is some mess incl all HTML code in dialog.php

  • tangerinetangerine Posts: 3,365Questions: 39Answers: 395

    What happens in "search.php"? Can you show the code?

    The response is some mess incl all HTML code in dialog.php

    I don't immediately see where "dialog.php" comes into it, but I know that one possible reason for collecting unwanted HTML is failing to include a PHP exit() command after gathering your JSON data. Can you check that your data is as expected, apart from the extra HTML?

  • rduncecbrduncecb Posts: 125Questions: 2Answers: 28
    edited June 2017

    Disclaimer: I'm not affiliated with DataTables/SpryMedia in anyway but do make use of DataTables and Editor. I support OpenSource, have released my own software as GPL in the past, but am also a software developer by profession and make use of both open source and commercial software.

    DataTables is OpenSource (MIT License), Editor is NOT required to use DataTables.

    Editor is an extension to DataTables that you may purchase a license for. The proceeds from Editor help fund development of DataTables.

    If you do not like the way DataTables works, per the license you free to make changes you require. That's not to say they will become part of the official source but there is a chance they could. DataTables in on github and you can fork and make pull requests for your own changes if you wish to contribute to the project and community as a whole.

    If you wish to use DataTables with other projects that make data in it editable, you are free to do that, or write your own edit extension, perhaps even sell your extention, just as SpryMedia has done with Editor.

    It's important to see the distinction between DataTables and Editor, they are separate pieces of software with very different functionality to solve different problems, therefore they have separate licenses.

    If you want to save time and effort you have the options to buy licenses for Editor, it's not that expensive and relatively unrestrictive license, one developer can use their license to create any number of commercial websites.

    In my experience, support has been excellent. I've found small bugs and suggested fixes. By the next version they were incorporated into the trunk.

    I would suggest you open a forum post in the free community support explaining your issue. Your are likely to get responses if you explain the problem and intention clearly. Lots of people are eager to help if they can.

    In regards to your problem, have you verified the php target of your ajax call executes correctly, independent of any other code? What is the response?

  • [Deleted User][Deleted User] Posts: 0Questions: 2Answers: 0

    So, this is my "dialog.php" code

    <!DOCTYPE html>
    <html>
    <title>Namedays Datagrid Edit</title>
    <head>
    <link rel="stylesheet" type="text/css" href="css/jquery.dataTables.min.css">
    <link rel="stylesheet" type="text/css" href="css/bootstrap.min.css">
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap-theme.min.css">
    <link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/smoothness/jquery-ui.css">

    <script type="text/javascript" language="javascript" src="js/jquery-1.12.4.min.js"></script>
    <script src="//code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
    <script type="text/javascript" language="javascript" src="js/bootstrap.min.js"></script>
    
    <script type="text/javascript">
        $(document).ready(function(){
            $("#editModal").modal('show');
        });
    </script>
    

    </head>

    <body>

    <?php
    $file = './request.txt';
    $row_id = intval($_POST['row_id']);
    file_put_contents($file, $row_id);
    
    /*
    include "connect.php";
    
    $data_ids = $_REQUEST['data_ids'];
    
    $data_id_array = explode(",", $data_ids); 
    if(!empty($data_id_array)) {
        foreach($data_id_array as $id) {
            $sql = "SELECT FROM name_db ";
            $sql.=" WHERE id = '".$id."'";
            $query=mysqli_query($conn, $sql) or die("namedays-edit.php: update name_db");
        }
    }
    */
    ?>
    
    <div id="editModal" class="modal fade">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                    <h4 class="modal-title">Subscribe our Newsletter</h4>
                </div>
                <div class="modal-body">
                    <p>Subscribe to our mailing list to get the latest updates straight in your inbox.</p>
                    <form>
                        <div class="form-group">
                            <input type="text" class="form-control" placeholder="Name">
                        </div>
                        <button type="submit" class="btn btn-primary">Subscribe</button>
                    </form>
                </div>
            </div>
        </div>
    </div>
    

    <?php
    $result = "ID: " . $row_id . " OK!";
    echo json_encode($result);

    <?php > ?>

    </body>
    </html>

  • tangerinetangerine Posts: 3,365Questions: 39Answers: 395

    Disclaimer: I'm not affiliated with DataTables/SpryMedia in anyway

    I should have spelled that out myself - my apologies.

  • allanallan Posts: 63,471Questions: 1Answers: 10,467 Site admin

    Hi folks,

    Thanks for the comments and feedback. To answer the initial question of why Editor is not open source: the simple answer is that I need to eat and feed my family. DataTables is my full time job - I don't have another source of income. I am the "DataTables team" and rely upon the good will of fine folks like @tangerine to be able to continue doing what I do - it is simply the only way that it is sustainable.

    I would love to answer every question in the forum myself, taking time to answer in detail and write code for others - doing this is my passion. But that simply isn't possible. I get more than 50 questions per day. Balancing that will sales support for Editor, all the paper work to run a business and continued product development (never mind family life) means that it isn't possible to provide complete free support for the open source software. Best effort is as much as I can do.

    If you want to use free alternatives rather than using Editor - you are of course welcome to do so. Personally I believe Editor's price point accurately reflects the amount of time and effort it can save you.

    How can I implement $.ajax() call using jQuery Modal popup and redirect that call to another php-page to editing ONE column, selected Datatable row.

    This is the code reformatted to be a little more readable:

    var table = $('#namedays-grid').DataTable();
    $('#namedays-grid tbody td').on('click', 'tr', function() {
        var data = table.row(this).data();
        alert('You clicked on ' + data[2] + '\'s row');
        $.ajax({
                method: "POST",
                url: "search.php",
                data: {
                    "row_id": data[0]
                },
            })
            .done(function(msg) {
                alert("Data Saved: " + msg);
            });
    });
    

    The selectors look odd. The initial selector is selecting all td elements in the table's tbody. Then it will activate on a child tr of those td cells. Unless you have inner tables, that is never going to do anything.

    Try using:

    $('#namedays-grid').on('click', 'tbody tr', function() {
    

    The jQuery documentation has a good introduction to using jQuery events.

    Allan

  • [Deleted User][Deleted User] Posts: 0Questions: 2Answers: 0

    Dear allan https://datatables.net/forums/profile/1/allan

    I understand your needs and profit,
    but I'm quit volunteering and do my "job" as no profit.

    So, I wonder if You can understand my POV.

    I must continue searching an alternative for Datatables and Datatables Editor.
    If I continue to use DataTables I only need edit ONE column of my namedays database,.

    Regards,
    Jorma

  • allanallan Posts: 63,471Questions: 1Answers: 10,467 Site admin

    Of course I do. Everyone needs to do what is right for them! Much respect to anyone who follows their dreams and peruses what they want to do.

    Allan

  • [Deleted User][Deleted User] Posts: 0Questions: 2Answers: 0

    Ok, I understand and I continue searching free alternative for Datagrid.
    I only have my own Namedays Grid and I do not decide to pay over $100 for one implementation.

    So, Goo day everyone
    We in Finland we have midsummer festivals
    We never sleep!

This discussion has been closed.