Thunderbird chrome not working

If even after adding chrome folder thuderbird doesn’t use your cutomized css, you should try with:

Settings/Options > Advanced > General > Config Editor

toolkit.legacyUserProfileCustomizations.stylesheets > true

update remote wordpress from localhost

Migrate DB is a good tool, even in its free version. You can follow these steps:

  • create a database in remote and import there the local wordpress database, changing some data with Migrate DB (tipically you have to convert the local server path https://localhost/your-local-path/wordpress to //your-remote-path/wordpress, and the local absolute path (such as /mnt/your-PC-path/wordpress) to the remote absolute path (such as https://your-remote-path/wordpress);
  • upload the local wordpress folder to your remote website, via FTP;
  • change in the uploaded folder the wp-config.php file, according to the db user, db name and db server of the remote wordpres database;
  • go to the remote wordpress, login (user and password are identical to the your local wordpress ones), and go to Migrate DB -> settings, and there -> generate/reset API key, copy the 32 char key and paste it in the local Migrate DB push box.
  • So your connection should work, syncing the remote database with the local one.

A problem could arise using Wordfence Security: to update with MigrateDB, you could have to disable temporarliy Wordfence.

link from outside to a part of a file

pdf

It is possible to link a page of a pdf, with the following syntax:

file:///your-path-here/your-pdf-filename-here.pdf#pag=[the-page-number]

or, if the file is within your localhost folder

http://localhost/your-path-here/your-pdf-filename-here.pdf#pag=[the-page-number]

epub

It is possible to link to a given location of an epub file, i.g. with calibre viewer, with a code like the following

file:///your-path-here/your-epub-filename.epub?open_at=epubcfi(/10/2/4/2/132/18/1:65)

You can get the string after open_at (in the above case: epubcfi(/10/2/4/2/132/18/1:65) in the calibre viewer, this way:

  • right click
  • -> go to
  • -> location
  • -> current location (above in the window) : copy

video file

with VLC you can use this code

vlc file:///my-path/my-video.mp4 --start-time=90

where ’90’ are the seconds (after the start of video).

I didn’t manage, so far, to open a video with such a code from a browser.

audio file

You ca do it in several ways. With play (sox) in Linux you can use a code setting not only the start time, but the end one as well:

play '/your-path/your-file.ogg' trim 5:18 =7:01

where 5:18 is the start time, and 7:01 the end one (=7.01 and not = 7:01)

embed a playlist in a web page

After many attempts I finally figured taht it’s impossible embed an audio playlist (such as m3u) to a webpage: you can add only multiple (audio) files, but not a playlist.

I tried with the <audio> tag: nothing to to, even with jquery or javascript. Neither with <embed> or <object> html tags: html developers allow only a single audio playing, not a playlist.

The mimetype “audio/x-mpegurl” doesn’t work.

A Workaround for the Default Gmail “From” Rewrite

Google automatically rewrites the “From” field of any e-mail you send through its SMTP servers to the default address set up in your Gmail account, even if you don’t send the mail directly from Gmail. If you’re not careful, this can tarnish your business image. This small quick fix has to be done before you start sending e-mails to help you keep your branding consistent.

Start by signing into the Gmail account you use with Google SMTP. Click the gear icon in the top left corner, then choose Settings. Select the Accounts and Import tab. Look at the Send mail as section and make sure you have more than one e-mail address set up. If you don’t, add another account, preferably one personalized with your business branding. Now simply make this your default account; Google’s SMTP will automatically rewrite the From field using this address instead of your Gmail account. It’s that simple!

problems with phpmyadim

Sometimes it happens that phpmyadmin (/mysql) don’t allow you to do what it should allow, such as change the encoding of a column (or of a table or of a database), or change the engine of tables.

Then, after many failed attempts via sql query, I found that the easiest solution is

  • export the database
  • do the changes you want through a text editor, such as Kate, i.g., replacing the old enconding with the new one
  • import the (modifyed) database (after deleting/renaming the old one)
  • done!

matrix clients

desktop clients

Unfortunately all the matrix desktop clients we have tested are quite poor from a graphical point of view: very different from whatsapp or telegram ones, and in particular their interface lacks of intuitivity.

Furthermore, the only capable to make a (video or audio) call is Element, while the others work only as messaging app.

mobile clients

There is Element, but I found Schildichat, with a more friendly interface, very similar to WA or Telegram.

svg rounded corner and shadow

shadow (like css shadow-box)

At least with Firefox you can use a filter, like the following:

.shadow{filter: drop-shadow(8px 6px 6px gray);}

rounded corner

The simplest way to round the corners of a box is to

  • use rect element with rx and ry attributes (such as rx="20" ry="20")
  • and define the style of rect with stroke-linejoin:round; and something like stroke:[your color]; stroke-width:[the width you like];

You can see the following example

box rounded

update wordpress in localhost

First of all backup your database follwing these insctructions.

  1. Get the latest WordPress zip (or tar.gz) file.
  2. Unpack the zip file that you downloaded.
  3. Deactivate plugins.
  4. Delete the old wp-includes and wp-admin directories on your web host (through your FTPor shell access).
  5. Using FTP or your shell access, upload the new wp-includes and wp-admin directories to your web host, in place of the previously deleted directories.
  6. Upload the individual files from the new wp-content folder to your existing wp-content folder, overwriting existing files. Do NOT delete your existing wp-content folder. Do NOT delete any files or folders in your existing wp-content directory (except for the one being overwritten by new files).
  7. Upload all new loose files from the root directory of the new version to your existing WordPress root directory.

NOTE – you should replace all the old WordPress files with the new ones in the wp-includes and wp-admin directories and sub-directories, and in the root directory (such as index.phpwp-login.php and so on). Don’t worry – your wp-config.php will be safe.

Be careful when you come to copying the wp-content directory. You should make sure that you only copy the files from inside this directory, rather than replacing your entire wp-content directory. This is where your themes and plugins live, so you will want to keep them. If you have customized the default or classic themes without renaming them, make sure not to overwrite those files, otherwise you will lose your changes. (Though you might want to compare them for new features or fixes..)

Lastly you should take a look at the wp-config-sample.php file, to see if any new settings have been introduced that you might want to add to your own wp-config.php.

More details here.