Class for TrackBack entries. This attempts to comply with theTrackBack specification at http://www.sixapart.com/pronet/docs/trackback_spec This is used to recieve and send TrackBack pings as well as to access locally stored ping data.
Inherits: LnBlogObject
OnInit | Fired when the object is about to initialize. |
InitComplete | Fired after the object has been initialized. |
POSTRetreived | Fired when POST data for a trackback is retreived. |
OnDelete | Fired when a trackback is about to be deleted. |
DeleteComplete | Fired right after a trackback has been deleted. |
OnReceive | Fired when starting to receive a ping. |
ReceiveComplete | Fired after receiving a ping. |
OnSend | Fired before sending a ping. |
SendComplete | Fired after sending a ping. |
OnOutput | Fired when starting to process for display. |
OutputComplete | Fired when output is sent to the client. |
function title( |
| ) |
An RSS compatibility method for getting the title of an entry.
no_escape | Optional boolean that tells the function to not escape ampersands and angle braces in the return value. |
A string containing the title of this object.
Gets a copy of the parent object.
A BlogEntry or Article object, depending on the context.
function isTrackback( |
| ) |
Determines if an object or file is a saved trackback.
path | The optional path to the trackback data file. If not given, then the object's file property is used. |
True if the data file exists and is under an entry trackback directory, false otherwise
function uri( |
| ) |
Get the URI for various functions
Pulls the trackback data out of the POST and into the object.
As per the TrackBack specification located at http://www.sixapart.com/pronet/docs/trackback_spec, the interface for POSTs is as follows. title - The title of the pinging post. excerpt - An excerpt from the text of the pinging post. blog_name - The name of the blog to which the pinging post belongs. url - The URL of the pinging post. This is the only required field.
function send( |
| ) |
Send a TrackBack ping without using a form.
url | The URL to which the trackback ping will be sent. |
An associative array with 'error', 'message', and 'response' elements. The error element contains the trackback return code from the remote server. The message element contains the error message if there was one. Note that a return code of 0 indicates success, while other values indicate an error. The response element contains the full XML response, for debugging purposes.
Receive a TrackBack ping and store the data in a file. This method also outputs a response in XML for the pinger.
Zero on success, 1 on failure. Note that these are the same return codes described in the TrackBack specificaiton.
Determines if there is a trackback ping in the POST data.
True if there is a ping URL in the POST, false otherwise.
function readFileData( |
| ) |
Reads trackback ping data from a file.
path | Optional path for the data file. Default is the current file. |
function writeFileData( |
| ) |
Write trackback data to a file.
path | The path to which to write the data |
True on success, false on failure.
Put the saved data into a template for display.
The data to be sent to the client.
Permanently delete a trackback.
True on success, false on failure.
Gives the permalink to the trackback entry.
A permalink to the trackback entry.
Gets an anchor to the entry on the page.
The anchor to use for this trackback.
function getFilename( |
| ) |
Converts an anchor from getAnchor or an ID from globalID into a filename.
anchor | The anchor or ID to turn into a filename. |
The path to the trackback file.
Get the global identifier for this trackback.