browse by category or date

Since my last post, I’ve been adding new features to JSON Table Editor. Here are the enhancements:

  1. Button labels and tool-tips.
    As I carefully observe the page, I asked myself whether the user interface is intuitive enough. From there, I changed some of the button labels with a clearer text. I also added additional information whenever user hover above certain controls. Hopefully this will make the UI less confusing.

    On the sub-level, the “Output to JSON” button is changed to “Finish Editing”.

  2. Instantly load remote JSON/CSV file.
    Not sure why I never think of this feature before. Now we can make the editor to automatically load a remote JSON/CSV file by passing parameters.
    Example:

  3. URL Shortener.
    The URL described in point no. 2 will be very long. Sharing this long URL is definitely look ugly. Thus, I added option to shorten the URL whenever a remote JSON/CSV fis is successfully loaded.

  4. Upload to Paste Sites
    A long time ago, a user complained why he can’t save the JSON output to other online storage like Google Docs/Spreadsheet. Since I don’t think a JSON file will fit nicely to a Google Spreadsheet, I decided to look other alternatives on storing text online. After short research, I picked Hastebin, Pastebin and DPaste as the upload destination. Purely due to the easiness to use their API.

That’s all guys. Looking forward to your feature request, bug reports! Cheers!

About Hardono

Hi, I'm Hardono. I am working as a Software Developer. I am working mostly in Windows, dealing with .NET, conversing in C#. But I know a bit of Linux, mainly because I need to keep this blog operational. I've been working in Logistics/Transport industry for more than 9 years.

Five years ago, I created JSON Table Editor. Recently I have the time to revisit the project and do some minor bug fixes and enhancements.

  1. Array editing.
    In previous version, loading an array of string will give you a table of characters. This is embarrassingly wrong.

    The updated version has no more of this problem.

  2. Improvements on multi-level object editing.
    I changed the button title from ‘Save to Upper Level’ to ‘Finish Editing’, which is more appropriate. I also make the window closed when you click ‘Finish Editing’ button. I also show the updated JSON so we can notice the changes.

    The changes also propagated all the way to the top. In previous version, on each child-window we need to click the ‘Save to Upper Level’ button.
  3. Limiting the proxy
    The proxy in the previous version is just a dumb proxy. It fetches any url requested and dump whatever content. I see a potential misuse here. So I limit the proxy to only fetch JSON, CSV and raw/text content.

    <?php
    $qUrl = $_REQUEST["q"];
    // create a new cURL resource
    $ch = curl_init();
    // set the URL
    curl_setopt($ch, CURLOPT_URL, $qUrl);
    // get only the Head
    curl_setopt($ch, CURLOPT_NOBODY, true);
    // curl_exec return value instead of directly to out
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    // do the request
    $res = curl_exec($ch);
    // check the content type
    $contentType = curl_getinfo ($ch, CURLINFO_CONTENT_TYPE);
    //only accept json, csv
    curl_close($ch);
     
    //error_log($contentType);
     
    if (strpos($contentType,'/json')!== false || strpos($contentType, '/csv')!== false || strpos($contentType, 'text/plain')!== false)
    {
       // ... SNIP ...
       // Normal CURL processing
    }
    else {
       //error_log('Not JSON');
       echo "Invalid resource. We only retrieve JSON/CSV/text resource. The requested URL returned ".$contentType;
    }
    ?>
    

That’s all, folks! Looking forward to hear your thoughts. Cheers!

About Hardono

Hi, I'm Hardono. I am working as a Software Developer. I am working mostly in Windows, dealing with .NET, conversing in C#. But I know a bit of Linux, mainly because I need to keep this blog operational. I've been working in Logistics/Transport industry for more than 9 years.

The past few days I have been scratching my head due to this seemingly simple problem. I can’t change the order of the pages in my Visio document.

Everytime I tried to drag the tab and change the order, it simply refused as shown above.

Today, I finally found out the cause. I need to change the Page Type from Backgroundto Foreground.

Once I did change to all pages, I noticed that the tab title is no longer italic.

About Hardono

Hi, I'm Hardono. I am working as a Software Developer. I am working mostly in Windows, dealing with .NET, conversing in C#. But I know a bit of Linux, mainly because I need to keep this blog operational. I've been working in Logistics/Transport industry for more than 9 years.