Web development

Adobe Dreamweaver CC – October 2017 release

First of all, I must confess, I am a big fan of Adobe Creative Cloud!

Aside from the frequently used applications like Photoshop, Illustrator or the new Adobe XD (Experience Design) I went on and installed all the apps.

Yes, ALL of them 🙂

What, there is a new Lightroom CC app, BAM installed it!
Audition CC for music editing, I might need it, BAM installed it!
After Effects CC, but of course, BAM installed it!

Had second thoughts before clicking on Install next to the Adobe Dreamweaver CC because I never liked and used the product. Back in 2003-2004 when I spent my time mostly in Macromedia (Adobe) Flash I installed Macromedia Dreamweaver. Can’t remember exactly (maybe because I found it bloated) but abandoned it and switched to another IDE. Instead and I went on and used PHPDesigner (yes, you can laugh), NetBeans and Eclipse.

From then I always took a poor view of Dreamweaver and avoided it.

Until today when I opened the application and what strucked me was Visual Studio Code alike style and simplicity. Then I found out about some wonderful new features like the Quick Edit which saves time by editing inline code from a css linked file for example.

Using Emmet shortcuts or updating multiple lines of code all at once are also some awesome features. Plus Dreamweaver compiles and generates the files if you want to use CSS preprocessors like LESS or Sass.

Morevor, Git integration and pushing automatically the files to a FTP server.

This being said, I will try to use Dreamweaver as my main IDE in the following weeks to come.

Web development

Encoding space characters in jQuery ajax request

I’ve run into an issue as I was working on a URL shortening tool. Obviously, this tool works with links or URLs. Some URLs can be very messy, let’s take for example Microsoft Forms or files in nested folders in SharePoint Online.

Problem

As I was passing a long URL which contained ” ” space characters I’ve noticed that the jQuery.ajax function was encoding these characters to “+” (plus) sign and not the well known “%20”.  Read 2354 articles, including this very interesting one which states that “URL is still broken to this day”. The takeaway there is that when you encode the space characters you should follow this simple rule:

You should have %20 before the ? and + after.

Even when using encodeURI() function or simply replace() function the value passed was still encoded by jQuery converting the ” ” or “%20” to “+”.

Solution

But finally I found the solution and it was something very basic so that’s why I am sharing this with you. On the official jQuery.ajax() documentation in the list of settings, there is this “processData” which is by default true.

processData (default: true)
Type: Boolean
By default, data passed in to the data option as an object (technically, anything other than a string) will be processed and transformed into a query string, fitting to the default content-type “application/x-www-form-urlencoded”. If you want to send a DOMDocument, or other non-processed data, set this option to false
Normally this is very useful because it processes the data passed but in my case it was messing up the data being sent.
Web development

JS frameworks and libraries madness

Lots have been changing lately in the front-end development scene. New JS frameworks  and libraries appearing, great support and pathos for the already industry recognized ones  lead to a very complicated answer about which is the best one.

But there is no such thing as the best one. One should choose the best which fits to the requirements. In order to do that, one must know and test the frameworks/libraries.

I’ve been playing with AngularJS in the past but in the following weeks I am going to test more Angular, Ember, React, Backbone, Ractive.js and some others.
A very good starting point is the TodoMVC  project which showcases a simple Todo application implemented using the most popular MV* frameworks of today.