最近、古いサーバーでは完全に機能しているのに、サーバー コードが機能しないように変更しました。
<?php
ini_set('display_errors', 1);
ini_set('error_reporting', E_ALL | E_STRICT);
$myid = "110988448104041785223";
$plus = file_get_contents("http://plus.google.com/$myid/plusones");
$match = array();
preg_match('/<div aria-hidden="true" class="BT"><a href="(.*?)"/',$plus,$match);
$data['url'] = $match[1];
echo strtolower($data['url']);
?>
戻り値: 未定義のオフセット: 1 in .... 9 行目
これを .htaccess に追加しました (これが必要かどうかはわかりません):
php_value magic_quotes 0
php_flag magic_quotes Off
php_value magic_quotes_gpc 0
php_flag magic_quotes_gpc Off
php_flag allow_url_include On
PHP バージョン 5.2.17 - 古いサーバーは正常に動作します。および PHP バージョン 5.3.23 - 新しいサーバー。
ありがとう