<link href="../fonts/font.css" rel="stylesheet" type="text/css">

<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="fa">
		<id>https://wiki.imaroof.ir/index.php?action=history&amp;feed=atom&amp;title=%D8%A7%D9%84%DA%AF%D9%88%3AIfnotempty</id>
		<title>الگو:Ifnotempty - تاریخچهٔ ویرایش‌ها</title>
		<link rel="self" type="application/atom+xml" href="https://wiki.imaroof.ir/index.php?action=history&amp;feed=atom&amp;title=%D8%A7%D9%84%DA%AF%D9%88%3AIfnotempty"/>
		<link rel="alternate" type="text/html" href="https://wiki.imaroof.ir/index.php?title=%D8%A7%D9%84%DA%AF%D9%88:Ifnotempty&amp;action=history"/>
		<updated>2026-08-02T04:23:55Z</updated>
		<subtitle>تاریخچهٔ ویرایش‌های این صفحه در ویکی</subtitle>
		<generator>MediaWiki 1.26.2</generator>

	<entry>
		<id>https://wiki.imaroof.ir/index.php?title=%D8%A7%D9%84%DA%AF%D9%88:Ifnotempty&amp;diff=2569&amp;oldid=prev</id>
		<title>Admin: ۱ نسخه واردشده</title>
		<link rel="alternate" type="text/html" href="https://wiki.imaroof.ir/index.php?title=%D8%A7%D9%84%DA%AF%D9%88:Ifnotempty&amp;diff=2569&amp;oldid=prev"/>
				<updated>2016-03-03T13:24:59Z</updated>
		
		<summary type="html">&lt;p&gt;۱ نسخه واردشده&lt;/p&gt;
&lt;table class='diff diff-contentalign-right'&gt;
				&lt;tr style='vertical-align: top;' lang='fa'&gt;
				&lt;td colspan='1' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;→ نسخهٔ قدیمی‌تر&lt;/td&gt;
				&lt;td colspan='1' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;نسخهٔ ‏۱۳ اسفند ۱۳۹۴، ساعت ۱۳:۲۴&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan='2' style='text-align: center;' lang='fa'&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(بدون تفاوت)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Admin</name></author>	</entry>

	<entry>
		<id>https://wiki.imaroof.ir/index.php?title=%D8%A7%D9%84%DA%AF%D9%88:Ifnotempty&amp;diff=2568&amp;oldid=prev</id>
		<title>Pourrezaei در ‏۱۵ مرداد ۱۳۹۴، ساعت ۱۱:۴۲</title>
		<link rel="alternate" type="text/html" href="https://wiki.imaroof.ir/index.php?title=%D8%A7%D9%84%DA%AF%D9%88:Ifnotempty&amp;diff=2568&amp;oldid=prev"/>
				<updated>2015-08-06T11:42:43Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;صفحهٔ تازه&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;lt;includeonly&amp;gt;{{ {{{|safesubst:}}}{{ {{{|safesubst:}}}#if:{{{1}}}|p1|p2}}|{{{2}}}|{{{3|}}}}}&amp;lt;/includeonly&amp;gt;&amp;lt;noinclude&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Documentation|content=&lt;br /&gt;
&lt;br /&gt;
With this template [[mw:Help:Extension:ParserFunctions|#if]] can be used in a way such that it does not [[m:Help:Newlines_and_spaces#Stripping_on_expansion|strip spaces and newlines]] from the &amp;quot;then&amp;quot; and &amp;quot;else&amp;quot; part. For evaluating the condition spaces and newlines are stripped like with ParserFunctions.&lt;br /&gt;
&lt;br /&gt;
This template can be substituted.&lt;br /&gt;
&lt;br /&gt;
==Usage==&lt;br /&gt;
*&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{ifnotempty| x | A | B }}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; gives &amp;quot;{{ifnotempty| x | A | B }}&amp;quot;&lt;br /&gt;
*&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{ifnotempty|x| A | B }}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; gives &amp;quot;{{ifnotempty|x| A | B }}&amp;quot;&lt;br /&gt;
*&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{ifnotempty| | A | B }}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; gives &amp;quot;{{ifnotempty| | A | B }}&amp;quot;&lt;br /&gt;
*&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{ifnotempty|| A | B }}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; gives &amp;quot;{{ifnotempty|| A | B }}&amp;quot;&lt;br /&gt;
Compare:&lt;br /&gt;
*&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{#if:x| A | B }}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; gives &amp;quot;{{#if:x| A | B }}&amp;quot;&lt;br /&gt;
*&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{#if:| A | B }}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; gives &amp;quot;{{#if:| A | B }}&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==Internal technical details==&lt;br /&gt;
For evaluating the condition (determining non-emptiness of the first parameter) the template uses parser function #if, producing 1 if the condition is true, and 2 otherwise. The template with name equal to &amp;quot;P&amp;quot; followed by the index value produced (hence [[Template:P1]] or [[Template:P2]]), is called with as parameters A and B. This produces either A or B, without trimming.&lt;br /&gt;
&lt;br /&gt;
==See also==&lt;br /&gt;
*[[Template:If]]&lt;br /&gt;
*[[m:Template:Ifnotempty]]&lt;br /&gt;
&lt;br /&gt;
[[Category:If-then-else templates]]&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>Pourrezaei</name></author>	</entry>

	</feed>