<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress.com" -->
<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/"
	>

<channel>
	<title>validate &amp;laquo; WordPress.com Tag Feed</title>
	<link>http://wordpress.com/tag/validate/</link>
	<description>Feed of posts on WordPress.com tagged "validate"</description>
	<pubDate>Thu, 21 Aug 2008 07:27:11 +0000</pubDate>

	<generator>http://wordpress.com/tags/</generator>
	<language>en</language>

<item>
<title><![CDATA[Three Free Web Widgets]]></title>
<link>http://brokenremote.wordpress.com/?p=70</link>
<pubDate>Mon, 18 Aug 2008 11:57:24 +0000</pubDate>
<dc:creator>brokenremote</dc:creator>
<guid>http://brokenremote.wordpress.com/?p=70</guid>
<description><![CDATA[In my current web development spree, I&#8217;ve discovered a nice heap of useful web widgets that ar]]></description>
<content:encoded><![CDATA[<p>In my current web development spree, I've discovered a nice heap of useful web widgets that are free, easy to install, and easy to use.</p>
<p>The first is simple, a popup calendar: <strong><a href="http://www.javascriptkit.com/script/script2/dyndateselector.shtml" target="_blank">Dynamic Date Selector</a></strong></p>
<p>This popup calendar works by using a hidden HTML table on your page. When you click in the box, the calendar is set to visible and moved around where you clicked. I chose this widget because it's easy to use and modify. All of the styles are in their own stylesheet, not embedded deep within the code, which makes customizing it very easy. I was also able to modify the code very easily to include a drop-down menu for the year and have a calendar icon to the right of the text box that I can click to open the calendar. Very useful little widget.</p>
<p><img src="http://brokenremote.wordpress.com/files/2008/08/4stars.gif"> 4 Stars for ease of use but potential div/table arguments.</p>
<p>Second, a JavaScript validator: <strong><a href="http://www.jsvalidate.com/" target="_blank">JSValidate</a></strong></p>
<p>This JavaScript tool is early in it's development. It's hard to say if there's much of a future for this project...we'll have to get to a version 1 before that's determined. Regardless, this script requires you to add a class attribute to your input fields...that's it. Give the class a name like "jsrequired" or "jsvalidate-number" to enable the validation. All the validation is done using regular expressions, and it's super-easy to add your own. It's a little tough to do two validations on one field (like required and number), but you can add two classes and it works. The only problem is that you get both error messages if either of the errors occur. The only other downside is that you have to add the "name" attribute to your form, which doesn't validate on XHTML strict, but that's reported to be fixed in another version. Overall, very nice and some beautiful effects. I hope to see this developed further.</p>
<p><img src="http://brokenremote.wordpress.com/files/2008/08/3stars.gif"> 3 Stars because it is an early version and does not fully validate.</p>
<p>Finally, the best of them all: <strong><a href="http://www.orangoo.com/labs/GreyBox/" target="_blank">GreyBox</a></strong></p>
<p>GreyBox is a self titled "Pop-up window that doesn't suck". And that's right...it doesn't! This AJAX tool (AJAX is just JavaScript and other technologies mixed) rocks. You just click a link and it opens up in an in-browser window. It's not a real popup, just divs and tables mixed with some nice AJAX effects. The best way to see this is to just try it for yourself at the website linked above. Again, this is easy to install and use and looks great. I use it for input forms on my website.</p>
<p><img src="http://brokenremote.wordpress.com/files/2008/08/5stars.gif"> 5 Stars because it simply rocks.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Sincerity and Dedication work well in interpersonal communications]]></title>
<link>http://patricktay.wordpress.com/?p=517</link>
<pubDate>Sat, 09 Aug 2008 07:03:37 +0000</pubDate>
<dc:creator>patricktay</dc:creator>
<guid>http://patricktay.wordpress.com/?p=517</guid>
<description><![CDATA[No communicators are excellent in every way when it comes to interpersonal communications. All of us]]></description>
<content:encoded><![CDATA[<p>No communicators are excellent in every way when it comes to interpersonal communications. All of us have our flaws and areas for improvement. This is something that we should be aware of. In the absence of this self-awareness, we will be denying ourselves the opportunity to be excellent communicators. One catch about self-reflection when it comes to the ways to improve ourselves is this: it's usually the case that we are unaware of the aspects of our communication process that we should improve on. I call this our "communication blind spots". Thus, we need feedback from others, not to validate us but to enable us to further improve ourselves.</p>
<p>However, we will require opportunities (since not everyone are suitable candidates to provide feedback to us. Think courtesy bias) and time to further improve ourselves. Does this mean that there's nothing much we can do in the meantime? Actually, no. There are two qualities that we can work on immediately. This is because developing these two qualities does not require substantial amount of time and effort. It just requires a change in mindset. So, what are these two qualities? It's <strong>sincerity</strong> and <strong>dedication</strong>.</p>
<p>All of us can be sincere towards our interactions with people and situation. We should refrain from merely showing sincerity. In fact, showing sincerity is simple. Fulfilling a promise, meeting a friend on time, helping someone in need are all examples of how we can express sincerity. However, there are some of us who stop here. This is insufficient.  When it comes to sincerity, we should live it. This brings us to the concept of <em>intention</em>. One can show sincerity in every aspects of one's communication but if one' intention is ultimately to deceive or to manipulate, then one is not sincere. In another words, we need to ask ourselves about what we wish to achieve with our intentions. If it's altruistic in nature or for the greater good, then it's great. If not, we need to question our intentions more closely, lest our sincerity become suspect.</p>
<p>Being sincere and expressing sincerity will enhance our interpersonal communication almost immediately. I am not saying this to satisfy one's need for instant gratification of positive results but rather, I am saying this as a fact. When we are sincere both in our mind, heart and speech, others are able to sense our sincerity and this is always a good start to an excellent communication process.</p>
<p>However, sincerity alone is insufficient. Another factor is required: dedication. Dedication is inseparable from <em>consistency</em>. When we look at someone who is dedicated in his work, they are usually very consistently in their work, working on their project continually till their tasks are completed.   So, how do we express dedication in our communications with others? We achieve this through a consistent display of sincerity with no signs of our goodwill abating anytime soon. Thus, it is through the coupling of sincerity and dedication that one achieves success in interpersonal communication.</p>
<p>Now, let's look at how these two concepts work together in the classroom and the workplace.</p>
<p>In the classroom, if educators are sincere and dedicated in the coaching of their students, students are usually attuned to<strong> </strong>their teachings. When the students are aware that their educators are sincere in their approach and dedicated in their guidance, the students will reciprocate with their gesture of goodwill as well. Many educators use discipline to maintain order in the classroom. While this is a feasible approach, winning the hearts of students is equally or even more important. And to win the heart of students, sincerity and dedication is important.</p>
<p>In the workplace, employers are able to display sincerity by treating each of their employees in an unbiased manner and reducing office politics (which usually undermine the credibility of sincerity in the workplace seriously). Employers should also display dedication through their personal display of dedication in their work, putting in their best effort in all of their endeavours.</p>
<p>The importance of sincerity and dedication goes way beyond one's ability to improve interpersonal communications. When others sense the existence of sincerity and dedication in our approach, I realise that they tend to ignore the areas that we might be not be very proficient in when we communicate with them.  It seems to be human nature that we are often vulnerable to a sincere display of sincerity and dedication.</p>
<p>This is probably why Beauty fell in love with the Beast eventually. Although the Beast's expression of sincerity and dedication is somewhat situational (he is a prince transformed into a beast by a witch of which only finding true love will allow him to recover his original form), it's undoubtedly a fact that it's sincerity and dedication that ultimately won the heart of Beauty.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[The PHP Authorization Class]]></title>
<link>http://vailo.wordpress.com/?p=148</link>
<pubDate>Fri, 01 Aug 2008 07:05:58 +0000</pubDate>
<dc:creator>vailo</dc:creator>
<guid>http://vailo.wordpress.com/?p=148</guid>
<description><![CDATA[When you decide to work with PHP and MySQL you probably end up creating some sort of user controlled]]></description>
<content:encoded><![CDATA[<p>When you decide to work with PHP and MySQL you probably end up creating some sort of user controlled application. It might not be your first application but rather soon you start working with forms and suddenly you have created a login form and want to validate the user on every single page to see if the user is allowed to view the page content. Today I will present my <strong>PHP Authorization Class</strong>.</p>
<p>The authorization class will not take care of a login script or anything validating a user trying to login on your application. If you need a <a title="SQL Login script" href="http://vailo.wordpress.com/2008/07/01/sql-login-function/" target="_blank">easy and fast login script you can read all about that</a> on my SQL Login post. This class will take care of the page validation you need to do to make sure the logged in user is valid. This is done by introducing three different types: roles, resources and actions.</p>
<p>A role represents a user group for example guest, member, staff or moderator. A resource is easily explained as an object such as news, articles, users or games. Lastly the action is something you want to do such as add, delete, edit, view or list. With these three types we are able to specify authorization rules for various roles.</p>
<p><!--more--></p>
<p>"Hum, I still don't get it!"</p>
<p>The PHP Authorization Class will help us define and set up rules for different roles. We can apply various action rules onto our resources which are, in the end, connected to our roles. We take a look at a example. Say we have three different roles defined for our application:</p>
<ul>
<li>guest - a visitor on the site which are not logged in.</li>
<li>member - a logged in visitor.</li>
<li>admin - the administrator</li>
</ul>
<p>To simplify our application we only have one resource on the site which is:</p>
<ul>
<li>news</li>
</ul>
<p>If we look at the overall actions we would like to do with this resource we might end up with something like this:</p>
<ul>
<li>view - look at a specific news item</li>
<li>list - look at all news items presented as a list</li>
<li>add - add news</li>
<li>edit - edit news</li>
<li>delete - delete news</li>
</ul>
<p>Going back to our roles, we don't want to let the guest role adding, editing nor deleting news. In this example we don't even let guests view a specific news. As for a member they should be able to view, list and add news. The administrator should be able to do everything. We can achieve this by writing something like this:</p>
<blockquote><p><code>$authorization = new Authorization();<br />
$guest = 'guest';<br />
$authorization-&#62;addRole($guest);<br />
$authorization-&#62;addAccess('news', $guest, 'list');</code></p>
<p><code>$member = 'member';<br />
$authorization-&#62;addRole($member, $guest);<br />
$authorization-&#62;addAccess('news', $member, array('view', 'add'));</code></p>
<p><code>$admin = 'admin';<br />
$authorization-&#62;addRole($admin, $member);<br />
$authorization-&#62;addAccess('news', $admin, array('edit', 'delete'));</code></p></blockquote>
<p>The above code implements the description of rules we stated a bit further up. We made a DSL to implement our authorization class if you will. Let's look at the code in more detail to see if we find anything interesting.</p>
<blockquote><p><code>$authorization = new Authorization();</code></p></blockquote>
<p>We create our PHP Authorization object and assign it to a variable named authorization.</p>
<blockquote><p><code>$guest = 'guest';<br />
$authorization-&#62;addRole($guest);<br />
$authorization-&#62;addAccess('news', $guest, 'list');</code></p></blockquote>
<p>We assign the variable guest the value of 'guest'. Then we add that variable to our list of roles our authorization class holds. The third line adds access rules. We start with providing the resource, the role and lastly the action. We could skip the first line and just add 'guest' instead of $guest. So, to make this very clear: These three lines of code gives the user group/role <em>guest</em> the ability to <em>list </em>all <em>news </em>on the site.</p>
<p>The next two sections are very similar to the first except for two things:</p>
<blockquote><p><code>$authorization-&#62;addRole($member, $guest);<br />
$authorization-&#62;addAccess('news', $member, array('view', 'add'));</code></p></blockquote>
<p>In the first section the addRole method only took one argument and here we have two. What does this mean? It means that the first argument will be extended with the second argument. In this case, member will be extended with guest. This is really useful if member should have the same access as guest plus a few more. We don't need to add the list action to member because guest already has it. Basically guest is the parent of member (which is acting like a child). Everything we add to guest is also added to member even if we decide to assign more rules to guest after we have defined and created the member role. Pretty sweet huh?</p>
<p>The other thing that differ is the number of actions you can provide to the addAccess method. You can add just one action as a normal string or provide an array of actions. Also very useful if a resource has a lot of different actions defined.</p>
<p>So, the code above created our three different roles and we applied different action access for each of the roles on our news resource. Now we are able to query our Authorization class to see if a specific role have access to a specific resource with a specific action. We do this by using the isAllowed method.</p>
<blockquote><p><code>echo $authorization-&#62;isAllowed($guest, 'news', 'list') ? 'allowed' : 'denied';</code></p></blockquote>
<p>What do you think? Is guest allowed to list the news? The answer is yes. Can answer these:</p>
<blockquote><p><code>echo $authorization-&#62;isAllowed($member, 'news', 'list') ? 'allowed' : 'denied';<br />
echo $authorization-&#62;isAllowed($member, 'news', 'add') ? 'allowed' : 'denied';<br />
echo $authorization-&#62;isAllowed($admin, 'news', 'add') ? 'allowed' : 'denied';<br />
echo $authorization-&#62;isAllowed($admin, 'news', 'list') ? 'allowed' : 'denied';<br />
echo $authorization-&#62;isAllowed($admin, 'news', 'comment') ? 'allowed' : 'denied';</code></p></blockquote>
<p>And the answers:</p>
<blockquote><p>Yes, member is extended with guest and guest is allowed to list news.<br />
Yes, member is allowed to add news.<br />
Yes, admin is extended by member and member is allowed to add news.<br />
Yes, admin is extended by member and member is extended by guest and guest is allowed to list news.<br />
No, admin is denied to comment on news.</p></blockquote>
<p>Pretty cool! This can be used in your PHP pages where you need to check if the user is valid. For example in your header file to make sure unauthorized users don't get access to your pages and files. To know if you should add a comment form or not you simple check if the role in question have the access to comment. You are able to be very specific and you can show different parts of the page depending on the role type.</p>
<p>Since the class doesn't require a database it's 100% customizable. You can add your very own roles, resources and actions. All of this sounds pretty nice but how would it work in real action? I will give you a sweet example.</p>
<p>To be able to check if the role has access to the resource with a specific action we need to know the role, the resource and of course the action. It might sound like a huge amount of effort to get this to work, but it isn't! The specific role needs to be fetch from the user in question. Let's say we have a database with users and each user has a access type, say A-C. Either you can use these values straight of as your roles or we can translate them to understandable roles: A = guest, B = member and C = admin. This can then be saved in a session or in anyway you know as long as you are able to access it often and fast. The get our hands on the resource and action we can use the splendid mod_rewrite found in the Apache server software. If you don't know what this module does, I suggest you <a title="Friendly URL's" href="http://vailo.wordpress.com/2008/06/30/friendly-urls-with-wamp-apache/" target="_blank">take a peak at my other post about friendly URL's</a>. If we use the .htaccess wisely we will be able to fetch the resource and action from our URL.</p>
<p>.htaccess example:</p>
<blockquote><p><code>RewriteEngine on<br />
RewriteRule ^([a-z_]+)$ /authorization/$1/ [R]<br />
RewriteRule ^([a-z_]+)/$ /authorization/index.php?resource=$1&#38;action=list<br />
RewriteRule ^([a-z_]+)/([a-z_]+)$ /authorization/$1/$2/ [R]<br />
RewriteRule ^([a-z_]+)/([a-z_]+)/$ /authorization/index.php?resource=$1&#38;action=$2</code></p></blockquote>
<p>In this example my root is /authorization. The first two rewrites takes care of an example looking like this:</p>
<blockquote><p>http://www.dosspot.com/games</p></blockquote>
<p>It will first add a / to the end and reload and send the user to my index page with two get variables resource and action. We we haven't added an action the default action is list. The other two rules are activated if we have applied an action to.</p>
<blockquote><p>http://www.dosspot.com/games/view/</p></blockquote>
<p>Now we are able to fetch the resource and action out from our GET array and see if the role is valid for this page. If not we send him/her of to another page. So now we have two examples where we use the Authorization class inside a page using the isAllowed method to see if the user in question should be able to do various actions. Or we can use the URL to fetch the resource and action in question and validate. In our index.php page it might look something like this:</p>
<blockquote><p><code>if(isset($_GET['resource']) &#38;&#38; isset($_GET['action'])) {<br />
$resource = mysql_real_escape_string($_GET['resource']);<br />
$action = mysql_real_escape_string($_GET['action']);<br />
$role = $_SESSION['role'];<br />
}</code></p>
<p><code>if($authorization-&#62;isAllowed($role, $resource, $action)) {<br />
echo 'You are allowed';<br />
} else {<br />
echo 'You are not allowed in here!';<br />
}</code></p></blockquote>
<p>Pretty simple put yet effective. But! There is more to it! Now we have a set of methods we can use to grant access to resources with different actions. If a user doesn't have the access s/he is thrown out from that page. We might want to apply a few of these access rules to every role avaible and we don't want to use extend, because there might just be one access we want to share, and we don't want to write it twice. How can we do this? Simple, we add null instead of a role in the addAccess method. By supplying null as the role the access rule will be applied to all roles, including roles added after the null access.</p>
<p>So let's say we want our guest to be able to access both the list and add news. The member role should just be able to list, not add. In this case we cannot extend the member role with the guest role since then the member role would be able to add news. Here is some code:</p>
<blockquote><p><code>$authorization = new Authorization();<br />
$authorization-&#62;addAccess('news, null, 'list);</code></p>
<p><code>$guest = 'guest';<br />
$authorization-&#62;addRole($guest);<br />
$authorization-&#62;addAccess('news', $guest, 'add');</code></p>
<p><code>$member = 'member';<br />
$authorization-&#62;addRole($member);<br />
$authorization-&#62;addAccess('news', $member, 'view');</code></p></blockquote>
<p>With this slightly different code everyone will be able to list the news but the guest will be the only one able to add news and member the only one able to view a news. If this would be a real case it would be very bad, in this example though it shows the example pretty well. Notice that member isn't extended by the guest role.</p>
<p>The next thing we might be interested in is how we save the authorization object. We can do this with a simple session or we can store it using the serialize method in PHP. Since we have been working with session before we are going to use the serialize technique. Basically we are able to serialize an object meaning that we are able to save it on a file. We can then just unserialize the file and get our object back. By doing this we can write our authorization code in one file, serialize it and remove that code. Since the object is stored in a file we don't need to create our object everytime we want to access it, we just unserialize the file and the object with it's current state it presented to us. Sadly I'm a newbie working with the serialize method so if you know any problems or errors working with it, please let me know.</p>
<p>We simply use the save() method in the Authorization class to serialize our authorization object. We are able to provide a filename, by default it's saved as authorization. With our .htaccess file we are able to block everyone out from this file and deny everyone trying to access it. In every page we want to validate the user we simple do this:</p>
<blockquote><p><code>include('Authorization.php');<br />
$object = implode("", @file("authorization"));<br />
$authorization = unserialize($object );</code></p></blockquote>
<p>We have to include the class file and then we read the file and finally use the unserialize method to unserialze the object and we assign it again to our authorization variable. Now we are able to use the object exactly the same as we did in the examples above. Combine this with the .htaccess rewrite options you will find it rather easy to control the visitors using your system. It's easy, straight forward and pretty cool!</p>
<p>The download below provides everything you will need to run the authorization class, including unit tests!</p>
<ul>
<li><a title="Authorization Class" href="http://www.dosspot.com/authorization.zip" target="_blank">Download the PHP Authorization Class</a></li>
</ul>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Verbatim String: a string precede with a @ character (the at sign).]]></title>
<link>http://lxcid.wordpress.com/?p=33</link>
<pubDate>Tue, 29 Jul 2008 18:20:43 +0000</pubDate>
<dc:creator>lxcid</dc:creator>
<guid>http://lxcid.wordpress.com/?p=33</guid>
<description><![CDATA[C# support 2 type of strings: regular string and verbatim string.
In this post we will try to explai]]></description>
<content:encoded><![CDATA[<p>C# support 2 type of strings: regular string and verbatim string.</p>
<p>In this post we will try to explain what is a verbatim string.</p>
<p>An explanation of <a href="http://msdn.microsoft.com/en-us/library/aa691090(VS.71).aspx" target="_blank">verbatim string in MSDN</a> is:</p>
<blockquote><p>A verbatim string literal consists of an <code class="ce">@</code> character followed by a double-quote character, zero or more characters, and a closing double-quote character. A simple example is <code class="ce">@"hello"</code>. In a verbatim string literal, the characters between the delimiters are interpreted verbatim, the only exception being a <em>quote-escape-sequence</em>. In particular, simple escape sequences and hexadecimal and Unicode escape sequences are not processed in verbatim string literals. A verbatim string literal may span multiple lines.</p></blockquote>
<p>The MSDN explanation of  is clear cut enough but allow me to give you one example:</p>
<pre>@"\w+([-.]\w+)*\@\w+([-.]\w+)*\.[A-Za-z]{2,4}$"</pre>
<p>The above string is a regular expression for validating an email address.</p>
<p>Notice in the above string, I used the <a href="http://en.wikipedia.org/wiki/Escape_character" target="_blank">'\' (</a><a href="http://en.wikipedia.org/wiki/Escape_character" target="_blank">escape</a><a href="http://en.wikipedia.org/wiki/Escape_character" target="_blank">) </a><a href="http://en.wikipedia.org/wiki/Escape_character" target="_blank">character</a> quite a number of times. But a closer observation will prompt one questions: none of the <a href="http://en.wikipedia.org/wiki/Escape_sequence" target="_blank">escape sequence</a> make sense. This is where the <code>@</code> character preceding the string come handy. The <code>@</code> character basically tell the compiler to ignore escape character in the string that follows.</p>
<p>Without the preceding @ character, the above regular expression string should be written as:</p>
<pre>"\\w+([-.]\\w+)*\\@\\w+([-.]\\w+)*\\.[A-Za-z]{2,4}$"</pre>
<p>Hope this helps.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[validate XML File against inline Schema]]></title>
<link>http://herbee.wordpress.com/?p=94</link>
<pubDate>Mon, 28 Jul 2008 11:20:18 +0000</pubDate>
<dc:creator>herbee</dc:creator>
<guid>http://herbee.wordpress.com/?p=94</guid>
<description><![CDATA[&#8221;&#8217; &lt;summary&gt;
&#8221;&#8217; validates XML File against inline Schema
&#8221;]]></description>
<content:encoded><![CDATA[<p>''' &#60;summary&#62;<br />
''' validates XML File against inline Schema<br />
''' &#60;/summary&#62;<br />
''' &#60;param name="sXmlFile"&#62;xml File mit Schema und Daten&#60;/param&#62;<br />
''' &#60;returns&#62;true no errors, false errors&#60;/returns&#62;<br />
''' &#60;remarks&#62;not used, not ready&#60;/remarks&#62;<br />
'''<br />
Public Function ValidateXMLFileInternalXSD(ByVal sXmlFile As String) As Boolean<br />
Try<br />
Dim oXmlReaderSettings As New XmlReaderSettings()<br />
oXmlReaderSettings.ValidationType = ValidationType.Schema<br />
oXmlReaderSettings.ValidationFlags = oXmlReaderSettings.ValidationFlags Or XmlSchemaValidationFlags.ProcessInlineSchema<br />
oXmlReaderSettings.ValidationFlags = oXmlReaderSettings.ValidationFlags Or XmlSchemaValidationFlags.ReportValidationWarnings<br />
AddHandler oXmlReaderSettings.ValidationEventHandler, AddressOf oXmlReaderSettingsValidationEventHandler<br />
Dim reader As XmlReader = XmlReader.Create(sXmlFile, oXmlReaderSettings)<br />
' parse reader<br />
While (reader.Read())<br />
End While<br />
Catch ex As XmlException<br />
Console.WriteLine("XmlDocumentValidationExample.XmlException: {0}", ex.Message)<br />
Return False<br />
Catch ex As XmlSchemaValidationException<br />
Console.WriteLine("XmlDocumentValidationExample.XmlSchemaValidationException: {0}", ex.Message)<br />
Return False<br />
Catch ex As Exception<br />
Console.WriteLine("XmlDocumentValidationExample.Exception: {0}", ex.Message)<br />
Return False<br />
End Try<br />
Return True<br />
End Function</p>
<p><a href="http://herbee.ourtoolbar.com/">..:: Whereever you go, stay in touch. Download toolbar now! It´s free, private and secure. ::..</a></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[validate XML File against XSD File]]></title>
<link>http://herbee.wordpress.com/?p=92</link>
<pubDate>Mon, 28 Jul 2008 11:18:36 +0000</pubDate>
<dc:creator>herbee</dc:creator>
<guid>http://herbee.wordpress.com/?p=92</guid>
<description><![CDATA[&#8221;&#8217; &lt;summary&gt;
&#8221;&#8217; validates XML File against XSD File
&#8221;&#8217; ]]></description>
<content:encoded><![CDATA[<p>''' &#60;summary&#62;<br />
''' validates XML File against XSD File<br />
''' &#60;/summary&#62;<br />
''' &#60;param name="sXmlFile"&#62;xml data&#60;/param&#62;<br />
''' &#60;param name="sXSDFile"&#62;external xml schema&#60;/param&#62;<br />
''' &#60;returns&#62;true no errors, false errors&#60;/returns&#62;<br />
''' &#60;remarks&#62;&#60;/remarks&#62;<br />
Public Function ValidateXMLFileExternalXSD(ByVal sXmlFile As String, ByVal sXSDFile As String)<br />
Try<br />
Dim oXmlReaderSettings As XmlReaderSettings = New XmlReaderSettings()<br />
oXmlReaderSettings.Schemas.Add("http://www.tempuri.org", sXSDFile)<br />
AddHandler oXmlReaderSettings.ValidationEventHandler, New ValidationEventHandler(AddressOf oXmlReaderSettingsValidationEventHandler)<br />
oXmlReaderSettings.ValidationFlags = oXmlReaderSettings.ValidationFlags And XmlSchemaValidationFlags.ReportValidationWarnings<br />
oXmlReaderSettings.ValidationType = ValidationType.Schema<br />
Dim reader As XmlReader = XmlReader.Create(sXmlFile, oXmlReaderSettings)<br />
Dim oDom As New XmlDocument<br />
oDom.Load(reader)<br />
Catch ex As XmlException<br />
Console.WriteLine("XmlDocumentValidationExample.XmlException: {0}", ex.Message)<br />
Return False<br />
Catch ex As XmlSchemaValidationException<br />
Console.WriteLine("XmlDocumentValidationExample.XmlSchemaValidationException: {0}", ex.Message)<br />
Return False<br />
Catch ex As Exception<br />
Console.WriteLine("XmlDocumentValidationExample.Exception: {0}", ex.Message)<br />
Return False<br />
Finally</p>
<p>End Try<br />
Return True<br />
End Function</p>
<p><a href="http://herbee.ourtoolbar.com/">..:: Whereever you go, stay in touch. Download toolbar now! It´s free, private and secure. ::..</a></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[What's he Playing At?  (ha! another pun!)]]></title>
<link>http://londonlayovers.wordpress.com/?p=89</link>
<pubDate>Wed, 16 Jul 2008 16:54:25 +0000</pubDate>
<dc:creator>Tilia</dc:creator>
<guid>http://londonlayovers.wordpress.com/?p=89</guid>
<description><![CDATA[Posted by Tilia
Guitar Guy is starting to seriously piss me off.
I mean, okay, as a person, I&#8217;]]></description>
<content:encoded><![CDATA[<p style="text-align:right;"><strong><span style="color:#ff0000;"><span style="color:#33cccc;">Posted by Tilia</span></span></strong></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">Guitar Guy is starting to seriously piss me off.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">I mean, okay, as a person, I'm generally pissed off by at least a few things at any given time, but this is ridiculous.  The man is managing to both validate me and try to reject me at the same time, and unless I can repeatedly slap him or (preferably) get him into a dark corner and have my wicked way with him, I see no obvious resolution before my departure for the motherland.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">Last night, work seeming futile because one of our rare, all-day Florida thunderstorms was in the works (usually there's 20 minutes of apocalyptic downpour, complete with hail and lightening, and then we're back to tropical blue skies with very little fuss), we all went in with low expectations for business and a laid back demeanor.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">While chatting at the bar with my roommate and the hot gay bartender about his recent tryst with an ex, whom he now knows is in a relationship, I pointed out to him that his ex's new beau is in no way his responsibility.  To which the roommate responded, laughingly, "Yeah, this from the girl who wants to hook up with someone in a --."</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">And then we were cut off.  By Guitar Guy.  Rounding the corner.  Awkward.  He definitely knew something was up as we all fell silent and looked at him expectantly until he expressed a want for a bottle of water, which I was made to retrieve.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">Anyway, as the night progressed, Guitar Guy continued his futile attempts to distance himself from me, by trying to not let me catch him watching me.  Now, okay, honestly, Guitar Guy, if you're really trying to distance yourself, wouldn't you just stop staring all together?</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">It got so ridiculous that, not only were other co-workers noticing, with laughs, that as soon as I'd glance at the stage, he'd quickly jerk his focus down to the floor and stay there for several minutes, but guests started to pick up on it too.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">Around 2/3 of the way through the night, he almost slammed into me as I turned away from a table, and he quickly said he was sorry.  I'm not sure why, but my reply was a snippy, "Are you?"</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">I'm not sure why I said it.  All I know is that as I walked away, I heard him say "Yes?" in a puzzled sort of way.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">I guess I should be over it, and maybe I would be if he weren't so cripplingly touchable, and if there weren't these moments that broke away from the irritation.  Last night, for example, after ringing in another 17 beers for my drunken table of Brits, I turned from the computer to search for someone to help me take down some garbage bags, and unexpectedly caught his eye, as he'd been intently watching me from the stage.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">The song being performed at the moment was "I can't make you love me," which, while lyrically inappropriate, was tonally just fine.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">My smile immediately slipped from my face and we remained trained on each other for a good fifteen seconds or so until, though it seemed to pain him, he forced himself to look away.  I was unexpectedly jolted by this, deep in my stomach, and I'm not really sure what it means.  The moment itself was intense beyond description.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">Aside from getting a light up tee shirt that flashes the word "Sex?" when I push a button and using it on him every time no one else is looking until he cracks, I can't think of a good way to resolve this in a quick and efficient manner.</span></span></p>
<p><span style="color:#ff0000;"><span style="color:#33cccc;">He needs to get out of his relationship, as it clearly isn't fulfilling him.  And then he needs to come over, and fulfill me.</span></span></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Please, please, validate my existence!]]></title>
<link>http://stickerbuddy.wordpress.com/?p=24</link>
<pubDate>Sat, 12 Jul 2008 22:26:13 +0000</pubDate>
<dc:creator>StickerHappy</dc:creator>
<guid>http://stickerbuddy.wordpress.com/?p=24</guid>
<description><![CDATA[I&#8217;ve always been the quiet, soft spoken person trying to disappear in the crowd but oftentimes]]></description>
<content:encoded><![CDATA[<p style="margin-bottom:0;">I've always been the quiet, soft spoken person trying to disappear in the crowd but oftentimes that very nature is what catches the attention and imagination of strangers. I'm always described as shy, not anti social but I usually creep people out when they don't hear a peep from me to complete a conversation flow. I hate parties, I hate  gatherings, I hate any sort of public socializing that has no purpose other than to socialize. To me, an activity, action, job or interest comes first. Socializing will just follow afterwards if it feels like it. I'm not shy or quiet. I just don't have an opinion or a story to tell. Isn't that enough?</p>
<p style="margin-bottom:0;"><a href="http://stickerbuddy.files.wordpress.com/2008/07/386797.jpeg"><img class="alignleft size-medium wp-image-25" style="margin:10px;" src="http://stickerbuddy.wordpress.com/files/2008/07/386797.jpeg?w=230" alt="" width="230" height="300" /></a></p>
<p style="margin-bottom:0;">I used to paint traditional portraits, still life, and the occasional abstract art when I felt really angry and short of the deadline and found that once the painting is hung and displayed for sale, it's your opinion of your piece that matters, not the concept, idea or message that's already obvious in your piece. I could've painted an upside down man and picked a random bullshit speech on agony and suffering completely out of the blue... and people would just eat it all up. I found that it didn't matter what subject I painted, I got the same kind of response whether something mattered to me or not. Are these people really “seeing” it? Are they really acknowledging my skill or are they just trying to be nice? It's difficult for me to take people's feedback seriously when it's meant to be an emotional transaction than validating what it is that I have achieved.</p>
<p style="margin-bottom:0;">I have a tendency to be over critical of my artwork and point out obvious errors and critic it to try and get a response or opinion to help me fix the problem but all I would get is the “Oh, it's so wonderful!” No, you're not listening. I'm serious. Her eye is lopsided, he's missing his big toe, he has buck teeth, the orange looks like a miniature watermelon, it didn't matter how horrible or glaringly bad it was, I would get a response leading to a pat on the back. When I didn't respond appreciatively, I would get a puzzled look.</p>
<p style="margin-bottom:0;">Everybody loves a modest talent up until that person fully realizes their capacity and acknowledges it them self. This is often unfairly labeled “arrogance” when truly it's just jealousy for this person's understanding of themselves better than you understand yourself. I draw and write because I enjoy doing it and because I believe other people might enjoy it too. It means more to me to actually draw and write than it is to hear and acknowledge someone's opinion about it. Sure, I enjoy reading feedback, but I'm not obligated to have to validate you or accept it. This is what's difficult about the arts or sharing interests, automatically it's considered something that everybody is obligated to have a say on and for you as the artist to take it even if it doesn't mean anything to you. Nobody likes a self-deprecating whore after a while.</p>
<p style="margin-bottom:0;">I find that many people play a social echolocation game where they're only talking and socializing with other people simply to figure out who agrees with who and to validate their existence. They automatically become insulted when you don't recognize this. Honestly, you don't need any body's validation to feel important. You only need yourself.</p>
<p style="margin-bottom:0;">It already takes a lot of courage to understand and accept yourself for who you are and what you value. Nobody else can do this for you but yourself. Before you can even start to appreciate something or someone, those feelings and thoughts start with you.</p>
<p style="margin-bottom:0;"><em>“To say 'I love you' one must first be able to say the 'I.'”</em></p>
<p style="margin-bottom:0;">
]]></content:encoded>
</item>
<item>
<title><![CDATA[The PHP Forms Class]]></title>
<link>http://vailo.wordpress.com/?p=51</link>
<pubDate>Wed, 25 Jun 2008 06:02:52 +0000</pubDate>
<dc:creator>vailo</dc:creator>
<guid>http://vailo.wordpress.com/?p=51</guid>
<description><![CDATA[The PHP Forms class is the last class out of 4 in the PHP Class series #1. So far we have been looki]]></description>
<content:encoded><![CDATA[<p><strong>The PHP Forms class</strong> is the last class out of 4 in the PHP Class series #1. So far we have been looking at a <a title="Database Class" href="http://vailo.wordpress.com/2008/06/21/the-database-class/" target="_self">Database Class</a>, a <a title="Paging Class" href="http://vailo.wordpress.com/2008/06/22/the-paging-class/" target="_self">Paging Class</a> and a <a title="Record class" href="http://vailo.wordpress.com/2008/06/23/the-php-record-class/" target="_self">Record Class</a> and now it's time to integrate and implement our Forms Class to get a good end on the first series. The reason for creating this PHP Forms Class is to make working with forms and validating forms a lot more fun and easy. We have a few goals we want the Forms Class to for fill:</p>
<ol>
<li>Extracting all form tags and attributes into our Forms class.</li>
<li>Auto-generate a form based on a table in a MySQL database.</li>
<li>Validate form fields using keywords such as letter, number, string, email, text and file.</li>
<li>Add, edit and delete form fields from a form based on a table or built from scratch.</li>
</ol>
<p><!--more--></p>
<blockquote><p><strong>UPDATES: </strong>This walkthough is covering the basics of the PHP Form class. The download at the bottom of the page includes the very latest version which might be slightly different than the walkthough here!</p></blockquote>
<p>Okay, looking a bit closer at our goals we see that the second goal is rather complex. If we manage to pull it off it will be really sweet. We need to handle normal form fields, text fields, file fields and select boxes, radio boxes and checkboxes. And all this needs to be auto-generate just using information from our MySQL database. We will work with three different pages: the one handling the Forms Class, the JavaScript handling the AJAX and the PHP validation script. Before we continue I want to tell you that none of these PHP classes is 100% correct or flawless. I'm posting them here to get input from you and share my ideas.</p>
<p>All 4 goals will be reach using 12 different functions and 7 private class variables and 1 static privat  variable. We start presenting the private class variables:</p>
<ul>
<li>$_fields: is a array containing all form fields</li>
<li>$_method: is either 'POST' or 'GET', used when applying the &#60;form&#62; tag.</li>
<li>$_action: contains the URL we should go to when the form is validated an submitted.</li>
<li>$_id: each form we create will have a unique id, we can either provide one or it will get an auto-generate form id.</li>
<li>$_db: holds and database instance.</li>
<li>$_table: the name of a database table.</li>
<li>$_validate: a boolean variable telling us to validate or not.</li>
<li>$_numForms: the static private variable, counting how many forms we create.</li>
</ul>
<p><a href="http://vailo.files.wordpress.com/2008/06/form_vars.png"><img class="alignnone size-medium wp-image-58" src="http://vailo.wordpress.com/files/2008/06/form_vars.png?w=300" alt="Code describing the private class variables" width="300" height="15" /></a></p>
<p>The functions in the form.php file are:</p>
<ul>
<li>public __construct(): initializing our form object.</li>
<li>public addField(): we use this to add a form field to our object.</li>
<li>public getField(): returns the given form field.</li>
<li>public setField(): updates a given form field.</li>
<li>public setAttribute(): updates a attribute of a field in the form fields arra.</li>
<li>public removeField(): removes a given form field.</li>
<li>public generate(): generates a form from a specific MySQL database table.</li>
<li>private createField(): creates the actual html markup</li>
<li>private createLabel(): help function to createField(), generates a label.</li>
<li>pubic validate(): makes it possible to turn off the validation script.</li>
<li>public create(): sets everything together.</li>
<li>public view(): used for debug.</li>
</ul>
<p>Starting with the <code>__construct()</code> function we are required to supply at least 2 parameters: <code>$method</code> and <code>$action</code>. They have the same task as in normal HTML markup, the <code>$method</code> decide if we should use 'GET' or 'POST'. The <code>$action</code> let us know where we are suppose to go when the form is valid and submitted. Then we are able to supply a third parameter in a array. The array can have an 'id', 'db' and 'table' key. Even though the <strong>Form Class</strong> gives a unique id to every form we create we might want to supply our own id, this is done here. As for the 'db' and 'table' key, these are used when we want to auto generate a form using the <code>generate()</code> function. Since the third parameter is optional we don't need to supple a 'db' and 'table' to be able to create a form from scratch. At the very end of the function we create a $_SESSION which we will use when we validate. The main task of the function is to assign our private class variables with the incoming parameters. We are using static class functions from the Common Class.</p>
[caption id="attachment_116" align="alignnone" width="300" caption="Form __construct() method"]<a href="http://vailo.files.wordpress.com/2008/07/form_construct.png"><img class="size-medium wp-image-116" src="http://vailo.wordpress.com/files/2008/07/form_construct.png?w=300" alt="Form __construct() method" width="300" height="158" /></a>[/caption]
<p>Next, public <code>addField()</code>. The function takes 3 parameters, 2 required, 1 optional. The required once are <code>$name, $type</code> and the optional <code>$attributes</code>.</p>
<ul>
<li>$name: the name of the field.</li>
<li>$type: which type the field should be. (text, password, textarea, select, radio, checkbox)</li>
<li>$attributes: a vast list of key =&#62; value entries in an array. Each one will be described in the validation presentation.</li>
</ul>
<p>The function assigns new fields into our class variable <code>$_fields</code>. If we find a field with the type = file we change the private variable <code>$method</code> to post. The <code>$attribute </code>parameter is the magic parameter holding all information regarding validation. We check if we want to show labels and if we find any 'snippets'. A snippet is a piece of code we want to add after the field.</p>
[caption id="attachment_117" align="alignnone" width="300" caption="Form addField() method"]<a href="http://vailo.files.wordpress.com/2008/07/form_addfield.png"><img class="size-medium wp-image-117" src="http://vailo.wordpress.com/files/2008/07/form_addfield.png?w=300" alt="Form addField() method" width="300" height="98" /></a>[/caption]
<p>Next four functions are rather easy and self-telling. We use these functions to manipulate fields already added in the private <code>$_fields</code> variable, which were created from our auto-generate function. We might want to remove fields, edit field values or validation rules, look at a field and more. The functions I'm talking about is <code>getField(), setField(), setAttribute()</code> and <code>removeField()</code>. We just make sure the parameter, $key, is found in our private <code>$_fields</code> array. The $key must be the name of the field.</p>
[caption id="attachment_118" align="alignnone" width="300" caption="Form get &#38; set methods"]<a href="http://vailo.files.wordpress.com/2008/07/form_getset.png"><img class="size-medium wp-image-118" src="http://vailo.wordpress.com/files/2008/07/form_getset.png?w=300" alt="Form get &#38; set methods" width="300" height="268" /></a>[/caption]
<p>This next public function is a rather large one, but not that complicated. The <code>generate()</code> function is the function making this <strong>Form Class</strong> interesting. The function takes 1 optional parameters: <code>$attributes</code>. The <code>$</code><code>attributes</code> parameter is an array of default values and default validation rules. The first thing we do is to see that we have added a database object and a table to work on. After that we gather information from both the mysql_fetch_field method and by using the 'SHOW COLUMNS' query command. This is because we want to know two important things:</p>
<ol>
<li>When we encounter a blob, we need to know if it is of data type text or a file. This can't be done just using mysql_fetch_field.</li>
<li>When we encounter a enum, we want to be able to get all values in a nice radio link. This can't either be done just using mysql_fetch_field.</li>
</ol>
<p>The two ways of getting information about a MySQL field is sometime overlaying each other, meaning we get the same information twice, at least we are able to fetch the same information from both techniques. Sadly non of them alone is supplying enought information, therefore we use both techniques.</p>
<p>Inside the for-loop we are able to set validations rules to each field depending on the data type of the field in the database. The validation rules are these: required, format, min, max, label, showLabel, boxClass, fieldClass and snippet. This means we can set a max value and a min value. We are able to see if the field is required or optional and set a validation rule for that. Each field will get a 'format' rule depending on the data type. If the name of the field is 'email' or 'password' we use special format validation rules. We can supply a class for the form field and a box class for the div around each form field. At the very end we add each field to our private <code>$_field</code> array using the <code>addField()</code> function. Basically this function takes one field at a time found in the supplied MySQL database table. We gather as much information as possible about the field and then make desicions about which validation rules the field should get. When we are done we add it to the private <code>$_fields</code> variable.</p>
[caption id="attachment_119" align="alignnone" width="300" caption="Form generate() method"]<a href="http://vailo.files.wordpress.com/2008/07/form_generate.png"><img class="size-medium wp-image-119" src="http://vailo.wordpress.com/files/2008/07/form_generate.png?w=300" alt="Form generate() method" width="300" height="271" /></a>[/caption]
<p>Puew, that's a long function but each line is small and simple. The next function, <code>createField()</code> is also a long function but a very simple one. The function will create a correct label and form field with the HTML markup code. We will look at the field and see if the field type matches anything of: text, password, hidden, file, radio, checkbox, textarea, select or submit. If it does we create the HTML markup code. Together with this function we use <code>createLabel()</code>, it will create the label for the field and it's used as a help function to <code>createField()</code>. The code itself is not that complicated so I will not describe it any further, it's just made up of if/elseif to find the correct field type.</p>
[caption id="attachment_120" align="alignnone" width="300" caption="Form createField() method"]<a href="http://vailo.files.wordpress.com/2008/07/form_createfield.png"><img class="size-medium wp-image-120" src="http://vailo.wordpress.com/files/2008/07/form_createfield.png?w=300" alt="Form createField() method" width="300" height="237" /></a>[/caption]
<p>The next three functions are similar the ones found in the <a title="Database class" href="http://vailo.wordpress.com/2008/06/21/the-database-class/" target="_blank">Database Class</a> and the <a title="Paging Class" href="http://vailo.wordpress.com/2008/06/22/the-paging-class/" target="_blank">Paging Class</a>. The first one is <code>validate()</code>, with this you are able to turn of the validating script when setting the incoming parameter to false, the validating script is true as default.</p>
<p>The <code>create()</code> function will gather all the information about the fields we have provided and finally end up adding the form tags making it possible to echo out the result as a working form with correct and valid syntax. Lastly we have the <code>view()</code> function which is used when we want to debug our form, we are able to see which fields we have, the validation rules, values and much more.</p>
[caption id="attachment_121" align="alignnone" width="300" caption="Form createLable(), validate(), create() and view() methods"]<a href="http://vailo.files.wordpress.com/2008/07/form_rest.png"><img class="size-medium wp-image-121" src="http://vailo.wordpress.com/files/2008/07/form_rest.png?w=300" alt="Form createLable(), validate(), create() and view() methods" width="300" height="199" /></a>[/caption]
<p>Okay, we are done with the first part of the <strong>Form Class</strong> We have presented the actual Form class. With this we are able to write a form using this syntax:</p>
[caption id="attachment_122" align="alignnone" width="300" caption="Form syntax"]<a href="http://vailo.files.wordpress.com/2008/07/form_syntax.png"><img class="size-medium wp-image-122" src="http://vailo.wordpress.com/files/2008/07/form_syntax.png?w=300" alt="Form syntax" width="300" height="43" /></a>[/caption]
<p>We create our form object with the two required parameters 'GET', 'default.php' as <code>$method</code> and <code>$action</code>. We add two fields named 'username' and 'password', each with 'text' as type for 'username' and 'password as type for the 'password' field. Then we add the validation rules with different formats, both fields are required and the minium length of the field must be 3 chars long. Lastly we add the 'submit' button.</p>
<p>This next example will show two new things. We will fetch values using our <a title="Record class" href="http://vailo.wordpress.com/2008/06/23/the-php-record-class/" target="_blank">Record Class</a> from a user, we will use the <code>get_values()</code> from the Record class. Secondly we will auto generate the the same form we did in example one. We will add a 'db' and a 'table' key where we create our object. We will then add the values we fetched from our user to our <code>generate()</code> function and the username field will get a default value (password will be empty because that field is empty in the database).</p>
[caption id="attachment_123" align="alignnone" width="300" caption="Form record"]<a href="http://vailo.files.wordpress.com/2008/07/form_record.png"><img class="size-medium wp-image-123" src="http://vailo.wordpress.com/files/2008/07/form_record.png?w=300" alt="Form record" width="300" height="90" /></a>[/caption]
<p>Both example results is shown here:</p>
<p><a href="http://vailo.files.wordpress.com/2008/06/form_view.png"><img class="alignnone size-medium wp-image-67" src="http://vailo.wordpress.com/files/2008/06/form_view.png?w=167" alt="Example results" width="167" height="278" /></a></p>
<p>Okay, so there we have it. This is the <strong>Form Class part 1</strong>. Coming up is the JavaScript file and the validation PHP page. You might wonder why we will use a PHP page to validate our fields, this is only because we have the Form class containing our fields which we are going to validate.</p>
<p>You can download the full PHP source code of the Forms Class right here:</p>
<ul>
<li><a title="Forms Class" href="http://www.dosspot.com/Forms.zip" target="_blank">Download the PHP Forms Class source code</a></li>
<li><a title="JavaScript" href="http://vailo.wordpress.com/2008/06/26/the-php-forms-class-javascript/" target="_self">Continue reading about the Forms Class JavaScript</a></li>
<li><a title="Forms Validation" href="http://vailo.wordpress.com/2008/06/27/the-php-forms-class-validation/" target="_self">Continue reading about the Forms Class Validation script</a></li>
<li><a title="Examples" href="http://vailo.wordpress.com/2008/07/06/the-php-series-examples/" target="_self">See the PHP class examples</a></li>
</ul>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Installing a Documentum Lifecycle]]></title>
<link>http://robau.wordpress.com/?p=8</link>
<pubDate>Mon, 23 Jun 2008 20:11:34 +0000</pubDate>
<dc:creator>robau</dc:creator>
<guid>http://robau.wordpress.com/?p=8</guid>
<description><![CDATA[There is no option to do this in DA. But it is really, really simple  
#1 Find the id of the lifecyc]]></description>
<content:encoded><![CDATA[<p>There is no option to do this in DA. But it is really, really simple :)</p>
<p>#1 Find the id of the lifecycle with DQL:</p>
<p>SELECT r_object_id FROM dm_policy WHERE object_name='&#60;your_lifecycle&#62;'</p>
<p>This returns the CURRENT version of the lifecycle</p>
<p># Use API to validate, install:</p>
<p>validate,c,&#60;dm_policy_id&#62;<br />
install,c,,&#60;dm_policy_id&#62;</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Zend Framework: Usando o Zend_Validate com ]]></title>
<link>http://programatik.wordpress.com/?p=58</link>
<pubDate>Sat, 14 Jun 2008 20:04:03 +0000</pubDate>
<dc:creator>programatik</dc:creator>
<guid>http://programatik.wordpress.com/?p=58</guid>
<description><![CDATA[Vou mostrar o uso básico do Zend_Validate, porém não tem segredo. Primeiro começamos com um form]]></description>
<content:encoded><![CDATA[<p>Vou mostrar o uso básico do Zend_Validate, porém não tem segredo. Primeiro começamos com um formulário básico.</p>
<p>[sourcecode language='html']</p>
<form name="frm" action="<? echo $this->baseUrl ?>/Produto/insere" method="post"></p>
<table>
<tr>
<td>
      Nome do Produto:
     </td>
<td>
<input type="text" name="nomeProduto"/>
     </td>
</tr>
<tr>
<td>
      Valor Produto:
     </td>
<td>
<input type="text" name="valorProduto" />
     </td>
</tr>
</table>
<input type="submit" value="Inserir" />
  </form>
<p>[/sourcecode]</p>
<p>[sourcecode language='php']<br />
		class ProdutoController extends Zend_Controller_Action<br />
	{</p>
<p>		function insere(){</p>
<p>			// Pegando os valores da camada de visao</p>
<p>			$nome       = $this->_request->getParam("nomeProduto");<br />
			$valor      = $this->_request->getParam("valorProduto");</p>
<p>			// Dando Loader na classes de validacao<br />
			Zend_Loader::loadClass('Zend_Validate_StringLength');<br />
			Zend_Loader::loadClass('Zend_Validate_Float');</p>
<p>			// Instanciando os validadores<br />
			$validadorNome       = new Zend_Validate_StringLength(1,100);<br />
			$validadorValor      = new Zend_Validate_Float();</p>
<p>			// Setando as mensagens e os tipos de validação<br />
			$validadorNome->setMessage(<br />
					"Campo nome é obrigatório".,<br />
					Zend_Validate_StringLength::TOO_SHORT);</p>
<p>			$validadorNome->setMessage(<br />
					"Campo nome maior que o permitido.",<br />
					Zend_Validate_StringLength::TOO_LONG);</p>
<p>			$validadorValor->setMessage(<br />
					"Campo valor nao é um número válido.",<br />
					Zend_Validate_Float::NOT_FLOAT);</p>
<p>			// Verificando se os valores digitados sao válidos<br />
			if ( $validadorNome->isValid(trim($nome)) &&<br />
				 $validadorNome->isValid($nome) &&<br />
				 $validadorValor->isValid($valor) ){</p>
<p>				// Executa os procedimentos para insercao	</p>
<p>			} else {<br />
				// Deu erro na validacao</p>
<p>				$msg = array_merge( $validadorNome->getMessages(), $validadorValor->getMessages() );</p>
<p>// Na variavel $msg vai ter todos os erros apontados no formulario,<br />
//basta exibir em um alert ou direto no corpo da página.<br />
			}</p>
<p>		}</p>
<p>	}<br />
[/sourcecode]</p>
<p>Uma boa prática é carregar todas as mensagens em um arquivo texto ao invés de utilizar as mensagens direto no arquivo do controller, apesar de php ser uma linguagem script e nao ser necessário a compilação de todo o sistema para apenas a troca de uma mensagem, um arquivo texto com todas as mensagens é válido pois iremos ter centralizado todas as mensagens.</p>
<p>Pode usar um absctract controller que faz esse papel, colocando a mensagem na camada de visao pois ela poderá usar em todos os controladores.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[How to check physical and logical data corruption using RMAN?]]></title>
<link>http://oraclespin.wordpress.com/?p=50</link>
<pubDate>Wed, 11 Jun 2008 17:42:55 +0000</pubDate>
<dc:creator>Amin Jaffer</dc:creator>
<guid>http://oraclespin.wordpress.com/?p=50</guid>
<description><![CDATA[If you are not using RMAN to backup data and use technologies like NetApp snapshot which doesn]]></description>
<content:encoded><![CDATA[<p>If you are not using RMAN to backup data and use technologies like NetApp snapshot which doesn't check for physical and logical corruption, one can still use RMAN to check for physical and logical corruption in the datafiles and not back the data up.</p>
<p>connect target /</p>
<p>run {<br />
   # set disk to be default device type<br />
   CONFIGURE DEFAULT DEVICE TYPE TO DISK;<br />
   # number of concurrent sessions to spawn<br />
   CONFIGURE DEVICE TYPE DISK PARALLELISM 10 BACKUP TYPE TO BACKUPSET;<br />
  # check datafiles for corruption 10 datafiles in each session<br />
   BACKUP VALIDATE CHECK LOGICAL DATABASE FILESPERSET=10;<br />
}</p>
<p>Corruptions information are recorded in the V$DATABASE_BLOCK_CORRUPTION view.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[W3C Validation]]></title>
<link>http://shubhamoy.wordpress.com/?p=33</link>
<pubDate>Wed, 04 Jun 2008 18:34:54 +0000</pubDate>
<dc:creator>Shubhamoy</dc:creator>
<guid>http://shubhamoy.wordpress.com/?p=33</guid>
<description><![CDATA[Hi Folks,
You might have noticed this logo on some websites . Well, this logo means that the page yo]]></description>
<content:encoded><![CDATA[<p>Hi Folks,</p>
<p>You might have noticed this logo on some websites <img src="http://sachinkraj.files.wordpress.com/2008/06/valid-xhtml10-blue.png" alt="Validated XHTML" />. Well, this logo means that the page you are surfing is created according to the norms given by <a title="Goto Wikipedia" href="http://en.wikipedia.org/wiki/W3c"><strong>W3C</strong></a>, for creating a XHTML Page. W3C has also given standards for <a title="Goto Wikipedia" href="http://enwikipedia.org/wiki/html"><strong>HTML</strong></a>, <a title="Goto Wikipedia" href="http://en.wikipedia.org/wiki/xhtml"><strong>XHTML</strong></a>, <a title="Goto Wikipedia" href="http://en.wikipedia.org/wiki/Cascading_Style_Sheets"><strong>CSS</strong> </a>and <a title="Goto Wikipedia" href="http://en.wikipedia.org/wiki/web_feed"><strong>FEED</strong></a>.</p>
<p>Read the full article <a href="http://sachinkraj.wordpress.com/2008/06/04/w3c-validation/"><strong>here</strong></a>.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[W3C Validation]]></title>
<link>http://sachinkraj.wordpress.com/?p=296</link>
<pubDate>Wed, 04 Jun 2008 18:23:41 +0000</pubDate>
<dc:creator>Shubhamoy</dc:creator>
<guid>http://sachinkraj.wordpress.com/?p=296</guid>
<description><![CDATA[Hi Folks,
You might have noticed this logo on some websites . Well, this logo means that the page y]]></description>
<content:encoded><![CDATA[<p>Hi Folks,</p>
<p>You might have noticed this logo on some websites <img src="http://sachinkraj.files.wordpress.com/2008/06/valid-xhtml10-blue.png" alt="Validated XHTML" />. Well, this logo means that the page you are surfing is created according to the norms given by <a title="Goto Wikipedia" href="http://en.wikipedia.org/wiki/W3c"><strong>W3C</strong></a>, for creating a XHTML Page. W3C has also given standards for <a title="Goto Wikipedia" href="http://enwikipedia.org/wiki/html"><strong>HTML</strong></a>, <a title="Goto Wikipedia" href="http://en.wikipedia.org/wiki/xhtml"><strong>XHTML</strong></a>, <a title="Goto Wikipedia" href="http://en.wikipedia.org/wiki/Cascading_Style_Sheets"><strong>CSS</strong> </a>and <a title="Goto Wikipedia" href="http://en.wikipedia.org/wiki/web_feed"><strong>FEED</strong></a>.</p>
<p>Creating a validated page helps a lot in making it <a title="Goto Wikipedia" href="http://en.wikipedia.org/wiki/Cross-browser"><strong>cross-browser</strong></a>. We should always try to create a validated page, as it also makes easier for the search-engine crawlers to find them. And it only requires a little more time but gives a good impression on our visitors(mainly professional) that we are following the standards. Now let me tell you, how to validate-&#62;</p>
<p><strong><span style="text-decoration:underline;">How to validate:</span></strong></p>
<ol>
<li>If you are planning to validate a HTML or XHTML document, then follow this link. <a title="W3C Validator" href="http://validator.w3.org"><strong>Click Here</strong></a>.</li>
<li>It offers validation by three types, i.e., url validation, file upload validation and validation by direct input.</li>
<li>If you happen to validate a CSS file, then follow this link. <a title=" CSS Validator" href="http://jigsaw.w3.org/css-validator/"><strong>Click Here</strong></a>.</li>
<li>If you want to validate a feed, then follow this link. <a title="FEED Validator" href="http://validator.w3.org/feed/"><strong>Click Here</strong></a>.</li>
</ol>
<p>Now you know how to validate. Follow the following links for a demonstration:</p>
<ul>
<li>XHTML Validation. <a title="XHTML Validation" href="http://validator.w3.org/check?uri=http://shubhamoy.sachinkraj.com"><strong>Click Here</strong></a>.</li>
<li>CSS Validation. <strong><a title="CSS Validation" href="http://jigsaw.w3.org/css-validator/validator?uri=http://shubhamoy.sachinkraj.com">Click Here</a></strong>.</li>
<li>FEED Validation. <strong><a title="FEED Validation" href="http://validator.w3.org/feed/check.cgi?url=http://sachinkraj.wordpress.com/feed">Click Here</a></strong>.</li>
</ul>
<p>So next you are creating a webpage, remember to validate it. Till then Happy Reading :-D. Don't forget to post your valuable comments.</p>
<p><strong><span style="text-decoration:underline;">Note:</span></strong></p>
<p>If you ever happen to face problem with validation, you are free to contact us. We will try our best to help you.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Brazilian Rails ! A solução de seus problemas :D]]></title>
<link>http://fabianosoriani.wordpress.com/?p=6</link>
<pubDate>Tue, 20 May 2008 03:27:54 +0000</pubDate>
<dc:creator>fabianosoriani</dc:creator>
<guid>http://fabianosoriani.wordpress.com/?p=6</guid>
<description><![CDATA[Intro: Estava eu feliz fechando a versão parcial do meu site em Rails no meu estágio quando minha ]]></description>
<content:encoded><![CDATA[<p><strong>Intro:</strong> Estava eu feliz fechando a versão parcial do meu site em Rails no meu estágio quando minha chefa vem e me fala: "E essas mensagem de erro em ingles aí ?!" <em>BOM ! Acabou com o meu dia..</em></p>
<p>Pesquisa vai pesquisa vem eu leio num tutorial do TaQ que essas mensagens só podem ser corrigidas pela alteração do código Rails.. vixi Maria.. tudo que eu não curto fazer: explorar código alheio.. e tem mais.. eu deveria modificar novamente no servidor remoto final ! Como ela não falou mais nada, eu deixei quieto né :P Logo depois me passou a tarefa de validar CPF/CNPJ, então, nas minhas explorações por um código pronto decente ouvi falar de um tal de <em>Brazilian-Rails</em>, instalei o bixinho e pá.. ele não valida CPF coisa nenhuma.. uhaehusahehuaeaueauh  <em>(não que eu saiba pelo menos)</em> <strong>PORéM descobri que ele faz coisas muito mais importantes !</strong></p>
<p><strong>Benefícios:</strong></p>
<ul>
<li> Altamente facil de usar.. precisou de uma função ela tá na mão !!</li>
<li>Free &#38; Open.</li>
<li>Ainda em desenvolvimento <em>(nesse caso isso é bom:P</em> )</li>
<li><strong>Tradução das terríveis msgs de erro do validate</strong></li>
<li>Só colar no <span style="text-decoration:underline;">Vendor&#62;Plugins </span>e reiniciar o server que já está funcionando !</li>
<li>Conversões extremamente intuitivas.</li>
<li>Pluralização em portugues !</li>
</ul>
<p><span style="color:#0000ff;">Homepage do Projeto: http://brazilian-rails.rubyforge.org/ Procurem como funciona por lá ok ?</span><br />
Meu <strong><a title="Vlw tapajós !" href="http://www.dc.uel.br/~fpsoriani/brazilian-rails-Abril-08.zip">MIRROR NA UEL</a></strong>, (principalmente para aqueles que sofrem no download de baixo de proxy)<br />
<strong>(esse mirror não é oficial da faculdade e o servidor cai as vezes ok ??)<br />
Versão de Abril de 2008 !</strong></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Validate site pages to follow W3C standards]]></title>
<link>http://ssonawa.wordpress.com/?p=5</link>
<pubDate>Fri, 16 May 2008 12:54:41 +0000</pubDate>
<dc:creator>ssonawa</dc:creator>
<guid>http://ssonawa.wordpress.com/?p=5</guid>
<description><![CDATA[After developing the pages for a website, following link can be used to find out if web pages follo]]></description>
<content:encoded><![CDATA[<p>After developing the pages for a website, following link can be used to find out if web pages follow the W3C standards, like CSS, Markup (HTML, XHTML etc). Its very useful and no need to upload files only specify link in the input box and errors will get listed.</p>
<p><a href="http://validator.w3.org/">http://validator.w3.org/</a></p>
<p> </p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Validatore Carte di Credito]]></title>
<link>http://taninorulez.wordpress.com/?p=137</link>
<pubDate>Sat, 03 May 2008 11:21:59 +0000</pubDate>
<dc:creator>T4n|n0 Ru|3z</dc:creator>
<guid>http://taninorulez.wordpress.com/?p=137</guid>
<description><![CDATA[

In giro esistono molti programmini per controllare se una carta di credito è valida o falsa. Ho d]]></description>
<content:encoded><![CDATA[<p><iframe src='http://digg.com/api/diggthis.php?u=http%3A%2F%2Fdigg.com%2Fsecurity%2FTutorial_Guide_Photoshop_Programming_Msn' height='82' width='55' frameborder='0' scrolling='no' style='float: right; margin-left: 10px; margin-bottom: 5px; padding: 4px 0 2px 4px; background: #fff;'></iframe></p>
<p style="text-align:center;"><img class="aligncenter" src="http://www.dcs-success.com/imglib/java-logo.jpg" alt="" width="150" height="150" /></p>
<p>In giro esistono molti programmini per controllare se una carta di credito è valida o falsa. Ho deciso però anche io di scriverne uno semplice semplice in java. Per farlo,ho usato l'<a href="http://it.wikipedia.org/wiki/Formula_di_Luhn">algoritmo di Luhn</a>. Con lo stesso algoritmo potrete creare anche un generatore di carte di credito. Eccovi il mio scriptino:</p>
<p>[sourcecode language="java"]<br />
public class ValidateCard {</p>
<p>   public static void main(String[] args) {<br />
      if (args.length < 1) {<br />
         System.err.println("Wrong Usage. Use: ValidateCard Card_Number");<br />
         System.exit(1);<br />
      }</p>
<p>      for (int i = 0; i < args.length; i++) {<br />
         System.out.print("Card '" + args[i] + "'" );<br />
      if (!args[i].matches("^\\d{13,19}$")) {<br />
         System.out.println(" Error,must be 13-19 digits.");<br />
      }<br />
      else if (Validate(args[i])) {<br />
         System.out.println(" is a valid credit card.\n");<br />
      }<br />
      else{<br />
         System.out.println(" is an invalid credit card.\n");<br />
      }<br />
      }</p>
<p>      }<br />
   /*<br />
   La formula di Luhn si basa su tre semplici passaggi:</p>
<p>   1. Moltiplicare per 2 ogni cifra posta in posizione dispari, se il risultato è composto da un numero a 2 cifre, bisogna sommarle in modo da ottenere un’unica cifra (es. 18 = 1+8)<br />
   2. Sommare tutti i risultati ottenuti<br />
   3. Sommare al risultato le cifre di posizione par<br />
    */<br />
   public static boolean Validate(String Card_Number){</p>
<p>      int tot = 0;</p>
<p>      for (int i=0; i<= Card_Number.length() - 1; i+=2) {<br />
         int temp = Integer.parseInt(Card_Number.substring(i, i + 1));</p>
<p>            temp *= 2;<br />
            if (temp > 9){<br />
            temp = (temp % 10) + 1;<br />
            }<br />
            tot += temp;<br />
      }<br />
      return (tot % 10 == 0);<br />
   }</p>
<p>}</p>
<p>[/sourcecode]</p>
<div class="techtags" style="text-align:center;"><span style="color:#339966;"><strong>Tech Tags:</strong></span> <a class="techtag" rel="tag" href="http://technorati.com/tag/sicurezza">sicurezza</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/java">java</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/programmazione">programmazione</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/programming">programming</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/validate">validate</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/credit">credit</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/cards">cards</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/software">software</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/download">download</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/linux">linux</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/windows">windows</a> <a class="techtag" rel="tag" href="http://technorati.com/tag/browser">browser</a></div>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Microsoft admits it sent Office nag to all WSUS servers]]></title>
<link>http://smokeys.wordpress.com/?p=65</link>
<pubDate>Sat, 19 Apr 2008 23:07:30 +0000</pubDate>
<dc:creator>Smokey</dc:creator>
<guid>http://smokeys.wordpress.com/?p=65</guid>
<description><![CDATA[April 19, 2008 (Computerworld) Admins, furious, say their Office installs have been falsely fingered]]></description>
<content:encoded><![CDATA[<p><em>April 19, 2008 (Computerworld)</em> Admins, furious, say their Office installs have been falsely fingered as fake:</p>
<p>System administrators have ripped Microsoft Corp. for pushing a trial anti-piracy program meant for limited distribution to all enterprise update servers, a mistake that has triggered false warnings of Office counterfeits.</p>
<p>Earlier this month, Microsoft announced it would kick off a pilot program for software to display nagging notices on copies of Office that it deems fake. The program, part of the Office Genuine Advantage (OGA) initiative, which already requires users to validate their software as legitimate, was to run in only four countries: Chile, Italy, Spain and Turkey. The notices would appear on machines running phony copies of Office XP (called Office 2002 by some), Office 2003 and Office 2007.</p>
<p>Last Tuesday, however, Microsoft published the test update to all Windows Server Update Services (WSUS) servers, and did not limit its delivery to end users in Chile, Italy, Span and Turkey. WSUS is the primary update mechanism used by businesses to patch their Microsoft software. Later, Microsoft said the mistake had seeded the OGA update to WSUS servers for about 24 hours.</p>
<p>By early Wednesday, administrators in the U.S., U.K., New Zealand and elsewhere were posting messages on Microsoft support newsgroups, asking why their WSUS systems had received the Office nag. In some cases, administrators reported that the update had fingered large numbers of desktop PCs as running counterfeit copies of Office.</p>
<p>"Update KB949810 arrived via WSUS yesterday and now all my XP workstations running Word 2002 are telling me it needs activating," said a user identified as "morriswoodyman," who said he is in the U.K. "The only problem is that the software is genuine and was activated three years ago," the user added in a message to a Microsoft support newsgroup.</p>
<p>The support document morriswoodyman referenced -- KB949810 -- is the one associated with the OGA notification update, and was how WSUS labeled the update in its listings.</p>
<p>Source: <a href="http://www.computerworld.com/action/article.do?command=viewArticleBasic&#38;articleId=9079058">ComputerWorld Security</a></p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Webpage validation by World Wide Web Consortium using JavaScript]]></title>
<link>http://tanzilo.wordpress.com/?p=52</link>
<pubDate>Mon, 17 Mar 2008 04:44:48 +0000</pubDate>
<dc:creator>tanzilo</dc:creator>
<guid>http://tanzilo.wordpress.com/?p=52</guid>
<description><![CDATA[If you are a website developer, it will be a really valuable action if you test whether your page pa]]></description>
<content:encoded><![CDATA[<p>If you are a website developer, it will be a really valuable action if you test whether your page passes the W3C validation standard.  But why should you do this? If your pages pass <a href="http://www.w3.org">W3C</a> standard, it is often guaranteed that your pages will load quicker in modern web browsers and be easier to maintain. You can validate your pages directly from <a href="http://www.w3.org">World Wide Web Consortium</a>'s website. And the link is here: http://validator.w3.org.</p>
<p>We can write a JavaScript that can validate a page on given parameter. Below I have written a very simple JavaScript function to test a page's web standard. But you can customize it according to your requirements. This kind of JavaScript function can be helpful when we have lots of pages and we need to check them one by one by just clicking a button. Now let us make a HTML page with a JavaScript function and we will give <b>validator.html</b> as its name. The page's code is as below:</p>
<p class="MsoNormal"><span style="color:#993300;">&#60;html&#62;<br />
&#60;head&#62;<br />
&#60;title&#62;W3C Web Standard Test&#60;/title&#62;<br />
&#60;script language="javascript" type="text/javascript"&#62;<br />
<span></span></span></p>
<p class="MsoNormal"><span style="color:#993300;">function testMyPage(webpageLocation)<br />
<span></span>{<br />
<span></span></span></p>
<p class="MsoNormal"><span style="color:#993300;">var url = 'http://validator.w3.org/check?uri=' + webpageLocation;</span></p>
<p class="MsoNormal"><span style="color:#993300;"><span>                        </span>window.open(url, '', 'width=775, height=500, status=yes, resizable=yes, scrollbars=yes, location=yes');</span></p>
<p class="MsoNormal"><span style="color:#993300;"><span>            </span>}</span></p>
<p class="MsoNormal"><span style="color:#993300;"> </span></p>
<p class="MsoNormal"><span style="color:#993300;">&#60;/script&#62;<br />
&#60;/head&#62;<br />
&#60;body&#62;</span></p>
<p class="MsoNormal"><span style="color:#993300;">&#60;input name="Button" type="button" value="Test My Page" onclick="testMyPage('www.wordpress.com');" /&#62;</span></p>
<p class="MsoNormal"><span style="color:#993300;">&#60;/body&#62;<br />
&#60;/html&#62;</span></p>
<p>A new window opens with your given page location i.e. url as below:<br />
<img src="http://tanzilo.wordpress.com/files/2008/03/ss.jpg" alt="ss.jpg" /></p>
<p>Remember that the above window may not appear if you have a pop-up killer active. I suggest you turn off the pop-up killer program (if any) to test the code.</p>
<p>Now, if your page passes the validation, you will get a "<b>This Page Is Valid XHTML 1.0 Transitional!</b>" message. You will also get a <b>congratulations</b> message. If you want, you can use available options such as Show Source, Show Outline, Validate error pages, Clean up Markup with HTML Tidy etc. and revalidate the page.</p>
<p>If you want to test the current page, the <b>validator.html</b> page's code will be as below:</p>
<p class="MsoNormal"><span style="color:#993300;">&#60;html&#62;<br />
&#60;head&#62;<br />
&#60;title&#62;W3C Web Standard Test&#60;/title&#62;<br />
&#60;script language="javascript" type="text/javascript"&#62;</span></p>
<p class="MsoNormal"><span style="color:#993300;"><span>            </span>function testMyPage()</span></p>
<p class="MsoNormal"><span style="color:#993300;"><span>            </span>{</span></p>
<p class="MsoNormal"><span style="color:#993300;"><span>                        </span>var url = 'http://validator.w3.org/check?uri=' + window.location.href;</span></p>
<p class="MsoNormal"><span style="color:#993300;"><span>                        </span>window.open(url, '', 'width=775, height=500, status=yes, resizable=yes, scrollbars=yes, location=yes');</span></p>
<p class="MsoNormal"><span style="color:#993300;"><span>            </span>}</span></p>
<p class="MsoNormal"><span style="color:#993300;"> </span></p>
<p class="MsoNormal"><span style="color:#993300;">&#60;/script&#62;<br />
&#60;/head&#62;<br />
&#60;body&#62;</span></p>
<p class="MsoNormal"><span style="color:#993300;">&#60;input name="Button" type="button" value="Test My Page" onclick="testMyPage();" /&#62;</span></p>
<p class="MsoNormal"><span style="color:#993300;">&#60;/body&#62;<br />
&#60;/html&#62;</span></p>
<p>What I have done here is --- I just changed the <span style="color:#993300;">webpageLocation</span> parameter to <span style="color:#993300;">window.location.href</span>.</p>
<p>I must mention one thing and that is you cannot validate i.e. test web standard of any page that is located in your localhost.</p>
<p>Thus, this is very easy but important to validate our pages. I believe validation should be a part of professional website development although it takes some time. But it is a benchmark of the quality of your webpage.</p>
<p>OK. That is all I know.</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Activa tu Microsoft Office 2007]]></title>
<link>http://shakpablo.wordpress.com/2008/03/16/activa-tu-microsoft-office-2007/</link>
<pubDate>Sun, 16 Mar 2008 15:02:52 +0000</pubDate>
<dc:creator>shakpablo</dc:creator>
<guid>http://shakpablo.wordpress.com/2008/03/16/activa-tu-microsoft-office-2007/</guid>
<description><![CDATA[Para aquellos que tiene el Office 2007 BETA o comprarón una computadora Nueva con Windows Vista, pu]]></description>
<content:encoded><![CDATA[<p>Para aquellos que tiene el Office 2007 BETA o comprarón una computadora Nueva con Windows Vista, pues me imagino que les trajo una versión del Office, versión de prueba por 60 días. Pues de tanto que me pedían alguno que publicará un método, me di la tarea de buscar el modo de quitar la advertencia de que cuando haya pasado los 60 días no te pida activación del producto. Logré encontrar dicho método, <b>cabe mencionar que no lo he probado si funciona. Ustedes me dicen si logró funcionar.</b></p>
<p>Bueno aquí va como hacer dicho método:</p>
<p>1. Primero debemos cerrar todo producto de Microsoft Office.</p>
<p>2. Vamos a  <b>Inicio &#62; Ejecutar &#62; Escribimos regedit</b></p>
<p>3. Debemos buscar esta entrada:</p>
<p><b>HKEY_LOCAL_MACHINE\software\Microsoft\office\12.0\registro</b></p>
<p>Una vez encontrada dicha entrada, debemos de buscar otra subentrada como esta:</p>
<p><b>HKEY_LOCAL_MACHINE\software\Microsoft\office\12.0\registro \ {90120000-0030-0000-0000-0000000FF1CE</b></p>
<p>O una como esta:</p>
<p><b>HKEY_LOCAL_MACHINE\software\Microsoft\office\12.0\registro \ {91120000-0011-0000-0000-0000000FF1CE</b></p>
<p>4. Debes de asegurarte que aparezca dentro de esas subentradas el nombre del producto del Office, como por ejemplo:</p>
<p><b>ProductName=Microsoft Office Professional Plus 2007<br />
ProductName=Microsoft Office Enterprise 2007</b></p>
<p>5. Una vez encontrada las algunas de las claves antes mencionadas, busca estas entradas del regedit y eliminalas:</p>
<p><b>DigitalProductID<br />
ProductID</b></p>
<p>Lo que hicimos fue borrar la clave del producto del Microsoft Office, ahora haremos que nunca más la pida:</p>
<p>6. Vamos a la carpeta de instalación del Microsoft Office 2007, que debe de estar en esta dirección:</p>
<p><b>C:\Archivos de programa\Archivos comunes\Microsoft Shared\OFFICE12\Office Setup Controller\Proof.es</b></p>
<p>También debemos hacerlo para la carpeta Proof.en, que es esta:</p>
<p><b>C:\Archivos de programa\Archivos comunes\Microsoft Shared\OFFICE12\Office Setup Controller\Proof.en</b></p>
<p>Buscamos el archivo: <b>proof.xml y lo abrimos con el Bloc de Notas.</b></p>
<p>Y editamos la penúltima línea:</p>
<p><b>&#60;Feature Id="SetupXmlFiles" Cost="1359"&#62;<br />
&#60;OptionRef Id="AlwaysInstalled"/&#62;<br />
&#60;/Feature&#62;</b></p>
<p>Le quitamos el AlwaysInstalled y le ponemos: neverInstalled. Debe de quedar algo así:</p>
<p><b>&#60;Feature Id="SetupXmlFiles" Cost="1359"&#62;<br />
&#60;OptionRef Id="neverInstalled"/&#62;<br />
&#60;/Feature&#62;</b></p>
<p>Fuente:http://www.luiskano.net/</p>
]]></content:encoded>
</item>
<item>
<title><![CDATA[Task Sequences - Explained]]></title>
<link>http://frontslash.wordpress.com/?p=10</link>
<pubDate>Thu, 31 Jan 2008 20:07:42 +0000</pubDate>
<dc:creator>Soultaker</dc:creator>
<guid>http://frontslash.wordpress.com/?p=10</guid>
<description><![CDATA[From who cames from Windows XP unattended installations, the new Vista deployment features mais seem]]></description>
<content:encoded><![CDATA[<p>From who cames from Windows XP unattended installations, the new Vista deployment features mais seem a little strange, confusing and scary! That happened to me...<br />
But, that was before having some readiness of the BDD 2007/Microsoft Deployment documents. Now I'm a little less confused.</p>
<p> One of the first things that made my head go around was the Task Sequencer. I've never worked with SMS but who did, told me it was something similar to what we call today Microsoft Deployment tools.</p>
<p>Now, here it's some info that I've extrated from <em>Deployment_Customization_Guide.doc </em>about the task sequences that are set by default when you install MS Deployment:</p>
<p style="margin:3pt 0;" class="Text">The Microsoft Deployment process occurs in phases that are defined in the TS.xml file. Task Sequencer parses the TS.xml file to identify the appropriate sequence for performing the deployment process. The phases defined in the TS.xml file include:</p>
<p style="margin:3pt 0;" class="Text"><font face="Times New Roman"><br />
</font><u><strong><span class="Bold">Validate Phase</span><br />
</strong></u>Performs validation checks to make sure that the operating system installation can proceed; specifically blocks installation on server operating systems.</p>
<p style="margin:3pt 0;" class="Text"><span class="Bold"><u><strong>State Capture Phase<br />
</strong></u></span>Gathers information from the configuration file, databases, and the local machine to determine how the image installation process should proceed, including whether there is enough space to do a local USMT state backup. The scripts also invoke the USMT Scanstate.exe command as appropriate.</p>
<p style="margin:3pt 0;" class="Text"><span class="Bold"><strong><u>Preinstall Phase</u></strong></span><br />
Confirms that the necessary information has been gathered in the State Capture Phase for the Refresh Computer and Upgrade Computer scenarios. In the New Computer and Replace Computer scenarios, the script gathers the necessary information in this phase because these scenarios do not perform the State Capture Phase. Also, a backup of the computer can be optionally performed for the Refresh Computer and Upgrade Computer scenarios.</p>
<p><span class="Bold"><u><strong>Install Phase<br />
</strong></u></span>Installs the target operating system on the target computers.</p>
<p><span class="Bold"><strong><u>Post Install Phase</u></strong></span><br />
Updates the Sysprep.inf file, Sysprep.xml file, or Unattend.txt file with information gathered in the previous custom actions based on the operating system being deployed.</p>
<p><span class="Bold"><strong><u>State Restore Phase<br />
</u></strong></span>Invokes the USMT Loadstate.exe command to restore the user state that was previously backed up.</p>
]]></content:encoded>
</item>

</channel>
</rss>
