New 27Jan2013, updated 11Dec2016
This page is in groups Technology and Publishing.

In this page I will jot down some experience with using WordPress. My general impression after half a year’s usage is that it is excellent for my needs! Same after three years!

WordPress and www.one.com webhotel

January 2013: It was easy to connect the MySQL database and the PHP server, thanks to one.com supplying me with a letter with all the login details. This is not the theme here.

I have experienced some problems with stability and a long response times, including a complete failure with the “Error establishing a database connection” message, with no page being presented, or page with only some pictures. I filled in a support page at one.com about this, attached screen clips with dates and how it looked. Half a day later I got a response where they regretted to have had problems at that time, and that the problem had been resolved. (This was on a Saturday to Sunday, so their 24/7 live support probably did that response.)

However, they added this info (since I am at www.teigfam.net):

Additionally, we also recommend updating the database host that you are currently using in your wp-config.php file. Please edit the wp-config.php file located in the /oyvind/home directory and in it, update:

define(‘DB_HOST’, ‘localhost’);


define(‘DB_HOST’, ‘teigfam.net.mysql’);

When I asked them why this, they replied:

We do not recommend using localhost anymore, as its known to cause
erratic connections to the database server. Hence we have developed a
custom hostname for each webspace, in case of your domain, it is:
teigfam.net.mysql. This should result in better connectivity to the

August 2013: I have still had problems on and off with “Error establishing a database connection”, spurious or even for hours. To verify such an error, it’s important to clear the browser’s cache if in doubt. One.com replied over some period of time that “Our technicians have confirmed that they have located, and solved the issue on the MYSQL server” and after more problems: “Our technicians are in the process of moving some of the domains to a new database server to reduce the load. It will take few more hours for changes to take affect” and after still persisting problems: “Due to this, we have assigned your domain to use our new database servers, which are more stable. I have checked your website now, and it works well again.” The good thing is that they respond fast. I hope it’s over now. I will update here should I experience problems again.

Changing Size of slideshow

See http://wordpress.org/support/topic/changing-size-of-slideshow?replies=10

IE8 picture scaling

See http://wordpress.org/support/topic/ie8-picture-scaling?replies=11. IE8 simply don’t want too large pictures, it will make them non-proportional if larger than 1200×1200. So, make large pictures (like 1600 width) and set them to 60% (=960 width) then it’s (almost?!) ok. All(?) can see nice pictures, and most can see them full size ok by double-clicking on them. But honestly, IE8 users – install Google Chrome and leave IE8 well behind!

Is a 60% picture downloaded in full?

Yes! WordPress lets the browser do the downscaling. If you want short initial download time and few megabyte but still want to present the viewer with something big, here’s the recipe. This may be especially important if you have a page full of pictures.

Make the pictures for your page just the right size. 1600 width 60% is 960, but WordPress sends the larger 1600 picture. Scale it in your system, out of WordPress (like Preview or GraphicConverter on OSX). Upload two: the 1600 and the 960. Use the 960 in your WordPress page. Edit the biggest picture in the WordPress Media Editor and copy the “Permalink” to it (it does not end in jpg etc.!). Then go into the page and edit it, edit the picture and paste that permalink into the picture’s “Link URL” (example of a permalink: http://www.teigfam.net/oyvind/home/?attachment_id=1149). Then, by pressing the picture you get the the picture viewer, with your full pixel also present. Test it here (where the in-page download is 900 and the full width is 4688): http://www.teigfam.net/oyvind/home/models/046-sbb-ae-3_6-ii-h0-scale/#Selection_criteria

Academic style reference list

To make an academic style reference list with numbers enclosed in [..] and correct left margin, here’s the CSS that needs to be inserted into your “style.css” (which resides in your sub-directory, like “twentytwelve-child”). I have a local copy and edit it, and then ftp it up to my site. (You may of course insert this into any referenced CSS in any HTML you might have, WordPress or not.)

ol.ol_href {
    list-style-type: none;
    counter-reset: section;
    padding-left: 0;
ol.ol_href li {
    display: table-row
ol.ol_href li:before {
    counter-increment: section;
    content: "[" counter(section) "] ";
    padding-right: 1em;
    display: table-cell;

You may see an example of its use here: http://www.teigfam.net/oyvind/home/technology/072-pike-sutter-concurrency-vs-concurrency/#References

To use it, just make a standard ordered list in WordPress. Then do Text edit on it and replace <ol> with <ol_href>, example below.

This CSS code is entirely courtesy of Chris Rockwell at http://www.css-discuss.org.

I have missed this for years! However, a five years old iPhone 3G from 2008, with iOS 4.2.1 does it wrongly and loses the list style completely. But all other browsers I’ve tried are fine, even IE8. Also, newer iOS does it correctly. I’ll use this from now on, also update in older blogs.

In order to make the links from the references I do something like this (blue HTML is not in scope here, but it shows how I do header referencing):

<a name="Chapter1"></a>
<h2>Chapter 1 <a href="#Chapter1">:-:</a></h2>
There are some implicit <a href="#Wiki-refs">Wiki-refs</a> at the bottom
Now <a href="#Ref01">[01]</a> probably appears before <a href="#Ref02">[02]</a>.

<a name="References"></a>
<h2>References <a href="#References">:-:</a></h2>
<a name="Wiki-refs"></a>Wiki-refs: Text..
<ol class="ol_href">
    <li id="Ref01">Reference 1 in here</li>
    <li id="Ref02">Reference 2 in here</li>
    <li id="Ref03">Reference 3 in here</li>
    <li id="Ref04">Reference 4 in here</li>
    <li><a name="Ref05"></a>NOT LIKE THIS! Some urls in here won't be clickable</li>

On 17Sept2014 I discoved a problem. I reported it as href contents some times removed if anchor inside list element. I repeated it at http://www.css-discuss.org and Chris Rockwell found the answer. I had used the Ref05 form (above), while it’s the style of those above that’s correct! Thanks, again!

SSL HTTP login

New 1Sep2013, updated 2Sep2013

I probably shouldn’t shout this too load, but the villains probably know it already. The “Smashing WordPress” book by Thord Daniel Hedengren (3rd ed. page 25) tells me that I can add this line to wp-config.php:

define('FORCE_SSL_ADMIN', true);

But Hedengren also states that “SSL won’t work without support from your host”. I asked one.com and they quickly  and concisely replied that “SSL/HTTPS is not supported on our servers. It’s not possible to enable this on our servers.” I don’t think that was the answer I wanted to hear. Update 2Sep2013: In the acknowledgement (bottom) one.com state that they are looking at the possibility of supporting SSL/HTTPS on their servers.

That being said, one.com sent a letter two days ago with this text (translated from Norwegian):

If you are using WordPress on your domain teigfam.net at One.com, we would like to inform you about what we do to ensure your safety when using WordPress.

Over the last few weeks we have seen an increase in attacks on WordPress blogs and websites, not just at One.com, but also from other web hosting providers in the world.

This type of attack, also known as “brute force” attack, focus on getting unauthorized access to your WordPress page, by testing your credentials against a variety of commonly used user name and password “admin” and “123456”.

Since this is important to us, and because we want to protect our customers’ data in the best possible way, we have begun to introduce measures to fight against these attacks. We can already see a decrease in the amount of “brute force” traffic we get, which means that WordPress installation is already much safer.

Make sure your WordPress installation is always up to date. You should also choose a secure password consisting of uppercase and lowercase letters combined with figures.

If you experience any problems when you log into your WordPress page, you are welcome to contact our customer service to help you find a solution.

www.one.com / chat

Also other support (mentioned in this blog note) makes me rather satisfied with their service. But I would like to know why they don’t support encrypted connections between my machine and their servers, so that nobody could listen on it and manipulate – even if I personally don’t think I have experienced that it’s needed. Maybe it isn’t?

I have informed one.com about this blog note 1Sept2013,  and they have acknowledged (with new information, see “Update 2Sep2013” above).

Vertical line to the left of the paragraph

I asked about this at http://wordpress.org/support/topic/vertical-line-to-the-left-of-the-text-in-twenty-twelve. It was resolved:

I added this to my style.css:

/* Thanks to WPyogi 2013 11 18 */
p.p_vline_left_gray {
   border-left: 1px solid #C0C0C0;
   margin-left: 10px;
   padding-left: 10px;

And this usage in the text:

<p class="p_vline_left_gray">Text</p>

Here is a text that uses this class (from Wikipedia):

The exhibition halls and galleries expand over the restored ground floor of two antique buildings: Palazzo Gamucci (which later became the Sisters of Saint Catherine Convent) and Palazzo Ficarelli. The museum highlights the historical and artistic aspects that concerned the city during the Middle Ages.

How to include an excerpt text in an index Post or Page?

Jan-Feb. 2016: See https://wordpress.org/support/topic/how-to-include-an-excerpt-text-in-an-index-post-or-page?replies=3#post-7970261

Collapse-O-Matic plugin

I did a topic on Expand/close all and auto-expand on printing on the WordPress forum.

Update: Even if I did do a search in the documentation, that’s where the answer was! I’m using it first at Towards a taxonomy(?) of CSP-based systems.

Sidebar in multi-column table after text?

See https://wordpress.org/support/topic/sidebar-in-multi-column-table-after-text-2/

I am using the Twenty Twelve theme. When I have short notes the sidebar (on the right side) creeps down to far below the text. Is there a way to put it in a multi-column table when it reaches the end of text? Or, perhaps have only a multi-column section at the bottom? I see that for the mobile version it comes as list at the end. If not Twenty Twelve supports it, is there a WordPress.org theme that does?

An example is here: http://www.teigfam.net/oyvind/home/etc/137-eggekartong-i-to-etasjer/

Email this to someoneShare on FacebookTweet about this on TwitterShare on LinkedIn