↓
 

A Pipe and a Keyboard

A sort of Linux scrapbook

  • Home
  • About
  • Software
  • List of posts

Category Archives: Tech stuff

Post navigation

<< 1 2 … 6 7 8 9 10 11 12 … 27 28 >>

Firefox Nightly – tabs on top

A Pipe and a Keyboard Posted on November 28, 2012 by RichardNovember 28, 2012

My browser of choice is Firefox Nightly which is currently V20.0a1.

I like to see the development process where the developers play around with various layouts and techniques, such as how they handle downloads and the general layout.

Lately they made a change which I found a little frustrating – they moved the tabs above the toolbars and removed the option to change this from the menu.  I am used to the old “tabs on bottom” layout so had to find a way around this.

The solution is, of course, simple….

In about:config just toggle the entry – browser.tabs.onTop to read “false”.

That’s all!

Posted in Tech stuff | Leave a reply

Installing Linux Mint 14 (Nadia)

A Pipe and a Keyboard Posted on November 20, 2012 by RichardNovember 20, 2012

They haven’t officially announced it at the time of writing, but Linux Mint 14 (Nadia) was released a couple of days ago.

Naturally I had to download and install!  I used the MATE 64bit edition and for various reasons I installed Cinnamon on top.

I decided on a complete reinstall including formatting my Home partition, so I backed up everything and formatted.

As usual the process was painless.  Nadia installed without a glitch.  However the process was not without a couple of minor problems which led to a little frustration.

The first problem that I encountered was a strange one.  While running through the list of packages (listed on the Software page of this site) I installed Audacity.  When I ran a test I discovered the problem – Audacity had no menu-bar!  After trying the usual reinstall and the like with no success I resorted to the Internet.  As usual I had to wade trough a series of solutions that didn’t work, but eventually found one that did.

The solution involved a hack to the code using the following:

sudo mv /usr/bin/audacity /usr/bin/prog-audacity
gksudo pluma /usr/bin/audacity

In the above, you may want to change “pluma” to your own editor, such as “gedit”.

In the editor insert the following lines :

#! /bin/bash

export UBUNTU_MENUPROXY=0
prog-audacity

Save the file and then run

sudo chmod a+x /usr/bin/audacity

That sorted the problem and now Audacity runs as normal.

This may just be a temporary glitch such as a missing library, but my Internet searches gave no clues. 

As a footnote, I also ran into problems installing Google Earth.  I remembered seeing a mention of this on the Mint blog, so I tried Clem’s fix.  It worked, so it appears the bug hadn’t been fixed before full release!

–oOo–

Update

Almost immediately I found a major flaw in the fix above.

I use Audacity Nightly which was updated shortly after I posted this.  That of course overwrote my modification.

A bit of further research led to a permanent solution.Apparently it is a wxwidgets problem.

The solution.  Enter the following –

sudo apt-get purge appmenu-gtk appmenu-gtk3 appmenu-qt


That seems to have done the trick!

Posted in Linux, Tech stuff | Tagged Linux | 12 Replies

A new home for an old site

A Pipe and a Keyboard Posted on November 7, 2012 by RichardNovember 7, 2012

There are two ways of moving a WordPress site from one server to another.

One is to create a database, and then copy all files to the new server, point wp-config at the new database and copy the contents of the database across.  This is the simplest way and ideal if, for example you are switching hosts.

The other method is trickier, but a lot more efficient, creating a leaner and faster site.  I have just completed a transfer of Head Rambles using this method.

The first thing is to create a new blank database on the new server, using a spare domain name for access.  Then upload a fresh copy of WordPress and using its built in features, create a new WordPress site.  The new site should be set up with the same Title and Subtitle as the old site, but using the new domain.

Next, copy across the theme files from the old server.  In my case I did a fresh install of Weaver II and then copied over the little backup files.  Any specific image files [such as the Banner and any images in the sidebar] should be copied across also.

At this point the new site should look identical to the old, but contain no posts or pages.

In my case, I then backed up the old database but did it one table at a time.  I then imported into the new database the following tables – Posts, Postmeta, Comments, Commentmeta, Terms, Term_relationships, Term_taxonomy and Links.  If the new database has been set up with a different prefix from the old [for example, if the old was WP_ and the new one is NEW_] then before uploading the files to the database, open them in a text editor and do a simple search and replace.

Don’t forget to copy over a copy of wp-content/uploads.

Now is the time to transfer plugins.  The ideal is to upload fresh copies of each plugin to the new site.  This is the time to decide which plugins are really necessary and which ones can be dumped.  Be ruthless!

At this point the site should be running smoothly and be identical in all respects to the old, apart from the domain name.  Now is the time to test that all the plugins are functioning correctly and that the site is behaving itself.

The next part is the tricky part.

Shut down the old site for changes [for example, disable comments]. Take another backup of the Comments database tables [and Posts if that has changed].  Upload these to the new database.

Now point the domain to the new server.  While that is propagating, open up the Options table in the new database and change every instance of the temporary domain to the permanent domain.

Once the domain has switched and is pointing at the new server the job is complete.  You should now have a much leaner faster site.

In the case of Head Rambles, the database dropped in size from 54Mb to 32Mb and from 34 to 17 tables.  Average page load time dropped from 1.48 seconds to 0.66 seconds which is quite impressive?  The main losses were database entries from redundant plugins and trimming the Options table from 16,225 records to 276 [a saving of 4.7Mb!].

The only problem I had was in switching the domain, where a couple of DNS servers got locked up for some reason.  It meant the whole domain was dead for a while, but the wait and the trouble was worth it.

To be safe, I have kept the old site running but with a different domain name.  It is blanked out for the general public but I can access it, for example if I need to cross check settings or retrieve any logs.  Once I am happy that it is redundant it, and its bloated database can be scrapped.

Posted in Blogging, Tech stuff | Leave a reply

Working with Weaver II–Part 3

A Pipe and a Keyboard Posted on November 2, 2012 by RichardNovember 2, 2012

One of the big problems with customising themes is that the theme’s core files have to be modified.

So you spend a happy few hours modifying style.css and you get the site looking just as you wish.  Then along comes an update to the theme which nicely overwrites your customised style.css and you are back to where you started. 

Of course you should have a backup of your customised file, but suppose the update included the theme author’s updates to style.css? 

As I have already pointed out, Weaver has the facility to insert your own code (CSS or HTML) into the header or footer of the site without any file editing.

An example of this is in the layout of the nested comments on the theme.  I felt that the reply to a comment wasn’t indented enough, and could lead to some confusion, as it wasn’t immediately obvious whether a comment was a new comment in its own right, or a reply to a previous comment.

Indent1

The obvious way was to modify the style.css file but I went the route of adding an insert of some CSS into the Header in the (Advanced) Admin area –

.commentlist li.comment, #respond  {
margin-left: 15px !important;
}

This had the desired effect.  The effect is small but significant enough to improve readability –

Indent2

Since I made that modification, there has been an update to the Weaver theme.  I applied the update and all my modifications remained intact.

Another hugely significant feature is that in the event of catastrophic failure I only need three things –

  1. A database dump (mailed to me daily via a plug in)
  2. A copy of the images I have created
  3. A tiny XML file which Weaver creates and which contains all the modifications I have applied to the theme, including code inserts.

Every other item I need can be downloaded from the Internet.

Not many themes can do that?!

Posted in Blogging, Tech stuff | 8 Replies

Working with Weaver II–Part 2

A Pipe and a Keyboard Posted on October 23, 2012 by RichardOctober 23, 2012

I mentioned before that I had rejigged my three blogs to use Weaver II.

I am currently in the process of designing another (for a friend of a friend) and am once again using Weaver II.

It has become a real challenge to see just how far I can go without changing any code whatsoever in the core Weaver II files.  So far I am really impressed.

One of the big features is the ability to insert snippets of additional HTML, CSS or Javascript into parts of the site just by entering those snippets in at the Admin area. 

WeaverDash

So far I have been able to add CSS animation, customise a plugin’s display and to layout a complete page using CSS.  The latter was done by entering the various blocks (DIVs) on the page itself and then using custom CSS to handle those blocks.

I did come across a couple of areas though where in the bad old days I would have modified the raw code.  In particular I wanted to be able to place my own code in specific areas on pages.  For example, I wanted to insert some additional text onto the Comment form and also some Javascript (for Google Ads) onto posts.  The way around this was to install another plugin – Code Insert Manager – which does exactly what I want.  I realise there are plugins for Google Ads, but the Insert Manager does this and a lot more besides.

So far, I have managed to do everything without any file editing with one small exception – I use the CKEditor plugin for WYSIWYG comment editing and I wanted to modify the available buttons.  This isn’t possible from the admin area so I finally had to resort to tweaking the plugin’s file.

Weaver II also has its own plugin (Weaver II Theme Extras) which is essential as it contains an excellent backup feature.  All non-default settings and code additions to Weaver II are backed up to a small file which can be stored locally.  In the event of catastrophic failure the entire site can be restored using the standard installation files and then retoring all the various modifications using the backup file.

That’s assuming you have a backup of the database and images, of course!

Posted in Blogging, Tech stuff | Leave a reply

Post navigation

<< 1 2 … 6 7 8 9 10 11 12 … 27 28 >>

Recent Posts

  • GRUB problems
  • Tab bar broken again in Firefox 133
  • WP phpMyAdmin Session mismatch
  • When Linux slows down
  • Firefox broken again

Categories

  • Blogging
  • General
  • Linux
  • Media
  • Tech stuff
  • Writing

Blogroll

  • Head Rambles
  • Kirk M's Just Thinkin'
  • Wordpress Beginner
  • Wordpress Development

Archives

©2025 - A Pipe and a Keyboard - Weaver Xtreme Theme
↑