Kiwi Chris Posted June 16, 2017 Share Posted June 16, 2017 I've been a bit like the proverbial plumber with a leaky tap, with a rather ugly site myself, but I've had a period recently with very little work, so I thought it might be time to give my own site Create IT a refresh. I've got more work to do on it, but it's enough of a step up that I'm not totally embarrassed by it now. My site was running on a CMS I've developed myself since 1999 using an obscure language Mivascript, that was actually quite popular at the time, and my first exposure to a server scripting language. To put that in context, the first version of Wordpress only came out in 2003, and to be honest my code looks quite messy in the light of modern programming best practice. I've decided I'd rather focus on adding functionality and content than maintaining an entire CMS myself, and I love Processwire for its speed and flexibility of development. I had to import my existing content which was in a mySQL database. Having written the system myself, I knew the data structure well, so the issue was how to replicate the functionality. My old CMS was started before the days of SEO and security got a great deal of attention so I had urls like index.mvc?article=6. I had to come up with a safe way to redirect these to knew Processwire URLS. The Jumplinks module came to the rescue there, as when I'd imported my data, I'd already imported the old page ids into a field in processwire, so it ended up being pretty easy to provide automatic redirects from the old URLs with just a single jumplink using a selector. The other thing I wanted to do was use Bootstrap, but customise it without creating a mess of overrides.AIOM+ came to the rescue here, with its built in ability to compile LESS files. Rather than messing around with any third party LESS compiler, I could just put the Bootstrap source directly into my project and include the LESS files directly. Processwire never fails to impress how quickly and efficiently it enables often quite complex things to be done. 6 Link to comment Share on other sites More sharing options...
rick Posted June 16, 2017 Share Posted June 16, 2017 Looks good! One item: The blog menu shows, Security & Privacy rather than Security & Privacy. Link to comment Share on other sites More sharing options...
Kiwi Chris Posted June 17, 2017 Author Share Posted June 17, 2017 14 hours ago, rick said: Looks good! One item: The blog menu shows, Security & Privacy rather than Security & Privacy. Oops! Good spotting. Fixed now. I still need to go through and clean up a lot of the old content, as some of it's ancient, and maybe not all that relevant now, but I wanted to get the new site up ASAP as the old one was ugly. At least Processwire is both developer and end-user friendly, so I can go through and clean up the content pretty quickly. Link to comment Share on other sites More sharing options...
Mike Rockett Posted June 17, 2017 Share Posted June 17, 2017 Glad to know Jumplinks came to the rescue here (and that you used selectors), however it doesn't appear to work as index.mvc is still on the server. So if I request /index.mvc?article=6, it attempts to download the mvc file instead of redirecting. I'd also recommend moving the CSS reference up to the head to avoid the FOUC. Link to comment Share on other sites More sharing options...
Kiwi Chris Posted June 17, 2017 Author Share Posted June 17, 2017 10 minutes ago, Mike Rockett said: Glad to know Jumplinks came to the rescue here (and that you used selectors), however it doesn't appear to work as index.mvc is still on the server. So if I request /index.mvc?article=6, it attempts to download the mvc file instead of redirecting. I'd also recommend moving the CSS reference up to the head to avoid the FOUC. Thanks for spotting. It worked fine on my WAMP development server, but of course I didn't have the .mvc file there. I've renamed it, and tested for an actual URL from the old site /index.mvc?ArticleID=181 and it's working as it should. With regard to the CSS, I was trying to follow best practice according to Google Pagespeed Insights, but perhaps I'm being a bit overly picky trying to get a good Pagespeed rating. 1 Link to comment Share on other sites More sharing options...
Mike Rockett Posted June 17, 2017 Share Posted June 17, 2017 @Kiwi Chris - great, working fine now. Re: css: Yeah, I'd keep it in the head and perhaps gzip it (you're already using aiom, so most of the work is done already). Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now