<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://linguifex.com/w/index.php?action=history&amp;feed=atom&amp;title=Module%3Atitle%2FgetCurrentTitle</id>
	<title>Module:title/getCurrentTitle - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://linguifex.com/w/index.php?action=history&amp;feed=atom&amp;title=Module%3Atitle%2FgetCurrentTitle"/>
	<link rel="alternate" type="text/html" href="https://linguifex.com/w/index.php?title=Module:title/getCurrentTitle&amp;action=history"/>
	<updated>2026-04-08T23:08:13Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.6</generator>
	<entry>
		<id>https://linguifex.com/w/index.php?title=Module:title/getCurrentTitle&amp;diff=459869&amp;oldid=prev</id>
		<title>Sware: Created page with &quot;local get_current_title = mw.title.getCurrentTitle  --[==[ A modified version of {mw.title.getCurrentTitle}, which returns the title object for the current title. If the additional optional parameter {fragment} is given, the returned title object will have that value as the fragment, which is the part of the title that comes after {#}, referring to a specific section on the page (e.g. in {&quot;foo#bar&quot;}, the fragment is {&quot;bar&quot;}).  This is a convenience function, which is gen...&quot;</title>
		<link rel="alternate" type="text/html" href="https://linguifex.com/w/index.php?title=Module:title/getCurrentTitle&amp;diff=459869&amp;oldid=prev"/>
		<updated>2025-06-28T09:12:33Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;local get_current_title = mw.title.getCurrentTitle  --[==[ A modified version of {mw.title.getCurrentTitle}, which returns the title object for the current title. If the additional optional parameter {fragment} is given, the returned title object will have that value as the fragment, which is the part of the title that comes after {#}, referring to a specific section on the page (e.g. in {&amp;quot;foo#bar&amp;quot;}, the fragment is {&amp;quot;bar&amp;quot;}).  This is a convenience function, which is gen...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;local get_current_title = mw.title.getCurrentTitle&lt;br /&gt;
&lt;br /&gt;
--[==[&lt;br /&gt;
A modified version of {mw.title.getCurrentTitle}, which returns the title object for the current title. If the additional optional parameter {fragment} is given, the returned title object will have that value as the fragment, which is the part of the title that comes after {#}, referring to a specific section on the page (e.g. in {&amp;quot;foo#bar&amp;quot;}, the fragment is {&amp;quot;bar&amp;quot;}).&lt;br /&gt;
&lt;br /&gt;
This is a convenience function, which is generally only useful when dealing with fragment-only links, as these resolve to other sections on the current page (e.g. [[#foo]] is a link to the section &amp;quot;foo&amp;quot; on the current page). If the {fragment} parameter is not needed, it is more efficient to simply call {mw.title.getCurrentTitle} directly.]==]&lt;br /&gt;
return function(fragment)&lt;br /&gt;
	if fragment == nil then&lt;br /&gt;
		return get_current_title()&lt;br /&gt;
	end&lt;br /&gt;
	local current_title = get_current_title()&lt;br /&gt;
	current_title.fragment = fragment&lt;br /&gt;
	return current_title&lt;br /&gt;
end&lt;/div&gt;</summary>
		<author><name>Sware</name></author>
	</entry>
</feed>