Trackback points node url's when auto path's impemented.

nuvious - July 21, 2009 - 05:35
Project:TrackBack
Version:6.x-1.2
Component:Other
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active
Description

http://www.dcheeseman.com/blog/post/barny-frank-knows-his-public

I've got automatic url renaming implemented and the trackbacks point to trackback urls?

Example from above page:
http://www.dcheeseman.com/blog/trackback/60

#1

grateful_drupal_user - November 28, 2009 - 05:46

Would this work?
In the file trackback.ping.inc, function _trackback_ping, lines 202-206,

<?php
    $params
= array(
     
'title' => $node->title,
     
'excerpt' => truncate_utf8(trim(strip_tags($excerpt)), 255),
     
'blog_name' => variable_get('site_name', ''),
     
'url' => url('node/'. $node->nid, array('absolute' => TRUE))
    );
?>

change:
<?php
   
'url' => url('node/'. $node->nid, array('absolute' => TRUE))
?>

to:

<?php
    
'url' => url(drupal_get_path_alias('node/'. $node->nid), array('absolute' => TRUE))
?>

If so, this should probably be enabled by an admin setting (some may disagree with using aliases, as the alias may change, thus breaking old trackbacks).

I think this is really a feature request and not a bug report, though.

 
 

Drupal is a registered trademark of Dries Buytaert.