Extension:Listings
![]() Release status: beta |
|
---|---|
Implementation | API |
Description | This extension was written for use in imported Wikitravel articles. In future, the tags used should be substituted by templates. |
Author(s) | Roland Unger |
Latest version | 1.03 (2012-08-30) |
MediaWiki | 1.25+ |
License | GNU General Public License 2.0 or later |
Download | |
Quarterly downloads | 1 (Ranked 160th) |
Translate the Listings extension if it is available at translatewiki.net | |
Issues | Open tasks · Report a bug |
Listing is one of the Wikivoyage extensions.
Installation[edit]
- Download and place the file(s) in a directory called
Listings
in yourextensions/
folder. - Add the following code at the bottom of your LocalSettings.php file:
wfLoadExtension( 'Listings' );
Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.
Usage[edit]
Tags[edit]
The Listings extension implements the following tags:
<buy>
<do>
<drink>
<eat>
<listing>
<see>
<sleep>
Attributes[edit]
All tags can be used with the same attributes:
name
Name of the destination.alt
Additional information on the destination. This string can contain Wiki markups.address
Address the destination. This string can contain Wiki markups.directions
Way to or region of the destination. This string can contain Wiki markups.phone
Phone number(s) of the destination.tollfree
Toll-free phone number(s) of the destination.email
Email of the destination.fax
Fax number(s) of the destination.url
URL of the destination.hours
Opening hours of the destination.price
Price for the entrance or for accomodation of the destination.checkin
Check-in time of the hotels.checkout
Check-out-time of the hotels.lat
Position latitude of the destination. This information will be show only iflat
,long
attributes and thelistingsPositionTemplate
string are specified.long
Position longitude of the destination. This information will be show only iflat
,long
attributes and thelistingsPositionTemplate
string are specified.tags
Additional tags (specifications) of the destination. This information is not shown.
Text[edit]
The text included by the starting and closing tags is shown at the end. This string can contain Wiki markups.
Example[edit]
* <see name="National Underground Railroad Freedom Center" alt="Museum" address="50 East Freedom Way" directions="Downtown" phone="333-7500" tollfree="1-877-648-4838" email="info@freedomcenter.org" fax="333-7500" lat="30.1234" long="50.5678" url="http://www.freedomcenter.org" hours="M-Sa 10AM-5PM, Su noon-6PM" price="Admission for one museum or OMNIMAX show: Adults $7.25, Seniors $6.25">Link to the [[Main Page]].</see>
Deprecation[edit]
This extension performs a task which is already possible using standard templates. This appears to have been intended as a means to retain compatibility with an old Wikitravel listings editor which is not in use on Wikivoyage. The default behaviour effectively hard-codes a template-like design and field names into the extension's PHP code; this must be overridden if new fields are to be added without changing the code.
- phab:T45220 implemented a patch which overrides the generated output for this extension by redirecting processing to a template.
- Individual-language Wikivoyage projects have deployed robot scripts to edit every page, replacing the XML tags with voy:template:listing or its local equivalent.
- As of May 2020, phab:T253216 proposes the removal of the extension from Wikivoyage, the only major wiki family using this code.
The tags still work on Wikivoyage, but are deprecated and (at least on en:) any pages still using the tag are being added to a maintenance category.
![]() | This extension is being used on one or more Wikimedia projects. This probably means that the extension is stable and works well enough to be used by such high-traffic websites. Look for this extension's name in Wikimedia's CommonSettings.php and InitialiseSettings.php configuration files to see where it's installed. A full list of the extensions installed on a particular wiki can be seen on the wiki's Special:Version page. |
![]() | This extension is included in the following wiki farms/hosts and/or packages: This is not an authoritative list. Some wiki farms/hosts and/or packages may contain this extension even if they are not listed here. Always check with your wiki farms/hosts or bundle to confirm. |