Browsing articles in "Javascript"

Making Select2 Work with VueJS for Single and Multiselect Menus

Select2 Image

Recently I was migrating a website from a traditional front end; HTML, CSS, jQuery, etc… to Blade with VueJS and all was well in the world until… SELECT2. Getting the jQuery Select2 plugin to work with VueJS did not go well. The select2 menu items were populating, the forms seemed great, easy swap- no problem!  LIES.  ALL LIES.  After finishing up the initial front end migration, naturally I tried to submit my beautiful new VueJS form […]


MagicMin Version 3 Available!

Minifying CSS and Javascript just got way more awesome with MagicMin 3.0.0! Along with better directory path support for windows machines, V3 includes the ability to output merged/minified files with unique hashed filenames for better caching support


Using PHP to merge and minify CSS and Javascript

And yet another ‘bangin’ update!  Don’t use this (I’m going to leave it here for reference), use the magicmin javascript and css minification/caching class instead for performance, better javascript minification, caching, gzip, base64_encoded images, and more! One MAJOR factor in the usability of your website is site load time.  This is affected by a number of factors: the number of images, database queries, and the number of server requests to fetch your stylesheets and javascript […]


Synchronous Input Population Using JavaScript

Synchronization for html input forms

Working with code can often be tedious, and frequently requires programmers to continually reference functions or other sets of code that exists on different pages.  For example: As a relative newbie to wordpress, when creating or modifying files I spend ~70% of my development time looking through files for correct/applicable function usage.  If I wish to display an option to edit a post in a template, I must use “edit_post_link(‘edit’, ‘<p>’, ‘</p>’);”, however, the chance […]


JavaScript Close Window AND Refresh Parent

Earlier today I was working with complex PHP function to update values in a database, within a popout window.  The function worked flawlessly (naturally 😉 ), however I was looking for a way to have immediate display feedback on the parent page. Enter the JavaScript close window refresh parent script… <a id="actions" href="#" onClick="window.close();window.opener.location.reload();">Close Window</a> Looking for more?  Sorry!  That’s it for this crafty little function.