<?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/"
	>

<channel>
	<title>ILuvJohn</title>
	<atom:link href="http://iluvjohn.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://iluvjohn.com</link>
	<description>Everything Cool</description>
	<lastBuildDate>Wed, 01 Sep 2010 22:18:24 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Disable Link with Javscript and CSS</title>
		<link>http://iluvjohn.com/knowledge-database/computers/general-cross-platform/web-internet/php-mysql-curl/disable-link-javscript-css-786/</link>
		<comments>http://iluvjohn.com/knowledge-database/computers/general-cross-platform/web-internet/php-mysql-curl/disable-link-javscript-css-786/#comments</comments>
		<pubDate>Wed, 01 Sep 2010 22:15:13 +0000</pubDate>
		<dc:creator>SiteTracker</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[JavaScript / JS]]></category>
		<category><![CDATA[PHP MySQL Curl]]></category>
		<category><![CDATA[a]]></category>
		<category><![CDATA[bubble tooltips]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[disable]]></category>
		<category><![CDATA[disable link]]></category>
		<category><![CDATA[href]]></category>
		<category><![CDATA[js]]></category>
		<category><![CDATA[link]]></category>
		<category><![CDATA[make link not clickable]]></category>
		<category><![CDATA[title]]></category>

		<guid isPermaLink="false">http://iluvjohn.com/?p=786</guid>
		<description><![CDATA[I was using a Bubble Tool Tips script on a project to display description info when the mouse rolled over the title of an item pulled from the database. The problem is that the Bubble Tool Tip I was using only worked when used in links (a tag with href=&#8221;something&#8221; and title=&#8221;something&#8221;). So to get [...]]]></description>
			<content:encoded><![CDATA[<p>I was using a Bubble Tool Tips script on a project to display description info when the mouse rolled over the title of an item pulled from the database. The problem is that the Bubble Tool Tip I was using only worked when used in links (a tag with href=&#8221;something&#8221; and title=&#8221;something&#8221;). So to get around this, I need to do two things A) Style the link to look like text, and B) Disable the link from doing anything when you click it.</p>
<p>So here is how you can do it yourself:</p>
<p>For the css I decided to use a class of bubble in the link (See Below). The CSS I included in my default style.css as follows:</p>
<pre><code>.bubble{
text-decoration:none;
color:#000000;
cursor:default;
}</code></pre>
<p>I&#8217;m not really a JavaScript coder, I just started learning about it in any kind of detail last week or so. I do remember reading something along the lines of <strong>onclick=&#8221;someFunction(); return false;&#8221;</strong> though. Sure enough, just having the &#8220;<strong>return false;</strong>&#8221; is enough to start the link from even reloading the page when clicked.</p>
<p>So my link looks like this:</p>
<pre><code>&lt;a </code><code>href="#"</code><code> title="Description of Item For Tool Tip" class="bubble" onclick="return false;"&gt;Link Text&lt;/a&gt;
</code></pre>
<p>This in effect makes the text between an &lt;a&gt; &amp; &lt;/a&gt;tag appear normal. Ultimately, no matter how you dress it up the browse is always going to see it as a link. When you mouse over it, you may still see a url in your browsers status bar, but clicking it will do nothing and it will appear just like all your other text.</p>
<p>Good luck with your programming endeavor!</p>
]]></content:encoded>
			<wfw:commentRss>http://iluvjohn.com/knowledge-database/computers/general-cross-platform/web-internet/php-mysql-curl/disable-link-javscript-css-786/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP, XML, CDATA &#8211; Adding file(s) / BLOB to CDATA in XML formatted document</title>
		<link>http://iluvjohn.com/knowledge-database/computers/general-cross-platform/web-internet/php-mysql-curl/php-xml-cdata-adding-files-blob-cdata-xml-formatted-document-783/</link>
		<comments>http://iluvjohn.com/knowledge-database/computers/general-cross-platform/web-internet/php-mysql-curl/php-xml-cdata-adding-files-blob-cdata-xml-formatted-document-783/#comments</comments>
		<pubDate>Wed, 01 Sep 2010 00:00:49 +0000</pubDate>
		<dc:creator>SiteTracker</dc:creator>
				<category><![CDATA[PHP MySQL Curl]]></category>
		<category><![CDATA[XPath]]></category>
		<category><![CDATA[base64_decode]]></category>
		<category><![CDATA[base64_encode]]></category>
		<category><![CDATA[CDATA]]></category>
		<category><![CDATA[file]]></category>
		<category><![CDATA[import]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[xml]]></category>
		<category><![CDATA[xml file]]></category>

		<guid isPermaLink="false">http://iluvjohn.com/?p=783</guid>
		<description><![CDATA[I have a project in which the user may import and export their profile data.  I decided that I would like to try XML as the structure I use to save information. The problem here is that I also have files I would like to save inside of the XML file &#8211; Pictures, Zip files [...]]]></description>
			<content:encoded><![CDATA[<p>I have a project in which the user may import and export their profile data.  I decided that I would like to try XML as the structure I use to save information. The problem here is that I also have files I would like to save inside of the XML file &#8211; Pictures, Zip files and text files.</p>
<p>I pulled file content from some files and placed it between the CDATA markers. This did not work. I though I had to find some &#8220;binary to something&#8221; converter. The good news is that you don&#8217;t need to find some converter, you use base64_encode, and base64_decode to encode or decode your file content.</p>
<p>For example, let&#8217;s assume that you have files in a mysql database. The column should be of &#8220;blob&#8221;, &#8220;longblob&#8221;, etc depending on how big of a file you are saving in the database. So here is an example of how to encode a file or other related data into an XML document:</p>
<pre><code>
&lt;?php
header("Content-Type: text/xml");
echo "&lt;?xml version=\"1.0\" encoding=\"UTF-8\" ?"."&gt;"; // XML document

$gd = mysql_query("SELECT * FROM contact_pictures WHERE pic_contactid='$contact_id'");
$cgd = mysql_num_rows($gd);
if($cgd &gt; 0){
while($agd = mysql_fetch_array($gd)){
extract($agd); // pic_id pic_contactid pic_title pic_caption pic_content pic_filename pic_filetype
echo "&lt;pictures type=\"".htmlspecialchars($pic_filetype)."\"&gt;\n";
echo "  &lt;title&gt;".htmlspecialchars($pic_title)."&lt;/title&gt;\n";
echo "  &lt;filename&gt;".htmlspecialchars($pic_filename)."&lt;/filename&gt;\n";
echo "  &lt;caption&gt;".htmlspecialchars($pic_caption)."&lt;/caption&gt;\n";
echo "  &lt;content&gt;&lt;![CDATA[".base64_encode($pic_content)."]]&gt;&lt;/content&gt;\n";
echo "&lt;/pictures&gt;\n\n";
}
}
echo "&lt;/profile&gt;\n";
}
?&gt;

</code></pre>
<p>If you notice the line:</p>
<p>echo &#8220;  &lt;content&gt;&lt;![CDATA[".base64_encode($pic_content)."]]&gt;&lt;/content&gt;\n&#8221;;</p>
<p>You can clearly see how to encode file content, weather from a database, file_get_contents, or CURL &#8211; They can all work with this the same way.</p>
<p>When you parse your XML Document (import), you will need to base64_decode, probably need to save the file name and/or file type and save it back to a file, or database, etc.</p>
<p>Goodluck!</p>
]]></content:encoded>
			<wfw:commentRss>http://iluvjohn.com/knowledge-database/computers/general-cross-platform/web-internet/php-mysql-curl/php-xml-cdata-adding-files-blob-cdata-xml-formatted-document-783/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Finally Learning Javascript</title>
		<link>http://iluvjohn.com/welcome-to-iluvjohn/finally-learning-javascript-780/</link>
		<comments>http://iluvjohn.com/welcome-to-iluvjohn/finally-learning-javascript-780/#comments</comments>
		<pubDate>Sat, 28 Aug 2010 06:34:36 +0000</pubDate>
		<dc:creator>SiteTracker</dc:creator>
				<category><![CDATA[Welcome To ILuvJohn]]></category>

		<guid isPermaLink="false">http://iluvjohn.com/?p=780</guid>
		<description><![CDATA[It is only just recently that I have had an interest in Javascript, after running into that Animation Library. I decided it is time to just dive in and see what it can do and how it&#8217;s used. I jumped head first into W3C&#8217;s Introduction: Javascript.  Right away I found a familiar feel to it&#8217;s [...]]]></description>
			<content:encoded><![CDATA[<p>It is only just recently that I have had an interest in Javascript, after running into that Animation Library. I decided it is time to just dive in and see what it can do and how it&#8217;s used. I jumped head first into <a title="http://www.w3schools.com/js/default.asp" href="http://www.w3schools.com/js/default.asp" target="_blank">W3C&#8217;s Introduction: Javascript</a>.  Right away I found a familiar feel to it&#8217;s structure in declaring and executing functions, and a quickly recognized 90% of the javascript I had seen in so many other websites  before&#8230;.But now I got to see what all the different functions did!</p>
<p>My first order of business was to add some spunk to an HTML / PHP form. I wanted the value of selected option to place itself into the next &lt;input type=&#8221;text&#8221;[...] /&gt; tag. I finally figured it out, though it is not quite how I want it, it will suffice for now. I am thinking I might give JQuery / Ajax a go over next and see if they can better assist my needs.</p>
<p>So anyways, I just wanted to share: I&#8217;m leaning Javascript.</p>
<p>Hazza!</p>
]]></content:encoded>
			<wfw:commentRss>http://iluvjohn.com/welcome-to-iluvjohn/finally-learning-javascript-780/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
