Johan Benjaminsson

Web developer that likes photography, videography and writing.

Stockholm, Sweden 8 posts

Owl Carousel in FoundationPress

Foundation 6 made me move over from Bootstrap with its ability to define grids in sass @include grid-column(9);. I actually never got into bootstrap at all. The bloatage was to real ;(. The best Wordpress starting theme for Foundation seems to be FoundationPress. So this is how i add Bower components (or Owl Carousel more precisely) to Foundation. Up To Date Since NodeJS is a bit wonky on Windows i make sure that i have the latest version of NodeJS and Bower and run npm cache cleana couple of times before i proceed. Update NodeJS on nodejs.org and run bower update --save-dev. Run bower install OwlCarousel --save. Or bower install OwlCarousel2 --save. In the time of writing this i...

How to Make a Copy of an Umbraco Database

This is how you can move your MSSQL database from dev environment to production. Or if you just need a backup before doing an upgrade. Log in to SQL Management Studio 2014 (it's free) Right click on the database you want to copy and choose Tasks -> Generate Script Choose "Objects" and select "Tables" "Next" under "save to file" choose advanced Script: DROP and CREATE Script for server version 2008 Types of data to script: Schema and Data Choose a place to save the SQL file to Next, Finish! Then just run this script on your production server. If you are overriding an old Umbraco installation i usually get some errors droping all the tables. What i'll do is just...

Security Upgrade on Old Umbraco Sites

Lately i have been having trouble with old Umbraco sites not having the latest security updates. Weird files are added in the root of the site with spam links. This is the workflow i use when security upgrade on Umbraco 4 or 6. I don't really have the guts to alter version 3 sites anymore. Start off with making a backup on the database and the files of the site you are going to upgrade. Download the latest release of the version you are upgrading. Extract into a folder, i usually just name the folder after the release (eg, "4.11.10"). Then create a new folder called "upgrade" and copy the following files and folders over: Bin Config* Install...

Killing Bastards with Umbraco

Red bastards A bastard (or an orphan as you say outside Sweden) is a problem that occurs when a word, part of a word, or a very short line appears by itself at the end of a paragraph. Since most text on the web is not static and probably even have a dynamic width you will very likely end up with this problem. This is how you make your editors happy by letting them slay some bastards. No Wrap You can set the CSS property ´white space´ to ´no-wrap´. This will make line to never wrap to a new line. But we can't add this to all paragraphs. Then we'd get some pretty long lines of paragraphs. So we'll have...

Visual Studio and the Front End

This is second part of my Getting Back to Visual Studio-post. With Visual Studio 2015 and MVC 6 the Microsoft team have given the front end some extra attention. Web essentials ditching the Sass, Less, Coffeescript compiler in favor for Gulp/Grunt and the new folder structure is evidence of that. Normally if you make for example a Laravel-project you'll have the front end preprocessor stuff in a Resources-folder and compile that to the app folder. Or if you make a theme to Wordpress or Ghost you'll probably have a src-folder and compile it to the theme-folder. This workflow will be a lot easier to mimic with the release of MVC 6. But right now we are working with MVC...