<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
    <channel>
        <title>[MOD] Placeholder v1.0.0</title>
        <description> Sphider v1.3.5 Modification
---------------------------

Name And Version
----------------

[MOD] Placeholder v1.0.0
 
Description
-----------

This mod will add a placeholder to your search box. and be removed 
when it loses focus.

01. replace the following code from search_form.html with the code from code1.txt

&amp;lt;input type=&amp;quot;text&amp;quot; name=&amp;quot;query&amp;quot; id=&amp;quot;query&amp;quot; size=&amp;quot;40&amp;quot; value=&amp;quot;&amp;lt;?  print quote_replace($query);?&amp;gt;&amp;quot; action=&amp;quot;include/js_suggest/suggest.php&amp;quot; columns=&amp;quot;2&amp;quot; autocomplete=&amp;quot;off&amp;quot; delay=&amp;quot;1500&amp;quot;&amp;gt;	 

02. Add the code from code2.txt to the header file. Somewhere between &amp;lt;head&amp;gt; AND &amp;lt;/head&amp;gt;

03. Copy placeholder.js to the include folder.

CODE1.TXT


&amp;lt;input type=&amp;quot;text&amp;quot; name=&amp;quot;query&amp;quot; id=&amp;quot;query&amp;quot; size=&amp;quot;40&amp;quot; value=&amp;quot;&amp;lt;?php print quote_replace($query);?&amp;gt;&amp;quot; action=&amp;quot;include/js_suggest/suggest.php&amp;quot; columns=&amp;quot;2&amp;quot; autocomplete=&amp;quot;off&amp;quot; delay=&amp;quot;1500&amp;quot; placeholder=&amp;quot;Search&amp;quot; onfocus=&amp;quot;cph(this.id);&amp;quot; onblur=&amp;quot;aph(this.id);&amp;quot;&amp;gt;

CODE2.TXT


&amp;lt;script language=&amp;quot;javascript&amp;quot; src=&amp;quot;include/placeholder.js&amp;quot; type=&amp;quot;text/javascript&amp;quot;&amp;gt;&amp;lt;/script&amp;gt;

PLACEHOLDER.JS


function aph(elID) {
    if(document.getElementById(elID)) {
        var el = document.getElementById(elID);
		console.log(el);
		var pH = el.getAttribute('placeholder');
		console.log(el.getAttribute('placeholder'));
        if(pH !== 'undefined' &amp;amp;&amp;amp; el.value == '') {
            el.value = pH;
            el.className += 'placeheld';
        }
    }
}
function cph(elID) {
    if(document.getElementById(elID)) {
        var el = document.getElementById(elID);
		console.log(el);
		var pH = el.getAttribute('placeholder');
        if(pH !== 'undefined' &amp;amp;&amp;amp; el.value == pH) {
            el.value = '';
            el.className = el.className.replace('placeheld','');
        }
    }
}
var myElIDs = ['myinput','myinput2'];
console.log(myElIDs);
for(var i in myElIDs) {
    if(document.getElementById(myElIDs)) {
		console.log(document.getElementById(myElIDs));
		aph(myElIDs);
    }
}


By David Sierowski</description>
        <link>http://www.sphider.eu/forum/read.php?3,9411,9411#msg-9411</link>
        <lastBuildDate>Wed, 19 Jun 2013 09:35:56 +0300</lastBuildDate>
        <generator>Phorum 5.2.10</generator>
        <item>
            <guid>http://www.sphider.eu/forum/read.php?3,9411,9411#msg-9411</guid>
            <title>[MOD] Placeholder v1.0.0</title>
            <link>http://www.sphider.eu/forum/read.php?3,9411,9411#msg-9411</link>
            <description><![CDATA[ Sphider v1.3.5 Modification<br />
---------------------------<br />
<br />
Name And Version<br />
----------------<br />
<br />
[MOD] Placeholder v1.0.0<br />
 <br />
Description<br />
-----------<br />
<br />
This mod will add a placeholder to your search box. and be removed <br />
when it loses focus.<br />
<br />
01. replace the following code from search_form.html with the code from code1.txt<br />
<br />
&lt;input type=&quot;text&quot; name=&quot;query&quot; id=&quot;query&quot; size=&quot;40&quot; value=&quot;&lt;?  print quote_replace($query);?&gt;&quot; action=&quot;include/js_suggest/suggest.php&quot; columns=&quot;2&quot; autocomplete=&quot;off&quot; delay=&quot;1500&quot;&gt;	 <br />
<br />
02. Add the code from code2.txt to the header file. Somewhere between &lt;head&gt; AND &lt;/head&gt;<br />
<br />
03. Copy placeholder.js to the include folder.<br />
<br />
CODE1.TXT<br />
<br />
<pre class="bbcode">
&lt;input type=&quot;text&quot; name=&quot;query&quot; id=&quot;query&quot; size=&quot;40&quot; value=&quot;&lt;?php print quote_replace($query);?&gt;&quot; action=&quot;include/js_suggest/suggest.php&quot; columns=&quot;2&quot; autocomplete=&quot;off&quot; delay=&quot;1500&quot; placeholder=&quot;Search&quot; onfocus=&quot;cph(this.id);&quot; onblur=&quot;aph(this.id);&quot;&gt;</pre>
<br />
CODE2.TXT<br />
<br />
<pre class="bbcode">
&lt;script language=&quot;javascript&quot; src=&quot;include/placeholder.js&quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;</pre>
<br />
PLACEHOLDER.JS<br />
<br />
<pre class="bbcode">
function aph(elID) {
    if(document.getElementById(elID)) {
        var el = document.getElementById(elID);
		console.log(el);
		var pH = el.getAttribute('placeholder');
		console.log(el.getAttribute('placeholder'));
        if(pH !== 'undefined' &amp;&amp; el.value == '') {
            el.value = pH;
            el.className += 'placeheld';
        }
    }
}
function cph(elID) {
    if(document.getElementById(elID)) {
        var el = document.getElementById(elID);
		console.log(el);
		var pH = el.getAttribute('placeholder');
        if(pH !== 'undefined' &amp;&amp; el.value == pH) {
            el.value = '';
            el.className = el.className.replace('placeheld','');
        }
    }
}
var myElIDs = ['myinput','myinput2'];
console.log(myElIDs);
for(var i in myElIDs) {
    if(document.getElementById(myElIDs<i>)) {
		console.log(document.getElementById(myElIDs<i>));
		aph(myElIDs<i>);
    }
}
</i></i></i></pre>
<br />
By David Sierowski]]></description>
            <dc:creator>Sierowski</dc:creator>
            <category>Sphider Mods</category>
            <pubDate>Sun, 13 May 2012 20:39:16 +0300</pubDate>
        </item>
    </channel>
</rss>
