(Sunday, November 30th, 2008)
In the end, transfering a WordPress installation from one server to the next will not have been a simple task. As a matter of fact, moving the files, moving the database, seemed to be the easiest. But I could no longer upload images in WordPress.
Here is what I had to do (and you may have to do) to get back full features and operations:
- Check that PHP was in
safe_mode (not obvious, you’d have access to the server or its administrator).
- Ensure that access rights to the image upload directory (
wp-content/uploads/*) were clearly set to 777 (here again, you’ll need to get support from the adminstrator, or a Telnet/SSH access to your account on the server).
- Since I did not re-install WordPress from scratch, but transfered the full config, I did not notice that the setting for storing of images was now bogus (the directory used on the previous server was not existing on the new server). So, I went back to the admin interface of WordPress > Settings > Miscellaneous and set again
wp-content/uploads as the upload directory (first option on this page and default value as shown/written under it).
I hope that you will not be stung like me…
Find more stories in PHP, WordPress. Tags:
(Sunday, November 9th, 2008)
This is what I told myself when uncovering a little PHP code fragment that stopped working on one of my web sites. So, this is a reminder for those of you inattentive programmers like me: $DOCUMENT_ROOT = $HTTP_SERVER_VARS['DOCUMENT_ROOT']; is deprecated and works no longer. You must now use the newest form: $DOCUMENT_ROOT = $_SERVER['DOCUMENT_ROOT'];.
Be warned.
Find more stories in Blog, HTML and CSS, PHP. Tags:
(Friday, August 24th, 2007)
Some advice provided by Donncha for those who would like to move from PHP4 to PHP5 on a server supporting WordPress exploitation. Nothing big, but it is always good to check the items she points at:
- Location of
PHP.INI
- Update to
mysql and gd libraries
- Compatibility with
WP-cache
Find more stories in PHP, WordPress. Tags:
(Thursday, June 14th, 2007)
Some people have been wondering how I did the random selection of 404 page not found messages that are used on this web site.
So, here is the nice little PHP script that I use here to redirect randomly to one of the right pages:
-
-
<?PHP
-
-
"/404/404-01.php",
-
"/404/404-02.php",
-
"/404/404-03.php",
-
"/404/404-04.php",
-
"/404/404-05.php",
-
"/404/404-06.php",
-
/* "/404/404-07.php", */
-
"/404/404-08.php",
-
"/404/404-09.php",
-
"/404/404-10.php",
-
"/404/404-11.php",
-
"/404/404-12.php",
-
"/404/404-13.php",
-
"/404/404-14.php",
-
"/404/404-15.php",
-
"/404/404-16.php",
-
"/404/404-17.php",
-
"/404/404-18.php",
-
"/404/404-19.php",
-
"/404/404-20.php",
-
"/404/404-21.php",
-
"/404/404-22.php",
-
"/404/404-23.php",
-
"/404/404-00.php"
-
);
-
-
-
header(‘Location: ‘.
$address_list[$randomtopic]);
-
-
?>
You can re-use it on your own web site if you want to. It’s free.
Find more stories in Blog, Create a web site, PHP. Tags:
(Monday, May 28th, 2007)
It is well known that the human brain has pattern matching capabilities much further advanced than those of the best equivalent software programs. This explains that failure rates of OCR (Optical Character Recognition) program may be as high as 1% (or even 2%) of errors, which is requiring later human proof-reading to ensure a reasonable quality for document scans. But when the document is old, badly printed, or degraded, error rates may climb further into the unusable (even more so when we address the scan of thousands of documents like is done by libraries and cultural institutions all over the world).
On another issue, the SPAM problem on the Internet became a major problem: Prorams try to make believe that they are human beings in order to insert advertisment anywhere a user can write (in the messages of a forum, in the comments of a blog, etc). For some time now, it became common that human users must identify themselves by their capacity to recognize a badly written word. Theoretically, this is a very efficient Turing test allowing to differentiate a human from a machine only by the results of their actions. Practically, the abilities of software programs have become so impressive that SPAM is slowly coming back again through those filters named CAPTCHAs (those images that you must read and copy back in order to be identified and approved for a specific action).
The problem appears to be: create CAPTCHA tremendously difficult for the automated software and, simultaneously, bring human beings to the task of checking scans of documents difficult to read by program.
The solution: reCAPTCHA.
The idea is to provide a CAPTCHA service to thousands of bloggers and forum administrators (WordPress, phpBB, etc.) Users are invited to recognize two words specifically difficult to read (profesional OCR programs failed during scans done by Carnegie Mellon University). The user must recognize them both. One is used to check that this is a human being, the other will fill a database of OCR translations that will be used to deliver even more CAPTCHAs and to improve the quality of a document scanned by Carnegie Mellon. Dual core technology: efficiently fight spammers and deliver millions of human users to improve the scan quality of thousands of ancient documents (without using slave labor).
Example of a difficult to read/scan document:
One of the key advantages is that most pro OCR programs can tell when they fail to recognize a character or a word (when they are not confident enough).
Find more stories in Art, Blog, Books, Create a web site, Culture, HTML and CSS, New web site, PHP, SPAM, Sciences, Security, WordPress, bbPress. Tags:
(Thursday, May 3rd, 2007)
More and more often, accessing the Internet becomes limited by the presence of censoring tools and methods (and I am not speaking of those countries where this has been institutionalized like China, Iran or Tunisia). It may be to avoid your spending too much time idling instead of working or it may be to ensure that you do not access to “questionable material”. But the Internet is highly flexible in nature and there may be good solutions to avoid this censorship.
10 – Go to the IP addresss
Instead of connecting through the domain name (example.com), you could connect directly to the IP address (192.168.0.15). It the network stops you at the DNS level, this will allow you to reach the site.
9 – Go to the Google cache
As you certainly know, the Google search engine offers “cached” links after most of its results. Since those are copies of the original web site located on Google servers, it is convenient.
8 – Go to Google mobile search
Google mobile search is made for mobile phone users, but it can be used by countless others.
(more…)
Find more stories in Internet, Lists, PHP, Routers & networks, Tech, Uncategorized. Tags:
(Saturday, April 21st, 2007)
When, as I do, you want to include some bits and pieces of software code in a WordPress post, it starts to become a serious headache. As a matter of fact, WP has not really been prepared for this and it creates a number of issues. Those I already encountered here:
- The <?php tend to disappear (unless you start juggling)
- Some charcaters would not display at all (or badly)
- The overall presentation is pretty bland if you use <code>
So, I looked for a plugin (nearly everything in WordPress is done by adding on of those marvellous little code gems that can be included in a few seconds into the basic configuration) adapted to this task, easy to install (I don’t want to be stuck with heavy maintenance just for this), easy to use.
Here is the summary of what I checked and my opinion regarding them.
(more…)
Find more stories in Blog, Create a web site, HTML and CSS, Java, New web site, PHP, WordPress. Tags:
(Thursday, April 5th, 2007)
Find more stories in Advertising, HTML and CSS, Internet, Java, Legal downloads, PHP, Tech. Tags:
(Sunday, March 25th, 2007)
Software programs to do anything you want with your PC if you are a bit more geeky than most but do not want to pay much. Freeware & shareware.
Find more stories in Books, HTML and CSS, Internet, Linux, Music, P2P, PHP, Printers, Spreadsheet, Tech, Use your D-SLR, Windows Vista, Word processor. Tags: