18.06.2006, 21:07
|
#21 (permalink)
| | PostRank: 2
Registriert seit: 30.12.2005
Beiträge: 90
| Zitat: |
Zitat von Chris_ Es ist zum Mäuse melken... Bei mir funktioniert es weder mit Änderung der Coezeile noch mit Auskommentieren beider Zeilen...
Naja, kann man wohl nichts machen...
Chris | Hi Chris,
wenn Du noch Nerv hast, ändere mal in der xmlrpc.php in der Zeile 42 PHP-Code: $xmlrpc_logging = 0;
Die 0 zu einer 1.
Wenn dann ein Pingback zu Dir erfolgt, wird eine Logdatei "xmlrpc.log" in dem Verzeichnis *über* Deinem Blogverzeichnis erzeugt.
Bei mir stand bei einem erfolgreichen Pingback "input: blablabla" und "output: blablabla" drin, wenn kein Pinback durchkam, stand dort nur "input: blablablabla".
Erfolgreicher Pingback (mit standard Permalink): Code: 2006-06-18 12:59:32 Input: <?xml version="1.0"?>
<methodCall>
<methodName>pingback.ping</methodName>
<params>
<param><value><string>http://www.fcbui.net/fcblog/?p=91</string></value></param>
<param><value><string>http://www.webrocker.de/blog/index.php?p=142</string></value></param>
</params></methodCall>
2006-06-18 12:59:32 Output: (PB) URI='http://www.webrocker.de/blog/index.php?p=142' ID='142' Found='url_to_postid()' Erfolgreicher Pingback (mit index.php/ Permalink): Code: 2006-06-18 19:12:08 Input: <?xml version="1.0"?>
<methodCall>
<methodName>pingback.ping</methodName>
<params>
<param><value><string>http://www.fcbui.net/fcblog/?p=97</string></value></param>
<param><value><string>http://www.webrocker.de/blog/index.php/2006/06/18/pingback-trackback-scheissdreck/</string></value></param>
</params></methodCall>
2006-06-18 19:12:08 Output: (PB) URI='http://www.webrocker.de/blog/index.php/2006/06/18/pingback-trackback-scheissdreck/' ID='142' Found='url_to_postid()' Nicht erfolgreicher Pingback: Code: 2006-06-18 15:10:28 Input: <?xml version="1.0"?>
<methodCall>
<methodName>pingback.ping</methodName>
<params>
<param><value><string>http://www.fcbui.net/fcblog/?p=95</string></value></param>
<param><value><string>http://www.webrocker.de/blog/index.php/2006/06/18/pingback-trackback-scheissdreck/</string></value></param>
</params></methodCall>
Geändert von Webrocker (18.06.2006 um 21:14 Uhr).
|
| |
18.06.2006, 21:29
|
#22 (permalink)
| | PostRank: 2
Registriert seit: 27.02.2006
Beiträge: 71
| Danke für Deinen Einsatz:
Erster Test, "normale" functions.php, zweiter Test, eine geänderte Zeile, dritter Test beide Zeilen auskommentiert. Und Du warst auch dazwischen. Code: 2006-06-18 19:33:21 Input: <?xml version="1.0"?>
<methodCall>
<methodName>pingback.ping</methodName>
<params>
<param><value><string>http://www.erlebnis-forum.de/board/blog/?p=6</string></value></param>
<param><value><string>http://www.fixmbr.de/index.php/2006/06/18/dr-jekyll-mr-hyde/</string></value></param>
</params></methodCall>
2006-06-18 19:33:21 Output: (PB) URI='http://www.fixmbr.de/index.php/2006/06/18/dr-jekyll-mr-hyde/' ID='2006' Found='from the path'
2006-06-18 19:35:56 Input: <?xml version="1.0"?>
<methodCall>
<methodName>pingback.ping</methodName>
<params>
<param><value><string>http://www.erlebnis-forum.de/board/blog/?p=7</string></value></param>
<param><value><string>http://www.fixmbr.de/index.php/2006/06/18/scripte-der-fernuni-hagen/</string></value></param>
</params></methodCall>
2006-06-18 19:35:56 Output: (PB) URI='http://www.fixmbr.de/index.php/2006/06/18/scripte-der-fernuni-hagen/' ID='2006' Found='from the path'
2006-06-18 19:36:31 Input: <?xml version="1.0"?>
<methodCall>
<methodName>pingback.ping</methodName>
<params>
<param><value><string>http://www.webrocker.de/blog/index.php/2006/06/18/pingbacktest/</string></value></param>
<param><value><string>http://www.fixmbr.de/index.php/2006/06/18/penumbra-horroradventure-fur-lau/</string></value></param>
</params></methodCall>
2006-06-18 19:36:31 Output: (PB) URI='http://www.fixmbr.de/index.php/2006/06/18/penumbra-horroradventure-fur-lau/' ID='2006' Found='from the path'
2006-06-18 19:37:53 Input:
2006-06-18 19:38:26 Input: <?xml version="1.0"?>
<methodCall>
<methodName>pingback.ping</methodName>
<params>
<param><value><string>http://www.erlebnis-forum.de/board/blog/?p=8</string></value></param>
<param><value><string>http://www.fixmbr.de/index.php/2006/06/18/teure-webseite/</string></value></param>
</params></methodCall>
2006-06-18 19:38:26 Output: (PB) URI='http://www.fixmbr.de/index.php/2006/06/18/teure-webseite/' ID='2006' Found='from the path' Liest Du da irgendwas raus?
Chris |
| |
18.06.2006, 21:42
|
#23 (permalink)
| | PostRank: 2
Registriert seit: 30.12.2005
Beiträge: 90
| Zitat: |
Zitat von Chris_ Liest Du da irgendwas raus? | Ja. Das "found: from the path" ist anders als bei mir, dort steht "found: url_to_postid()", das ist die geänderte Function aus der functions.php.
Welche Wordpress-Version läuft bei Dir? Was steht in Deiner xmlrpc.php so in Zeile 1118-1130? PHP-Code: // let's find which post is linked to // FIXME: does url_to_postid() cover all these cases already? // if so, then let's use it and drop the old code. $urltest = parse_url($pagelinkedto); if ($post_ID = url_to_postid($pagelinkedto)) { $way = 'url_to_postid()'; } elseif (preg_match('#p/[0-9]{1,}#', $urltest['path'], $match)) { // the path defines the post_ID (archives/p/XXXX) $blah = explode('/', $match[0]); $post_ID = $blah[1]; $way = 'from the path'; }
gruss
Tom |
| |
18.06.2006, 21:51
|
#24 (permalink)
| | PostRank: 2
Registriert seit: 27.02.2006
Beiträge: 71
| 2.0.3 läuft hier
In meiner xmlrpc.php steht in Zeile 1118-1130 folgendes: PHP-Code: // let's find which post is linked to
// FIXME: does url_to_postid() cover all these cases already?
// if so, then let's use it and drop the old code.
$urltest = parse_url($pagelinkedto);
if ($post_ID = url_to_postid($pagelinkedto)) {
$way = 'url_to_postid()';
} elseif (preg_match('#p/[0-9]{1,}#', $urltest['path'], $match)) {
// the path defines the post_ID (archives/p/XXXX)
$blah = explode('/', $match[0]);
$post_ID = $blah[1];
$way = 'from the path';
} elseif (preg_match('#p=[0-9]{1,}#', $urltest['query'], $match)) {
// the querystring defines the post_ID (?p=XXXX)
Steht das hier bei Dir in der nächsten Zeile: PHP-Code: elseif (preg_match('#p=[0-9]{1,}#', $urltest['query'], $match)) {
Wenn nicht, hab ich das zu viel
Chris |
| |
18.06.2006, 22:06
|
#25 (permalink)
| | PostRank: 2
Registriert seit: 30.12.2005
Beiträge: 90
| hm, ok... alles wie bei mir.
also greift bei dir die url_to_postid() nicht richtig, und dann geht es in der xmlrpc.php weiter und da wird dieses #p/ tralala gecheckt.
ich poste hier mal die komplette url_to_postid() Funktion, wie sie bei mir jetzt in der functions.php steht. Check mal, ob es da irgendeinen Unterschied zu Deiner Version gibt. (functions.php Zeile 178 bis 265): PHP-Code: // examine a url (supposedly from this blog) and try to // determine the post ID it represents. function url_to_postid($url) { global $wp_rewrite;
// First, check to see if there is a 'p=N' or 'page_id=N' to match against preg_match('#[?&](p|page_id)=(\d+)#', $url, $values); $id = intval($values[2]); if ( $id ) return $id;
// Check to see if we are using rewrite rules $rewrite = $wp_rewrite->wp_rewrite_rules();
// Not using rewrite rules, and 'p=N' and 'page_id=N' methods failed, so we're out of options if ( empty($rewrite) ) return 0;
// $url cleanup by Mark Jaquith // This fixes things like #anchors, ?query=strings, missing 'www.', // added 'www.', or added 'index.php/' that will mess up our WP_Query // and return a false negative
// Get rid of the #anchor $url_split = explode('#', $url); $url = $url_split[0];
// Get rid of URI ?query=string $url_split = explode('?', $url); $url = $url_split[0];
// Add 'www.' if it is absent and should be there if ( false !== strpos(get_settings('home'), '://www.') && false === strpos($url, '://www.') ) $url = str_replace('://', '://www.', $url);
// Strip 'www.' if it is present and shouldn't be if ( false === strpos(get_settings('home'), '://www.') ) $url = str_replace('://www.', '://', $url);
// Strip 'index.php/' if we're not using path info permalinks // this is wrong!!!! //if ( false === strpos($rewrite, 'index.php/') ) // $rewrite is an array, not a string // so this should work: if ( false === strpos(key($rewrite), 'index.php/') ) $url = str_replace('index.php/', '', $url);
if ( false !== strpos($url, get_settings('home')) ) { // Chop off http://domain.com $url = str_replace(get_settings('home'), '', $url); } else { // Chop off /path/to/blog $home_path = parse_url(get_settings('home')); $home_path = $home_path['path']; $url = str_replace($home_path, '', $url); }
// Trim leading and lagging slashes $url = trim($url, '/');
$request = $url;
// Done with cleanup
// Look for matches. $request_match = $request; foreach ($rewrite as $match => $query) { // If the requesting file is the anchor of the match, prepend it // to the path info. if ( (! empty($url)) && (strpos($match, $url) === 0) ) { $request_match = $url . '/' . $request; }
if ( preg_match("!^$match!", $request_match, $matches) ) { // Got a match. // Trim the query of everything up to the '?'. $query = preg_replace("!^.+\?!", '', $query);
// Substitute the substring matches into the query. eval("\$query = \"$query\";"); $query = new WP_Query($query); if ( $query->is_single || $query->is_page ) return $query->post->ID; else return 0; } } return 0; }
Ich habe die original Zeile auskommentiert und noch drei Kommentarzeilen reingeschrieben. sollte aber an der funktion nix ändern  |
| |
18.06.2006, 22:18
|
#27 (permalink)
| | PostRank: 2
Registriert seit: 27.02.2006
Beiträge: 71
| Das hört sich doch schon mal positiv an.
Was den Code angeht, haargenau das gleiche bei uns.
Naja, ich danke Dir, wollen wir mal auf die nächste Version hoffen.
LG
Chris |
| |
18.06.2006, 22:25
|
#28 (permalink)
| | PostRank: 2
Registriert seit: 30.12.2005
Beiträge: 90
| hm... sehr merkwürdig.
was steht denn bei dir im backend unter allgemeinen optionen bei
"WordPress-Adresse (URL)" und "Blog-Adresse (URL)" ?
Der einzige Unterschied zwischen unseren Blogs ist, dass meines in einem UNterverzeichnis lebt. Ich habe keine Ahnung, wieso das auf die Permalinks/Pingbacks auswirken sollte, aber man weiss ja nie... |
| |
18.06.2006, 22:29
|
#29 (permalink)
| | PostRank: 2
Registriert seit: 27.02.2006
Beiträge: 71
| Jeweils: Code: http://www.fixmbr.de Btw, wer auch immer den Bug gemeldet hat. Hast Du eine wp-includes/rewrite.php?
Ich nicht, bei mir versteckt sich das ganze in wp-includes/functions.php in Zeile 217 - ich denke, bei Dir auch.
Chris |
| |
18.06.2006, 22:46
|
#30 (permalink)
| | PostRank: 2
Registriert seit: 30.12.2005
Beiträge: 90
| Nee, eine rewrite.php habe ich auch nicht. Alles in der functions.php, so wie bei Dir.
Die letzte Idee, die ich habe:
Schreibe mal das hier in die index.php Deines Themes nach dem header-include: PHP-Code: echo "<!--\n<pre>\n"; print_r( $wp_rewrite->wp_rewrite_rules() ); echo "</pre>\n//-->\n";
und lade Deinen Blog neu. Im Quelltext solltest Du nun eine Auflistung des rewrite-rules Arrays sehen. Schau mal, ob da in der ersten Zeile was von Code: [index.php/ ........] => index.php?...... steht. |
| | | Themen-Optionen | | | | Ansicht | Linear-Darstellung |
Forumregeln
| Es ist dir nicht erlaubt, neue Themen zu verfassen. Es ist dir nicht erlaubt, auf Beiträge zu antworten. Es ist dir nicht erlaubt, Anhänge hochzuladen. Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten. HTML-Code ist aus. | | | Alle Zeitangaben in WEZ +1. Es ist jetzt 00:11 Uhr. | |