<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Adhamian approach !</title>
	<atom:link href="http://theadhamian.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://theadhamian.wordpress.com</link>
	<description>Web &#38; IT from my adhamian approach</description>
	<lastBuildDate>Thu, 16 Dec 2010 00:17:40 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='theadhamian.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Adhamian approach !</title>
		<link>http://theadhamian.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://theadhamian.wordpress.com/osd.xml" title="Adhamian approach !" />
	<atom:link rel='hub' href='http://theadhamian.wordpress.com/?pushpress=hub'/>
		<item>
		<title>ببساطة ،، تحليل الخوارزميات</title>
		<link>http://theadhamian.wordpress.com/2010/12/15/%d8%a8%d8%a8%d8%b3%d8%a7%d8%b7%d8%a9-%d8%8c%d8%8c-%d8%aa%d8%ad%d9%84%d9%8a%d9%84-%d8%a7%d9%84%d8%ae%d9%88%d8%a7%d8%b1%d8%b2%d9%85%d9%8a%d8%a7%d8%aa/</link>
		<comments>http://theadhamian.wordpress.com/2010/12/15/%d8%a8%d8%a8%d8%b3%d8%a7%d8%b7%d8%a9-%d8%8c%d8%8c-%d8%aa%d8%ad%d9%84%d9%8a%d9%84-%d8%a7%d9%84%d8%ae%d9%88%d8%a7%d8%b1%d8%b2%d9%85%d9%8a%d8%a7%d8%aa/#comments</comments>
		<pubDate>Wed, 15 Dec 2010 22:59:26 +0000</pubDate>
		<dc:creator>3m masr</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://theadhamian.wordpress.com/?p=72</guid>
		<description><![CDATA[&#160; السلام عليكم و رحمة الله و بركاته الكلام عن تحليل الخوارزميات &#8211; من وجهة نظري &#8211; أفضل طريقة له هي السؤال و الجواب يعني مثلا يعني اية تحليل الخوارزم المعين ؟ لو انا عاوز مثلا أعمل ترتيب لدفعة تالتة حاسبات من حيث الدرجات و جيت ادور على خوارزميات ممكن تعمل لي ترتيب هالاقي خوارزميات [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=72&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p dir="rtl">&nbsp;</p>
<p style="text-align:right;">السلام عليكم و رحمة الله و بركاته</p>
<p style="text-align:right;">الكلام عن تحليل الخوارزميات &#8211; من وجهة نظري &#8211; أفضل طريقة له هي السؤال و الجواب يعني مثلا</p>
<p style="text-align:right;">يعني اية تحليل الخوارزم المعين ؟</p>
<p style="text-align:right;">لو انا عاوز مثلا أعمل ترتيب لدفعة تالتة حاسبات من حيث الدرجات و جيت ادور على خوارزميات ممكن تعمل لي ترتيب هالاقي خوارزميات كتير جدا ،، طب اختار الخوارزم المعين و اسيب الباقيين على أي اساس ؟</p>
<p style="text-align:right;">المعيار الاساسي اللي بيفرق بين خوارزم و التاني هو سرعة الاداء بتاعهم فالخوارزم اللي بيأدي أسرع ممكن نضحي بجزء من سرعته لزيادة دقة الحل مثلا ( لو انا مثلا بادور على خوارزم في مجال التحليل العددي Numerical analysis هايهمني قوي إني أوصل لدقة أكبر )</p>
<p style="text-align:right;">هنا ممكن يكون الخوارزم اللي اخترته أسرع بس دقته أقل فاضطر اعدل الخوارزم بحيث يطلع دقة أكبر بس في المقابل هاضحي بجزء من سرعته ،، معنى كدا ان الخوارزم السريع بيمكنني من اني اضيف فيه أي مميزات و أدفع في المقابل من سرعته لذلك بيعرفوا السرعة على انها عملة الكمبيوتر ،، ممكن أضحي بالسرعة في مقابل مميزات تانية كمان ،، انما لو الخوارزم اصلا بطيء يبقى انا مش معايا العملة اللي هادفعها في مقابل المميزات اللي عاوزها في الخوارزم بتاعي</p>
<p style="text-align:right;">العامل الاساسي اللي بتتوقف عليه السرعة في الغالب هو كمية المدخلات اللي داخلة للخوارزم ،، بمعنى ان لو الدفعة اللي انا عاوز ارتبها مثلا كان عددها 100 طالب غير لما يكون عددها 8000 اكيد الوقت المطلوب عشان ارتب 8000 طالب هايكون أكبر ،، و السبب في كدا ان الوقت المطلوب لتنفيذ الخوارزم هو دالة في المدخلات و دة معناه ان</p>
<p style="text-align:right;">لو عندي خوارزم الوقت بتاعه  = ( المدخلات ) ^2 يبقى مطلوب 10000 وحدة زمن عشان يرتب الـ100 طالب حسب درجاتهم بينما لو الوقت بتاعه = ( المدخلات)^3 هانحتاج 1000000 وحدة زمن !!</p>
<p style="text-align:right;">بنستنتج من كل دة ان تحليل الخوارزم هو ايجاد الدالة اللي بتمثل العلاقة بين مدخلاته و الزمن اللي هايستغرقه</p>
<p style="text-align:right;">&nbsp;</p>
<p style="text-align:right;">هل نوع المدخلات بيأثر في الزمن المطلوب ؟</p>
<p style="text-align:right;">أكيد اه ،، لان لو انا دخلت للخوارزم مصفوفة فيها الطلاب مترتبين اصلا يبقى هو كدا مش هايعمل اي شغل !! انما لو اديت له المصفوفة دي متلخبطة ،، يعني عشوائية كدا يبقى هو هايرتب يعني هايعمل خطوات و ممكن في أسوأ حالة تكون المصفوفة مترتبة بالعكس !! يعني هايضطر كدا يعمل أكبر كمية شغل ممكنة !! اذن انا عندي تلات حالات للمدخلات اللي جاية لي في الخوارزم</p>
<p style="text-align:right;">Best case</p>
<p style="text-align:right;">Average case</p>
<p style="text-align:right;">Worst case</p>
<p style="text-align:right;">لذلك لما احلل خوارزم هاحلله على التلات حالات دول يعني هابقى محتاج أعرف لو الخوارزم دة جات له أفضل الحالات هاياخد وقت قد اية ،، طب لو جات له حالة متوسطة ( يعني المصفوفة نص مترتبة ) هاياخد وقت قد اية ،، طيب ماذا لو جت أسوأ حالة خالص إن المصفوفة تكون مترتبة بالعكس تماما بقا !!  طبيعي احنا لازم نتوقع الأسوأ عشان كدا أهم حالة عندنا هي الورست كايس ،، أهم ما في تحليل الخوارزم هو اجابة سؤال : الخوارزم دة هاياخد وقت قد اية لو كانت المدخلات معكوسة ؟</p>
<p style="text-align:right;">Asymptotic analysis</p>
<p style="text-align:right;">الدالة اللي بتمثل العلاقة بين عدد مدخلات خوارزم و الوقت اللي بيستغرقه مش لازم تكون حد واحد ممكن تكون دالة تربيعية</p>
<p style="text-align:right;">f(x) = ax^2 + bx +c</p>
<p style="text-align:right;">أو دالة تكعيبة او دالة خطية او غير كدا ، بس لما بنعمل تحليل لخوارزم بنهمل كل الحدود غير المؤثرة بشكل كبير يعني لو عندنا دالة لخوارزم معين هي f(x) = 3x^3 + 2x+17</p>
<p style="text-align:right;">لاحظ كدا الجدول دة</p>
<table width="226">
<tbody>
<tr>
<td style="text-align:center;">x</td>
<td style="text-align:center;">3x^3</td>
<td style="text-align:center;">2x</td>
<td style="text-align:center;">17</td>
</tr>
<tr>
<td>10</td>
<td>3000</td>
<td>20</td>
<td>17</td>
</tr>
<tr>
<td>100</td>
<td>3000000</td>
<td>200</td>
<td>17</td>
</tr>
<tr>
<td>1000</td>
<td>3000000000</td>
<td>2000</td>
<td>17</td>
</tr>
<tr>
<td>10000</td>
<td>3000000000000</td>
<td>20000</td>
<td>17</td>
</tr>
</tbody>
</table>
<p style="text-align:right;">لاحظ بقا الحد الاولاني ( الاكس تكعيب ) و الفرق الرهيب بينه و بين الحد التاني و التالت خصوصا لو المدخلات ( الاكس ) زادت قوي ،، تخيل لو احنا عاوزين نرتب بقا دفعة تجارة ! او عاوزين نرتب سكان جمهورية مصر العربية حسب السن !!! في الحالة دي هانلاقي ان الحد التاني و التالتة لا يقارنوا بالحد الاولاني و الفرق بينهم رهيب ،، لو قسمتهم على بعض هابقى بتقسم مالا نهاية على رقم !</p>
<p style="text-align:right;">لذلك أهم ما في التحليل هو اكبر الحدود من ناحية الأس لان الأس هو اللي بيأثر بشكل كبير جدا لما حجم ( عدد ) المدخلات يزيد جدا فاذا كان عندي خوارزم دالة الوقت بتاعته هي</p>
<p style="text-align:right;">f(x) = x^2 + 4x^6 +678</p>
<p style="text-align:right;">باقول ان الخوارزم دة O(x^6)</p>
<p style="text-align:right;">و بتتنطق كدا ،، بيج او اوف اكس^6 و دة بينقلنا لجزئية تانية مهمة</p>
<p style="text-align:right;">Asymptotic notations</p>
<p style="text-align:right;">دالة البيج او دي بتوضح لينا الحد الاقصى من الوقت اللي عمر الخوارزم  ما هايعديه ،، يعني نقدر نقول ان</p>
<p style="text-align:right;">C*x^6 &gt;= T(x) ,, where T(x) is the time of an algorithm which is Big-O of x^6</p>
<p style="text-align:right;">هل في دوال تانية بتوضح لي حدود الزمن اللي بياخده الخوارزم ؟</p>
<p style="text-align:right;">أيوة في دالة الثيتا و دالة البيح أوميجا بحيث ان لو كان الخوارزم من نوع <strong>θ</strong>(x^6)</p>
<p style="text-align:right;">دة معناه إن</p>
<p style="text-align:right;">C1*x^6&lt;= T(x) &lt;=C2*x^6</p>
<p style="text-align:right;">و لو كان الخوارزم من نوع <strong>Ω(x^6) </strong></p>
<p style="text-align:right;">دة معناه إن</p>
<p style="text-align:right;">C*x^6 &lt;= T(x)</p>
<p style="text-align:right;">&nbsp;</p>
<p style="text-align:right;">نستنتج من كدا إن :-</p>
<p style="text-align:right;">Big-O Indicates the UPPER BOUND of the time an algorithm takes .</p>
<p style="text-align:right;">Big-<strong>Ω </strong>indicates the LOWER BOUND an algorithm takes .</p>
<p style="text-align:right;">θ indicates the area in which an algorithm falls .</p>
<p style="text-align:right;">طب اية هي الثوابت دي ؟</p>
<p style="text-align:right;">لما كنا بنحسب البيج او بتاعت خوارزم أهملنا الحدود الأقل تأثيرا ،، بس لما أقول إن الحد الأقصى للوقت اللي هايستهلكه الخوارزم هو كذا معنى كدا ان الحد الاقصى دة  = كل المعادلة اللي ذكرته منها و اللي ما ذكرتوش طب ازاي نعوض اللي ما ذكرناهوش ؟ بنعوضه عن طريق فرض ثابت وجود ثوابت يعني انا لما اقول ان الخوارزم دة بيج او اوف اكس تربيع : معناها ان الوقت اللي بيستهلكه الخوارزم أقل من ثابت في الإكس تربيع .</p>
<p style="text-align:right;">طيب اذا كانت عندي معادلة خورازم هي</p>
<p style="text-align:right;">f(x) = x+2</p>
<p style="text-align:right;">اية هي البج او بتاعته ؟ طبعا بيج او اوف اكس طيب هل تنفع انها تكون بيج او اوف اكس أس عشرة ؟ نظريا ينفع طبعا ما هو لو ضربت ثابت في اكس أس عشرة اكيد هايطلع أكبر من الوقت المطلوب في المعادلة دي لذلك اتطرحت فكرة تانية و هي ان الدوال اللي بتوضح لي الحدود نوعين :-</p>
<p style="text-align:right;">دوال Tight و دوال مش Tight!!</p>
<p style="text-align:right;">الدوال التايت دي يعني مش بعيدة بكتير عن الحل الصح زي ان البج أو للمعادلة الاخيرة دي بإكس إنما الحل اللي مش تاتيت معناه ان انا باوضع حد للزمن اه ،، انما الحد دة بعيد قوي عن الصح ،، زي مثلا لو انت رايح تشتري كتاب الام اي تي بتاع الخوارزميات : لو انت عارف ان الكتاب تمنه من خمسين لسبعين جنية و انت أخدت معاك سبعين جنية كدا تبقى انت واخد معاك البيج أو لسعر الكتاب دة و تبقى تاتيت أما لو أخدت معاك 10000 جنية هاتبقى واخد ليتل أو ( الحد الأقصى برضة بس ببيبقى بعيد ) اذن في مجموع دوال تانية للحدود و ماهياش تايت زي</p>
<p style="text-align:right;">Little-o</p>
<p style="text-align:right;">Little-<strong>ω</strong></p>
<p style="text-align:right;">و هي بالظبط بتقوم بنفس وظيفة البج أو و البيج أوميجا بس مش تايت</p>
<p style="text-align:right;">إية بقا المشاكل اللي ممكن تقابلني لما احب احلل خوارزم؟</p>
<p style="text-align:right;">واضح من الكلام اللي فات ان لو عندي معادلة التايم بتاعت خوارزم هاقدر أجيب الحدود التلاتة بتوعه بسهولة مثلا</p>
<p style="text-align:right;">f(x) = 17x^3+55x^(1/2) +3000 is :-</p>
<p style="text-align:right;">O(x^3) &amp; <strong>Ω</strong>(x^3) &amp; <strong>θ</strong>(x^3)</p>
<p style="text-align:right;">يبقى انا لو وصلت للمعادلة هقدر أجيب الحدود بسهولة ،، المشكلة اللي ممكن تقابلني بقا لما احب احلل خوارزم هي اني ما اقدرش أوصل للمعادلة بتاعته ! طب ازاي ؟ ممكن مثلا تكون المعادلة بتاعته دي بتحتوي على دوال تانية انا ما اعرفهاش ( دوال معادلات تانية ) في الحالة دي هاضطر أعرفها الأول و ممكن تكون الدالة دي recursive</p>
<p style="text-align:right;">و دي بتمثل مشكلة كبيرة زي مثلا</p>
<p style="text-align:right;">f(x) = 2 where x = 1 &amp; f(x) = 3x^2 + f(x/2) where x&gt;1</p>
<p style="text-align:right;">هنا لازم احل المعادلة اللي الريكرسف دي الأول بمعنى إني استبدل استخدامها لنفسها بحدود عادية مثلا حاجة + حاجة عشان أعرف اجيب أكبر أس و بالتالي أجيب دوال الحدود التلاتة أو الخمسة لو محتاجهم</p>
<p style="text-align:right;">حاجات عاوز أوضحها</p>
<p style="text-align:right;">الشرح دة مبني بالأساس على</p>
<ul>
<li>MIT : introduction to algorithms ( chapter 2,3 ) .</li>
<li>First lecture of MIT algorithms course (<a href="http://www.youtube.com/watch?v=JPyuH4qXLZ0"> available here</a>) .</li>
<li>Lecture about asymptotic notations from IIT : design and analysis of algorithms course ( <a href="http://freevideolectures.com/Course/2281/Design-and-Analysis-of-Algorithms/4">available here</a> ) .</li>
</ul>
<p style="text-align:right;">اي تعليقات ، تصحيحات او أسئلة تبقى مشكورة جدا و ان شاء الله المقال يكون مفيد</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/theadhamian.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/theadhamian.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/theadhamian.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/theadhamian.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/theadhamian.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/theadhamian.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/theadhamian.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/theadhamian.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/theadhamian.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/theadhamian.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/theadhamian.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/theadhamian.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/theadhamian.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/theadhamian.wordpress.com/72/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=72&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://theadhamian.wordpress.com/2010/12/15/%d8%a8%d8%a8%d8%b3%d8%a7%d8%b7%d8%a9-%d8%8c%d8%8c-%d8%aa%d8%ad%d9%84%d9%8a%d9%84-%d8%a7%d9%84%d8%ae%d9%88%d8%a7%d8%b1%d8%b2%d9%85%d9%8a%d8%a7%d8%aa/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/67ff47b4b380812af5dad3d89c0e472a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">3m masr</media:title>
		</media:content>
	</item>
		<item>
		<title>OOP questions and its adhamian answers</title>
		<link>http://theadhamian.wordpress.com/2010/08/04/oop-questions-and-its-adhamian-answers/</link>
		<comments>http://theadhamian.wordpress.com/2010/08/04/oop-questions-and-its-adhamian-answers/#comments</comments>
		<pubDate>Wed, 04 Aug 2010 15:46:49 +0000</pubDate>
		<dc:creator>3m masr</dc:creator>
				<category><![CDATA[OOP]]></category>

		<guid isPermaLink="false">http://theadhamian.wordpress.com/?p=68</guid>
		<description><![CDATA[السلام عليكم و رحمة الله و بركاته Alsalamo alikom wa rahmato allahe wa barakato , After finishing my 8th chapter in &#8220;OOP demystified &#8221; book , i wrote some questions and answers to them from my point of view , i listed some of them below :- What is abstract object and real object ? [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=68&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>السلام عليكم و رحمة الله و بركاته</p>
<p>Alsalamo alikom wa rahmato allahe wa barakato ,</p>
<p>After finishing my 8th chapter in &#8220;OOP demystified &#8221; book , i wrote some questions and answers to them from my point of view , i listed some of them below :-</p>
<p><span style="color:#008080;"><strong>What is abstract object and real object ?</strong></span><br />
Abstract object is the object &#8211; the details , like the class is an abstract object but the object itself is a real object , that is because the real object actually holds data , not just say that it exsits &#8230;<br />
<strong><span style="color:#008080;">Why we need to declare the type of our variables ?</span></strong><br />
We need that for two main purposes :-</p>
<ol>
<li>The computer need to know how much space to allocate for that variable ..</li>
<li>The computer uses this piece of information to determine what operations to be performed on that variable , like integer variable can&#8217;t be transformed to uppercase , or string variables can&#8217;t be summed ..</li>
</ol>
<p><strong><span style="color:#008080;">What is the diffrence between instance variable and just variable ?</span></strong><br />
Instance variables are variables of the class , so it is not allocated for untill his object is instantiated , but normal variables are allocated for when the compiler reach them ..<br />
<strong><span style="color:#008080;">What is initialzation and instantiation ?</span></strong><br />
Initialization is the process of setting a variable value , like name = &#8220;Adham&#8221;; , but instantiation is the process of determining the type of the variable so the computer can allocate memory for it , like String name; here you order the computer to allocate memory for a variable called name of type String .<br />
<span style="color:#008080;"><strong>What is Encapsulation ?</strong></span><br />
It is the process of combining the procedure and the attributes in one block called  the object .<br />
<span style="color:#008080;"><strong>Why to use Encapsulation ?</strong></span><br />
We may use it to some organizational reasons ( just groupping related data and behaviours togather ) , but the main purpose of it is Protection , accepting only proper data , for instance this is a PHP function to register a new student in a course :-<br />
<em>function register_student($student_id,$course_id){<br />
// do the registration<br />
}</em></p>
<p><em><br />
</em>Any two parameters are accepted here even if they are not a student&#8217;s data !! , but using Encapsulation , you combine attributes and behaviours into an object so you can prevent non-student objects from registering themselves allowing only student objects &#8230;</p>
<p><strong><span style="color:#008080;">Why we make setters and getters for private or protected properties ?</span></strong><br />
For setters we can use them to validate the new values , for getters we may use them for outputting on a specific manner like :-<br />
class Student {<br />
private status ;<br />
public void setStatus(int status){<br />
this.status = 1;<br />
if(status == 0){<br />
this.status = 0;<br />
}<br />
}</p>
<p>public Stirng  getStatus(){<br />
if(this.status == 0){<br />
return &#8220;Success&#8221;;<br />
}<br />
return &#8220;Fail&#8221;;<br />
}<br />
}</p>
<p><strong><span style="color:#008080;">What is Encapsulation ?</span></strong><br />
It is the process of combining the procedure and the attributes in one block called  the object .<br />
<strong><span style="color:#008080;">What are the types of Inheritance ?</span></strong><br />
Inheritance has three types :-</p>
<ol>
<li>Simple inheritance : class SubClass extends SuperClass ;</li>
<li>Multiple inheritance : not supported in java , but it is simulated usnig interfaces .</li>
<li>Level inheritance : when class a is a b is a c .</li>
</ol>
<p><strong><span style="color:#008080;">What are the differences between function and functionality ?</span></strong><br />
If we have a class represents a dog and another a human , both have common Function which is walking , but they have a different Functionality which is how they do the common function , for instance a human walks on two legs but the dog on four , so Function is something we do but Functionality is how do we do this Function .<br />
<strong><span style="color:#008080;">Can any class implement some not all interface methods ?</span></strong><br />
If a class is abstract it can implemet an interface and don&#8217;t define all of its methods , But if this abstract class was subclassed , the sub class must implement the remaining methods because the subclass in fact implements this interface .<br />
<strong><span style="color:#008080;">What are the common mistakes concerned with abstraction ?</span></strong></p>
<p>There are three common errors concerned with abstraction :-</p>
<ol>
<li>Trying to instantiate an abstract class .</li>
<li>Trying to call an abstract method from the super class .</li>
<li>Forgetting to define an abstract metod in the subclass .</li>
</ol>
<p>ISA i will post here regularly about Java from now on !!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/theadhamian.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/theadhamian.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/theadhamian.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/theadhamian.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/theadhamian.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/theadhamian.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/theadhamian.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/theadhamian.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/theadhamian.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/theadhamian.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/theadhamian.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/theadhamian.wordpress.com/68/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/theadhamian.wordpress.com/68/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/theadhamian.wordpress.com/68/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=68&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://theadhamian.wordpress.com/2010/08/04/oop-questions-and-its-adhamian-answers/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/67ff47b4b380812af5dad3d89c0e472a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">3m masr</media:title>
		</media:content>
	</item>
		<item>
		<title>Area units conversion class using JQuery&#8217;s AJAX .</title>
		<link>http://theadhamian.wordpress.com/2010/01/05/area-units-conversion-class-using-jquerys-ajax/</link>
		<comments>http://theadhamian.wordpress.com/2010/01/05/area-units-conversion-class-using-jquerys-ajax/#comments</comments>
		<pubDate>Tue, 05 Jan 2010 18:09:16 +0000</pubDate>
		<dc:creator>3m masr</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://theadhamian.wordpress.com/?p=62</guid>
		<description><![CDATA[Hi , today we will code our area system conversion in PHP object-oriented . Our project will be consisting of three parts :- The PHP class : for the conversion calculations . An HTML form to send conversion request to the convertArea.php script . The script that implements the class . The PHP class areaConversion.class.php [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=62&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Hi , today we will code our area system conversion in PHP object-oriented .</p>
<p>Our project will be consisting of three parts :-</p>
<ol>
<li>The PHP class : for the conversion calculations .</li>
<li>An HTML form to send conversion request to the convertArea.php script .</li>
<li>The script that implements the class .</li>
</ol>
<p>The PHP class areaConversion.class.php</p>
<pre class="brush: php;">
&lt;?php
/**
 * @author adham
 * @tutorial ‪http://wp.me/pJ1zT-10
 */
class areaConversion {
    private $quantity , $from , $to , $meters ;
    public $result;
    public function __construct($quantity ,$from, $to){
        $this-&gt;from = $from;
        $this-&gt;to = $to;
        $this-&gt;quantity = $quantity;
        $this-&gt;meters = $this-&gt;toMeters($this-&gt;quantity, $this-&gt;from);
        switch($this-&gt;to){
            case 'yard':
                $this-&gt;result = $this-&gt;toYards();
                break;
            case 'hectar' :
                $this-&gt;result = $this-&gt;toHectars();
                break;
            case 'foot' :
                $this-&gt;result = $this-&gt;toFeet();
            break;
            case 'meter':
                $this-&gt;result = $this-&gt;meters;
        }
    }
    // converts anything to meters
    private function toMeters( $quantity, $from){

        switch($from){
            case 'yard' :
                $meters = 0.83612736;
                break;
            case 'foot' :
                $meters = 0.09290304;
                break;
            case 'hectar' :
                $meters = 10000;
                break;
            case 'meter' :
                $meters = 1;
                break;
        }

        $result = $quantity*$meters;
        return $result;

    }

    private function toHectars(){
        $result = $this-&gt;meters * 0.0001;
        return $result;
    }

     private function toYards(){
        $result = $this-&gt;meters * 1.195990;
        return $result;
    }

      private function toFeet(){
        $result = $this-&gt;meters * 10.763911;
        return $result;
    }

}
?&gt;
</pre>
<p>The PHP script convertArea.php</p>
<pre class="brush: php;">
&lt;?php
require 'areaConversion.class.php';
if(strlen($_POST['quantity'])!=0 &amp;&amp; isset($_POST['from']) &amp;&amp; isset($_POST['to'])){
    $converter = new areaConversion($_POST['quantity'], $_POST['from'],$_POST['to']);
    echo round($converter-&gt;result, $_POST['round']);
}else{
    echo &quot;please specify required fields !&quot;;
}
?&gt;
</pre>
<p>The HTML form</p>
<pre class="brush: jscript;">
&lt;script type=&quot;text/javascript&quot; src=&quot;http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js&quot;&gt;&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
    $(document).ready(function(){
    $(&quot;#convForm&quot;).submit(function(){
        $.post('convertArea.php',
        {
            from : $(&quot;#fromSelect&quot;).val(),
            to : $(&quot;#toSelect&quot;).val(),
            quantity : $(&quot;#quantity&quot;).val(),
            round : $(&quot;#roundSelect&quot;).val()
        }

        ,function(data){
            $(&quot;#response&quot;).text(data);
        });
        return false;
    });
  });
&lt;/script&gt;
&lt;div id=&quot;response&quot;&gt;

&lt;/div&gt;
&lt;form id=&quot;convForm&quot;&gt;
    &lt;h4&gt;From :&lt;/h4&gt;
    &lt;select name =&quot;from&quot; id =&quot;fromSelect&quot;&gt;
        &lt;option value =&quot;hectar&quot;&gt;Hectar&lt;/option&gt;
        &lt;option value =&quot;foot&quot;&gt;Foot&lt;/option&gt;
        &lt;option value =&quot;yard&quot;&gt;Yard&lt;/option&gt;
        &lt;option value =&quot;meter&quot;&gt;Meter&lt;/option&gt;
    &lt;/select&gt;
    &lt;h4&gt;To :&lt;/h4&gt;
    &lt;select name =&quot;to&quot; id=&quot;toSelect&quot;&gt;
        &lt;option value =&quot;hectar&quot;&gt;Hectar&lt;/option&gt;
        &lt;option value =&quot;foot&quot;&gt;Foot&lt;/option&gt;
        &lt;option value =&quot;yard&quot;&gt;Yard&lt;/option&gt;
        &lt;option value =&quot;meter&quot;&gt;Meter&lt;/option&gt;
    &lt;/select&gt;
    &lt;h4&gt;Quantity :&lt;/h4&gt;
    &lt;input type=&quot;text&quot; name=&quot;quantity&quot; id=&quot;quantity&quot;/&gt;
    &lt;h4&gt;Round to :&lt;/h4&gt;
    &lt;select name =&quot;round&quot; id=&quot;roundSelect&quot;&gt;
        &lt;option value =&quot;5&quot;&gt;5&lt;/option&gt;
        &lt;option value =&quot;6&quot;&gt;6&lt;/option&gt;
        &lt;option value =&quot;7&quot;&gt;7&lt;/option&gt;
    &lt;/select&gt;
    &lt;input  id =&quot;submit&quot; type=&quot;submit&quot; value=&quot;convert&quot; name=&quot;submit&quot;/&gt;
    &lt;/form&gt;
</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/theadhamian.wordpress.com/62/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/theadhamian.wordpress.com/62/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/theadhamian.wordpress.com/62/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/theadhamian.wordpress.com/62/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/theadhamian.wordpress.com/62/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/theadhamian.wordpress.com/62/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/theadhamian.wordpress.com/62/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/theadhamian.wordpress.com/62/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/theadhamian.wordpress.com/62/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/theadhamian.wordpress.com/62/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/theadhamian.wordpress.com/62/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/theadhamian.wordpress.com/62/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/theadhamian.wordpress.com/62/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/theadhamian.wordpress.com/62/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=62&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://theadhamian.wordpress.com/2010/01/05/area-units-conversion-class-using-jquerys-ajax/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/67ff47b4b380812af5dad3d89c0e472a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">3m masr</media:title>
		</media:content>
	</item>
		<item>
		<title>My uncompleted MetBookmarks project using CI !</title>
		<link>http://theadhamian.wordpress.com/2009/12/24/my-uncompleted-metbookmarks-project-using-ci/</link>
		<comments>http://theadhamian.wordpress.com/2009/12/24/my-uncompleted-metbookmarks-project-using-ci/#comments</comments>
		<pubDate>Thu, 24 Dec 2009 17:09:16 +0000</pubDate>
		<dc:creator>3m masr</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://theadhamian.wordpress.com/?p=58</guid>
		<description><![CDATA[hi everyone, i am facing some problems concerned with how work flows , which step after which in my first codeigniter project .. it aims to be something like digg.com but smaller and just for getting my feet wet not for any commercial goals ! I used Jquery and the form validation class for making [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=58&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>hi everyone, i am facing some problems concerned with how work flows , which step after which in my first codeigniter project .. it aims to be something like digg.com but smaller and just for getting my feet wet not for any commercial goals !</p>
<p>I used Jquery and the form validation class for making validation for the reregistration and logging in system , this is a screen shot .</p>
<p style="text-align:center;">
<p style="text-align:center;"><a style="text-decoration:none;" href="http://theadhamian.files.wordpress.com/2009/12/adham.gif"><img class="aligncenter size-medium wp-image-59" title="adham" src="http://theadhamian.files.wordpress.com/2009/12/adham.gif?w=300&#038;h=168" alt="" width="300" height="168" /></a></p>
<p style="text-align:left;">Now anyone wanna read what i wrote , just <a href="http://usershare.net/fd7syjb41prj" target="_blank">download </a>!</p>
<p style="text-align:left;">i am trying to complete it .. ISA</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/theadhamian.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/theadhamian.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/theadhamian.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/theadhamian.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/theadhamian.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/theadhamian.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/theadhamian.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/theadhamian.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/theadhamian.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/theadhamian.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/theadhamian.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/theadhamian.wordpress.com/58/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/theadhamian.wordpress.com/58/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/theadhamian.wordpress.com/58/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=58&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://theadhamian.wordpress.com/2009/12/24/my-uncompleted-metbookmarks-project-using-ci/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/67ff47b4b380812af5dad3d89c0e472a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">3m masr</media:title>
		</media:content>

		<media:content url="http://theadhamian.files.wordpress.com/2009/12/adham.gif" medium="image">
			<media:title type="html">adham</media:title>
		</media:content>
	</item>
		<item>
		<title>Jacobi&#8217;s and Gauss&#8217;s Methods for solving a system of equations using PHP.</title>
		<link>http://theadhamian.wordpress.com/2009/12/06/jacobi-s-and-gauss-s-methods-for-solving-a-system-of-equations/</link>
		<comments>http://theadhamian.wordpress.com/2009/12/06/jacobi-s-and-gauss-s-methods-for-solving-a-system-of-equations/#comments</comments>
		<pubDate>Sun, 06 Dec 2009 12:21:32 +0000</pubDate>
		<dc:creator>3m masr</dc:creator>
				<category><![CDATA[Math]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://theadhamian.wordpress.com/?p=51</guid>
		<description><![CDATA[It&#8217;s my first post about what i study in  my college , it is about solving a system of equations using the two famous numerical methods of Jacobi and Gauss . This post is not about these numerical methods themselves but it is about their PHP implementation . This is the code for Jacobi : [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=51&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s my first post about what i study in  my college , it is about solving a system of equations using the two famous numerical methods of Jacobi and Gauss .</p>
<p>This post is not about these numerical methods themselves but it is about their PHP implementation .</p>
<p>This is the code for Jacobi :</p>
<pre class="brush: php;">
&lt;?php
	$x = array(
		array(0,-(1/3),-(1/3),-(8/3)),
		array((1/3),0,-(1/3),(8/3)),
		array(-(1/3),(1/3),0,-(8/3))
	);
	$s = array(
		0,0,0
	);
	echo &quot;&lt;table border='1' style= 'width :90%'&gt;&lt;tr&gt;&quot;;
	echo &quot;&lt;td&gt; k = 0&lt;/td&gt;&lt;td&gt; 0&lt;/td&gt;&lt;td&gt; 0&lt;/td&gt;&lt;td&gt; 0&lt;/td&gt;&lt;/tr&gt;&quot;;
	for($i=1;$i&lt;=30;$i++){
		echo &quot;&lt;tr&gt;&quot;;
		$s0 = ( $s[0]*$x[0][0]) + ( $s[1]*$x[0][1])+($s[2]*$x[0][2]+$x[0][3]);
		$s1 = ($s[0]*$x[1][0]) + ($s[1]*$x[1][1]) + ($s[2]*$x[1][2]+$x[1][3]);
		$s2 = ( $s[0]*$x[2][0]) + ($s[1]*$x[2][1]) + ($s[2]*$x[2][2]+$x[2][3]);
		$s[0] = $s0;
		$s[1] = $s1;
		$s[2] = $s2;
		echo &quot;&lt;td&gt; k = $i&lt;/td&gt;&lt;td&gt;&quot;.$s[0].&quot;&lt;/td&gt;&lt;td&gt;&quot;.$s[1].&quot;&lt;/td&gt;&lt;td&gt;&quot;.$s[2].&quot;&lt;/td&gt;&lt;/tr&gt;&quot;;
		//echo $i.&quot; :: &quot;.$s[0].&quot; :: &quot;.$s[1].&quot; :: &quot;.$s[2].&quot;&lt;br&gt;&quot;;
	}
	echo &quot;&lt;/table&gt;&quot;;
?&gt;
</pre>
<p>And this is the gauss-siedle</p>
<pre class="brush: php;">
	$x = array(
		array(0,0.2,-0.6,-0.4),
		array(-0.2,0,0.4,2),
		array(-0.2,0.4,0,0.6)
	);
	$s = array(
		0,0,0
	);
echo &quot;0 :: 0 :: 0 :: 0&lt;br&gt;&quot;;
	for($i=1;$i&lt;100;$i++){

		$s[0] =  $s[0]*$x[0][0] + $s[1]*$x[0][1] + $s[2]*$x[0][2]+$x[0][3];
		$s[1] = $s[0]*$x[1][0] + $s[1]*$x[1][1] + $s[2]*$x[1][2]+$x[1][3];
		$s[2] = $s[0]*$x[2][0] + $s[1]*$x[2][1] + $s[2]*$x[2][2]+$x[2][3];

		echo $i.&quot; :: &quot;.$s[0].&quot; :: &quot;.$s[1].&quot; :: &quot;.$s[2].&quot;&lt;br&gt;&quot;;
	}
?&gt;
</pre>
<h2>How to use it ?</h2>
<pre>just put the X coefficients into the $x array after putting it in the valid form !
<h2>If you have a problem with approximation accuracy use the <a href="http://www.php.net/manual/en/function.round.php">round()</a> function</h2>
</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/theadhamian.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/theadhamian.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/theadhamian.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/theadhamian.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/theadhamian.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/theadhamian.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/theadhamian.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/theadhamian.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/theadhamian.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/theadhamian.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/theadhamian.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/theadhamian.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/theadhamian.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/theadhamian.wordpress.com/51/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=51&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://theadhamian.wordpress.com/2009/12/06/jacobi-s-and-gauss-s-methods-for-solving-a-system-of-equations/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/67ff47b4b380812af5dad3d89c0e472a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">3m masr</media:title>
		</media:content>
	</item>
		<item>
		<title>JQuery validation &#8211; part 2 : using JQuery validation plugin .</title>
		<link>http://theadhamian.wordpress.com/2009/12/01/jquery-validation-part-2-using-jquery-validation-plugin/</link>
		<comments>http://theadhamian.wordpress.com/2009/12/01/jquery-validation-part-2-using-jquery-validation-plugin/#comments</comments>
		<pubDate>Tue, 01 Dec 2009 21:51:59 +0000</pubDate>
		<dc:creator>3m masr</dc:creator>
				<category><![CDATA[Jquery]]></category>

		<guid isPermaLink="false">http://theadhamian.wordpress.com/?p=29</guid>
		<description><![CDATA[Hi everyone , it&#8217;s my second tutorial about JQuery validation .. today we are gonna use the validation plugin ISA , we will cover more than one level dealing with this plugin as follows :- Validation using validate() method with no arguments . Validation using rules &#38; messages for custom error message . Some links [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=29&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Hi everyone ,</p>
<p>it&#8217;s my second tutorial about JQuery validation .. today we are gonna use the validation plugin ISA , we will cover more than one level dealing with this plugin as follows :-</p>
<ul>
<li>Validation using <em>validate() </em>method with no arguments .</li>
<li>Validation using <em>rules </em>&amp; <em>messages </em>for custom error message .</li>
<li>Some links !</li>
</ul>
<h4><span style="color:#808080;">1st level : Validation using </span><em><span style="color:#808080;">validate() </span></em><span style="color:#808080;">method with no arguments :-</span></h4>
<pre class="brush: jscript;">
&lt;html&gt;
&lt;head&gt;
&lt;script type = &quot;text/javascript&quot; src = &quot;http://code.jquery.com/jquery-latest.js&quot; &gt;&lt;/script&gt;
&lt;script type = &quot;text/javascript&quot; src = &quot;http://dev.jquery.com/view/trunk/plugins/validate/jquery.validate.js&quot; &gt;&lt;/script&gt;
&lt;script type = &quot;text/javascript&quot; &gt;
$(document).ready(function(){
$(&quot;#myForm&quot;).validate();
});
&lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;form id = &quot;myForm&quot; &gt;
&lt;p &gt; Username * : &lt;/p&gt;
&lt;input type=&quot;text&quot; id = &quot;username&quot; class = &quot;required&quot;/&gt;
&lt;p &gt; Email  : &lt;/p&gt;
&lt;input type=&quot;text&quot; id = &quot;email&quot; class = &quot;optional&quot;/&gt;
&lt;p&gt; Password * : &lt;/p&gt;
&lt;input type=&quot;text&quot; id = &quot;password&quot; class = &quot;required&quot;/&gt;
&lt;input type = &quot;submit&quot; value = &quot;Register&quot; class = &quot;submit&quot; /&gt;
&lt;/form&gt;
&lt;/body&gt;
&lt;/html&gt;
</pre>
<h4>=&gt; Here what did we do ?</h4>
<ul>
<li>As <strong>JQuery</strong> <strong>code : </strong>we ordered javascript to operate the <em>validate() </em>method on the form whose <em>id = &#8220;myForm&#8221; </em>when the <em>DOM </em>is ready .</li>
<li>As <strong>HTML code : </strong>we simply define the form inputs  and setting the class attribute to <em>&#8221; required &#8221; </em> for the required inputs and <em>&#8221; optional &#8221; </em>for the optional input ( here i assume that the username and password fields are required , but the email field is optional ) , don&#8217;t forget to set the <em>class </em>attribute for the submit button .</li>
</ul>
<p>If you execute this code you may have a result like this :-</p>
<p style="text-align:center;">
<p style="text-align:center;">
<p style="text-align:center;"><a href="http://theadhamian.files.wordpress.com/2009/12/jquery-validation-2-1.png"><img class="size-medium wp-image-38 aligncenter" title="jquery-validation-2-1" src="http://theadhamian.files.wordpress.com/2009/12/jquery-validation-2-1-e1259705611949.png?w=300&#038;h=225" alt="" width="300" height="225" /></a></p>
<p style="text-align:center;"><span id="more-29"></span></p>
<p style="text-align:left;">You can then customize the <em>error </em>css class that is applied to the message which appears above <em>&#8221; this field is required &#8221; </em>.</p>
<p style="text-align:left;">so add this css to your document&#8217;s head</p>
<p style="text-align:left;">
<pre class="brush: css;">
&lt;style&gt;
.error{
color : red ;
padding-left : 3px;
}
&lt;/style&gt;
</pre>
<p style="text-align:left;">
<p style="text-align:left;">We then add another attribute to the &lt;<em>input &gt; </em>tag to specify the minimum length for this field , this attribute is called <em>minlength </em>so update your <em>&lt;input&gt;</em>s like this :-</p>
<pre class="brush: xml;">
&lt;input type=&quot;text&quot; id = &quot;username&quot; class=&quot;required&quot; minlength = &quot;5&quot;/&gt;
</pre>
<p style="text-align:left;">If you tried to enter a username with length less than 5 chars you will get an error message css-classed with the <em>error </em>css class .</p>
<blockquote>
<p style="text-align:left;">Till now no i think that is no problem at all .. every thing goes well .. we make our form &gt; define out inputs or any field types , all what matters is the <em>class </em>attribute &gt; write two JQuery lines and it&#8217;s done ! now we&#8217;ll go deeper and pass somethings to the <em>validate() </em>method .</p>
</blockquote>
<h4>2nd level : Validation using <em>rules </em>&amp; <em>messages </em>for custom error messages .</h4>
<p>As you may note , jquery&#8217;s validation plugin has its own error messages for leaving a required field or any other error , also it is difficult to some extent to set HTML attributes for every option you wanna apply , so we will try the second level by passing some arguments to the <em>validate() </em>method.</p>
<ul>
<li><strong>HTML code</strong> :</li>
</ul>
<pre class="brush: xml;">
&lt;p class = &quot;fieldLabel&gt; Username * : &lt;/p&gt;
&lt;input type=&quot;text&quot; id = &quot;username&quot; name = &quot;username&quot;/&gt;
&lt;p class = &quot;fieldLabel&quot; &gt;Enter your email &lt;/p&gt;
&lt;input type = &quot;text &quot; name = &quot;email1&quot; id = &quot;email1&quot; /&gt;
&lt;p class = &quot;fieldLabel&quot; &gt;Re-enter your email &lt;/p&gt;
&lt;input type = &quot;text &quot; name = &quot;email2&quot; id = &quot;email2&quot; /&gt;
&lt;p class = &quot;fieldLabel&quot; &gt;Enter your comment * : &lt;/p&gt;
&lt;textarea name = &quot;comment&quot; id = &quot;comment&quot;&gt;&lt;/textarea&gt;
</pre>
<ul>
<li><strong>JQuery code</strong> :</li>
</ul>
<pre class="brush: jscript;">
$(document).ready(function(){
$(&quot;#myForm&quot;).validate({
   // specify some rules
   rules :{
      username : {
         required : true,      // username is a required field
         minlength : 3         // its minimum length is 3 chars
      },
      email1 : {
         required : true,
         email : true          // this field must has an email format
      },
      email2 :{
         required : true,
         email : true,
         equalTo : '#email1'   // this field must be equal to the element with id #email1
       },
       comment : {
         required : true,
         minlength : 20
       }
   },
   // messages that will appear if the previous rules were not true
   messages : {
      username : {
         required: ' Please enter a username ',  // if this field was left blank this message will appear
         minlength: ' you have to enter 3 charecters at least ! '
      },
      email1 : {
         required : 'this field is required',
         email : 'Not valid email format'
      },
      email2 : {
         required : 'this field is required',
         email : 'Not valid email format',
         equalTo : 'The two email fields must be identical'
      },
      comment : {
         required : 'sorry .. please enter your comment !',
         minlength : &quot;this field's length must be 20 at least&quot;
      }
   },
   errorClass : 'error',    // what css class will be applied to the errors ?
   // if all fields are valid just execute this function
   // this argument label refers to the error label element and is a label object
   // this is identical to label = getElementById(&quot;#someLabel&quot;);
   success : function(label){
                   label.addClass(&quot;valid&quot;).html(&quot;&lt;b&gt;this is a valid input !&lt;/b&gt;&quot;);
   }
});
</pre>
<p><em>Note : we can manipulate out &#8220;valid &#8221; css class and make it contain an image like <a href="http://dev.jquery.com/view/trunk/plugins/validate/demo/images/checked.gif" target="_blank">this</a> , look  the JQuery&#8217;s css example about this :</em></p>
<pre class="brush: css;">
.valid {
	background: url('http://dev.jquery.com/view/trunk/plugins/validate/demo/images/checked.gif') no-repeat;
	height:16px;
	width:16px;
	display: block;
	position: absolute;
	top: 4px;
	left: 152px;
}
</pre>
<h4>3rd level : Some links !</h4>
<p>About some tricks you may have to read the <a href="http://docs.jquery.com/Plugins/Validation" target="_blank">manual</a> yourself .. really useful .</p>
<p>The second link of course is here .. just follow me on <a href="http://twitter.com/3m_masr" target="_self">twitter</a> and you will be noticed if any validation or any other tutorial was added !</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/theadhamian.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/theadhamian.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/theadhamian.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/theadhamian.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/theadhamian.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/theadhamian.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/theadhamian.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/theadhamian.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/theadhamian.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/theadhamian.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/theadhamian.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/theadhamian.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/theadhamian.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/theadhamian.wordpress.com/29/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=29&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://theadhamian.wordpress.com/2009/12/01/jquery-validation-part-2-using-jquery-validation-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/67ff47b4b380812af5dad3d89c0e472a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">3m masr</media:title>
		</media:content>

		<media:content url="http://theadhamian.files.wordpress.com/2009/12/jquery-validation-2-1-e1259705611949.png?w=300" medium="image">
			<media:title type="html">jquery-validation-2-1</media:title>
		</media:content>
	</item>
		<item>
		<title>JQuery validation &#8211; part 1 .</title>
		<link>http://theadhamian.wordpress.com/2009/11/30/jquery-validation-part-1/</link>
		<comments>http://theadhamian.wordpress.com/2009/11/30/jquery-validation-part-1/#comments</comments>
		<pubDate>Mon, 30 Nov 2009 11:36:16 +0000</pubDate>
		<dc:creator>3m masr</dc:creator>
				<category><![CDATA[Jquery]]></category>

		<guid isPermaLink="false">http://theadhamian.wordpress.com/?p=4</guid>
		<description><![CDATA[Hi everyone , i intend to start a series of tutorials about JQuery validation covering some important topics like integrating php and its Cdoeigniter , using JQuery validation plugins and Doctrine . Note that : these tutorials represent my own trials !! Our tutorial consists of two 3 parts as follows :- HTML code : that [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=4&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Hi everyone , i intend to start a series of tutorials about JQuery validation covering some important topics like integrating <strong>php </strong>and its <strong>Cdoeigniter</strong> , using <strong>JQuery validation plugins</strong> and <strong>Doctrine </strong>.</p>
<p><em><span style="text-decoration:underline;">Note that</span></em> <em>: </em><em>these tutorials represent my own trials !! </em></p>
<p>Our tutorial consists of two 3 parts as follows :-</p>
<ul>
<li><strong>HTML code</strong> : that contains the form and its input and submit and &#8230; fields<em> </em>.</li>
<li><strong>PHP script</strong> : that validates some $_POST information (typed in the form) and either show errors or just type a message saying &#8220;<em>thanks for registering</em>&#8220;.</li>
<li><strong>JQuery code</strong> : that is responsible for two jobs (posting data from the form to the php script and getting the result back to the HTML page again).</li>
</ul>
<p>We start by writing a simple HTML page that contains a form for registering a new user that consists of :-</p>
<ol>
<li>Input field of type text for the user name .</li>
<li>Two input fields of type text for the email and the re-email .</li>
<li>Two input fields of type password for the password and re-password .</li>
</ol>
<p><em>That will be something like this :-</em></p>
<pre class="brush: xml; wrap-lines: false;">
&lt;form id=&quot;sendForm&quot; style = &quot;margin-bottom : 0px&quot;&gt;
&lt;label for=&quot;username&quot;&gt;Username : &lt;/label&gt;
&lt;input type=&quot;text&quot; id=&quot;username&quot;/&gt;
&lt;br&gt;
&lt;label for = &quot;email1&quot;&gt;Your email :&lt;/label&gt;
&lt;input type = &quot;text&quot; id = &quot;email1&quot; /&gt;
&lt;br&gt;
&lt;label for = &quot;email2&quot;&gt;re-enter your email :&lt;/label&gt;
&lt;input type = &quot;text&quot; id = &quot;email1&quot; /&gt;
&lt;br&gt;
&lt;label for = &quot;password1&quot;&gt;Your password :&lt;/label&gt;
&lt;input type = &quot;text&quot; id = &quot;password1&quot; /&gt;
&lt;br&gt;
&lt;label for = &quot;password2&quot;&gt;re-enter your password :&lt;/label&gt;
&lt;input type = &quot;text&quot; id = &quot;password2&quot; /&gt;
&lt;br&gt;
&lt;a id=&quot;mysubmit&quot; href=&quot;#&quot;&gt; Register&lt;/a&gt;
</pre>
<div><span style="font-weight:normal;">and i used this site to get a rounded-corners div that contained my form :
<p>&nbsp;</p>
<h4><a href="http://www.spiffycorners.com/index.php?sc=spiffy&amp;bg=806F6F&amp;fg=C9ABAB&amp;sz=5px">http://www.spiffycorners.com/index.php?sc=spiffy&amp;bg=806F6F&amp;fg=C9ABAB&amp;sz=5px</a></h4>
<h4><span style="font-weight:normal;"> =&gt; My PHP script that will validate data that will be $_POST<em>ed </em>from the previous HTML form will look like this :-</span></h4>
<pre class="brush: php; wrap-lines: false;">
&lt;?php
// this file is named &quot;rules.php&quot;
$username = $_POST['username'];
$password1 = $_POST['password1'];
$password2 = $_POST['password2'];
$email1 = $_POST['email1'];
$email2 = $_POST['email2'];
function isValidEmailAddress($email){
  return preg_match('/^[^0-9][a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)*[@][a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)*[.][a-zA-Z]{2,4}$/',$email);
	}
$errors=&quot;&lt;ul&gt;&quot;;
$flag = false;
// if it is empty
if(strlen($username)){
// if it is not empty check length
       if(strlen($username)&gt;50){
       $flag = true;
       $errors .= &quot;&lt;li&gt;username must be more than 10 chars and lower than 50&lt;/li&gt;&quot;;
	}
       if(strlen($username)&lt;10){
  $flag = true;
  $errors .= &quot;&lt;li&gt;username must be more than 10 chars and lower than 50&lt;/li&gt;&quot;;
	}
      }else{
	$flag = true;
	$errors.=&quot;&lt;li&gt;Please fill the username field&lt;/li&gt;&quot;;
	}
// if password is empty
if(strlen($password1)==0 || strlen($password2)==0){
   $flag = true;
   $errors.=&quot;&lt;li&gt;each password field must not left empty&lt;/li&gt;&quot;;
    }else{
         // if they are not left
         if(!($password1=== $password2)){
            $flag = true;
            $errors.=&quot;&lt;li&gt;Both password fields must be identical&lt;/li&gt;&quot;;
            }
         if(strlen($password1)&gt;50){
            $flag = true;
            $errors.=&quot;&lt;li&gt;password's field length must be less than 50 chars&lt;/li&gt;&quot;;
             }
        }
// checking the email
if(strlen($email1) == 0 | strlen($email2) == 0){
    $flag = true;
    $errors.=&quot;&lt;li&gt;email's field length must be between 1 and 49 chars&lt;/li&gt;&quot;;
}else{
    if(!$email1 === $email2){
    $flag = true;
    $errors.=&quot;&lt;li&gt;Both email fields must be identical&lt;/li&gt;&quot;;
      }
    if(strlen($email1)&lt;10){
       $errors .= &quot;email's field length must be more than 10 chars&quot;;
       }
    if(strlen($email1)&gt;50){
       $errors.= &quot;email's field length must be less than 50 chars&quot;;
       }
    if(!isValidEmailAddress($email1)){
       $flag = true;
       $errors .=&quot;&lt;li&gt;Invalid email address&lt;/li&gt;&quot;;
       }
     }
  $errors .=&quot;&lt;/ul&gt;&quot;;

if ($flag){
   print($errors);
}else{
   print &quot;thanks for registering !&quot;;
     }

?&gt;
</pre>
<h2><span style="font-weight:normal;"><span style="color:#808080;">In the previous code what did i do ?</span></span></h2>
<div>
<ul>
<li><span style="color:#808080;">Assigning the $_POST&#8217;s elements to variables like </span><em><span style="color:#808080;">$username = $_POST['username'];</span></em></li>
<li><span style="color:#808080;">Defining a function that compares its input email address against a </span><em><span style="color:#808080;">regex </span></em><span style="color:#808080;">patterns and returns a boolean value .</span></li>
<li><span style="color:#808080;">Defining a variable that will hold errors ( if any ) </span><em><span style="color:#808080;">$errors</span></em><span style="color:#808080;"> which will be an unordered list </span><em><span style="color:#808080;">&lt;ul&gt;</span></em><span style="color:#808080;"> containing errors as </span><em><span style="color:#808080;">&lt;li&gt;</span></em><span style="color:#808080;">&#8216;s .</span></li>
<li><span style="color:#808080;">Checking the </span><em><span style="color:#808080;">$username</span></em><span style="color:#808080;"> if its length is more than </span><em><span style="color:#808080;">zero </span></em><span style="color:#808080;">then we check its length to be between 10 and 50 charecters .</span></li>
<li><span style="color:#808080;">If not we just add an </span><em><span style="color:#808080;">&lt;li&gt; </span></em><span style="color:#808080;">to the </span><em><span style="color:#808080;">$errors </span></em><span style="color:#808080;">variable containing a message .</span></li>
<li><span style="color:#808080;">The rest is similar and logical !</span></li>
<li><span style="color:#808080;">Finally we check if the </span><em><span style="color:#808080;">$flag </span></em><span style="color:#808080;">boolean variable was </span><em><span style="color:#808080;">true </span></em><span style="color:#808080;">then we print the errors if not we print a &#8220;</span><em><span style="color:#808080;">thank you</span></em><span style="color:#808080;">&#8221; message .</span></li>
<li><span style="color:#808080;">Instead of printing a &#8220;</span><em><span style="color:#808080;">thank you message</span></em><span style="color:#808080;">&#8221; we can post these valid information to a database !!</span></li>
</ul>
</div>
<p>=&gt; And finally the JQuery code that will transfer data from the form to the PHP script using $_POST</p>
<pre style="font:normal normal normal 12px/18px Consolas, Monaco, 'Courier New', Courier, monospace;">and get the result back from the script to the HTML page that contains the form .</pre>
<h4>
<pre class="brush: jscript; wrap-lines: false;">
$(&quot;document&quot;).ready(function(){
  $(&quot;#mysubmit&quot;).click(function(){
    $.post(&quot;rules.php&quot;,
                 {
                   username : $(&quot;#username&quot;).val(),
                   password1 : $(&quot;#password1&quot;).val(),
                   password2 : $(&quot;#password2&quot;).val(),
                   email1 : $(&quot;#email1&quot;).val(),
                   email2 : $(&quot;#email2&quot;).val()
                 },
                 function(data){
                           $(&quot;#errors&quot;).html(data).show(&quot;slow&quot;);
                   }
                            );
    });
});
</pre>
<h2><span style="color:#888888;">In the previous code what did i do ?</span></h2>
<div>
<ul>
<li><span style="font-weight:normal;"><span style="color:#888888;">In the first line we tell javascript to execute a function when the document is ready .</span></span></li>
<li><span style="font-weight:normal;"><span style="color:#888888;">That function will execute another one if and only if the element of </span></span><em><span style="font-weight:normal;"><span style="color:#888888;">id = &#8220;mysubmit&#8221;</span></span></em><span style="font-weight:normal;"><span style="color:#888888;"> was clicked .</span></span></li>
<li><span style="font-weight:normal;"><span style="color:#888888;">If it was clicked then we&#8217;ll send some data to the &#8220;</span></span><em><span style="font-weight:normal;"><span style="color:#888888;">rules.php</span></span></em><span style="font-weight:normal;"><span style="color:#888888;">&#8221; via </span></span><em><span style="font-weight:normal;"><span style="color:#888888;">POST </span></span></em><span style="font-weight:normal;"><span style="color:#888888;">method .</span></span></li>
<li><span style="font-weight:normal;"><span style="color:#888888;">We then retrieve this file and load it inside the element with </span></span><em><span style="font-weight:normal;"><span style="color:#888888;">id=&#8221;errors&#8221; .</span></span></em></li>
</ul>
</div>
<p>So $.post works as follows :-</p>
<ul>
<li>Its first argument is the server-side script , the second is a map of what will be sent to the script and a callback .</li>
<li>This callback function will be executed when the operation is completed and takes one argument which will be considered to be the data retrieved from the script .</li>
</ul>
</h4>
<p><em>Note : while coding this script you should output the result , so loading it into a div using any ajax method will mean something !</em></p>
<p><em><br />
</em></p>
<p>&nbsp;</p>
<p></span></div>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/theadhamian.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/theadhamian.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/theadhamian.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/theadhamian.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/theadhamian.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/theadhamian.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/theadhamian.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/theadhamian.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/theadhamian.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/theadhamian.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/theadhamian.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/theadhamian.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/theadhamian.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/theadhamian.wordpress.com/4/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=theadhamian.wordpress.com&amp;blog=10730829&amp;post=4&amp;subd=theadhamian&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://theadhamian.wordpress.com/2009/11/30/jquery-validation-part-1/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/67ff47b4b380812af5dad3d89c0e472a?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">3m masr</media:title>
		</media:content>
	</item>
	</channel>
</rss>
