<?xml version="1.0" encoding="ISO-8859-1"?>

<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
	<channel>
		<title>CodingForums.com</title>
		<link>http://www.codingforums.com/</link>
		<description>Web coding and development forums. Get help on JavaScript, PHP, CGI, CSS, XML, and more.</description>
		<language>en</language>
		<lastBuildDate>Mon, 20 May 2013 04:58:45 GMT</lastBuildDate>
		<generator>vBulletin</generator>
		<ttl>60</ttl>
		<image>
			<url>http://www.codingforums.com/images/misc/rss.jpg</url>
			<title>CodingForums.com</title>
			<link>http://www.codingforums.com/</link>
		</image>
		<item>
			<title>How to get difference time ?</title>
			<link>http://www.codingforums.com/showthread.php?t=295618&amp;goto=newpost</link>
			<pubDate>Mon, 20 May 2013 04:12:06 GMT</pubDate>
			<description><![CDATA[Hi thanks to all... 
 
I have 3 variables ;  
1 is $date  = (dd-mm-yy) 
2nd is $time  = (H:i) 
 
3rd 1 $today = date('Y-m-d H:i') ; 
 
my question is how to get difference time (in minutes) between $today - $date $time ?]]></description>
			<content:encoded><![CDATA[<div>Hi thanks to all...<br />
<br />
I have 3 variables ; <br />
1 is $date  = (dd-mm-yy)<br />
2nd is $time  = (H:i)<br />
<br />
3rd 1 $today = date('Y-m-d H:i') ;<br />
<br />
my question is how to get difference time (in minutes) between $today - $date $time ?<br />
<br />
I try this, but not get correct answer :<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">PHP Code:</div>
	<div class="alt2">
		<hr />
		<code style="white-space:nowrap">
		<div dir="ltr" style="text-align:left;">
			<!-- php buffer start --><code><span style="color: #000000">
<span style="color: #0000BB">$time_me&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">$time&nbsp;</span><span style="color: #007700">;&nbsp;&nbsp;<br /></span><span style="color: #0000BB">$time_me&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">explode</span><span style="color: #007700">(</span><span style="color: #DD0000">":"</span><span style="color: #007700">,</span><span style="color: #0000BB">$time_me</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$date_me&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">$date&nbsp;</span><span style="color: #007700">;<br /></span><span style="color: #0000BB">$date_me&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">explode</span><span style="color: #007700">(</span><span style="color: #DD0000">"-"</span><span style="color: #007700">,</span><span style="color: #0000BB">$date_me</span><span style="color: #007700">);&nbsp;<br /></span><span style="color: #0000BB">$target&nbsp;</span><span style="color: #007700">=&nbsp;&nbsp;</span><span style="color: #0000BB">mktime</span><span style="color: #007700">(</span><span style="color: #0000BB">$time_me</span><span style="color: #007700">&#91;</span><span style="color: #0000BB">0</span><span style="color: #007700">&#93;,&nbsp;</span><span style="color: #0000BB">$time_me</span><span style="color: #007700">&#91;</span><span style="color: #0000BB">1</span><span style="color: #007700">&#93;,&nbsp;</span><span style="color: #0000BB">$date_me</span><span style="color: #007700">&#91;</span><span style="color: #0000BB">1</span><span style="color: #007700">&#93;,&nbsp;</span><span style="color: #0000BB">$date_me</span><span style="color: #007700">&#91;</span><span style="color: #0000BB">2</span><span style="color: #007700">&#93;,&nbsp;</span><span style="color: #0000BB">$date_me</span><span style="color: #007700">&#91;</span><span style="color: #0000BB">0</span><span style="color: #007700">&#93;)&nbsp;;<br /><br /></span><span style="color: #0000BB">$today&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">date</span><span style="color: #007700">(</span><span style="color: #DD0000">'Y-m-d&nbsp;H:i'</span><span style="color: #007700">)&nbsp;;<br /><br /></span><span style="color: #0000BB">$difference&nbsp;</span><span style="color: #007700">=(</span><span style="color: #0000BB">$today</span><span style="color: #007700">-</span><span style="color: #0000BB">$target</span><span style="color: #007700">)&nbsp;;<br /><br />print&nbsp;</span><span style="color: #0000BB">$minuts&nbsp;</span><span style="color: #007700">=&nbsp;(int)&nbsp;(</span><span style="color: #0000BB">$difference</span><span style="color: #007700">/</span><span style="color: #0000BB">60</span><span style="color: #007700">);&nbsp;<br /></span><span style="color: #0000BB"></span>
</span>
</code><!-- php buffer end -->
		</div>
		</code>
		<hr />
	</div>
</div>please help me</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=6">PHP</category>
			<dc:creator>pisumathu</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295618</guid>
		</item>
		<item>
			<title>using PHP variable in javascript</title>
			<link>http://www.codingforums.com/showthread.php?t=295617&amp;goto=newpost</link>
			<pubDate>Mon, 20 May 2013 03:57:14 GMT</pubDate>
			<description><![CDATA[I want to show a PHP variable then I create a button and if click it, the PHP variable will be showed 
 
Code: 
--------- 
<input type="button" value='show a PHP variable'; style="width:200px;" onClick="echoVar()";> 
 
<script type="text/javascript"> 
 
var phpVar = ???????????? <---------------...]]></description>
			<content:encoded><![CDATA[<div>I want to show a PHP variable then I create a button and if click it, the PHP variable will be showed<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left">&lt;input type=&quot;button&quot; value='show a PHP variable'; style=&quot;width:200px;&quot; onClick=&quot;echoVar()&quot;;&gt;<br />
<br />
&lt;script type=&quot;text/javascript&quot;&gt;<br />
<br />
var phpVar = ???????????? &lt;--------------- please help me here<br />
<br />
function echoVar()<br />
{<br />
&nbsp;alert(phpVar);<br />
&nbsp;}<br />
&lt;/script&gt;</code><hr />
</div>The varaiable I want to show is a global variable in PHP. How can I get it and use in this javascript?<br />
Thanks for any help</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=2">JavaScript programming</category>
			<dc:creator>docco</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295617</guid>
		</item>
		<item>
			<title><![CDATA["Unterminated string constant" error in IE10]]></title>
			<link>http://www.codingforums.com/showthread.php?t=295616&amp;goto=newpost</link>
			<pubDate>Mon, 20 May 2013 02:34:06 GMT</pubDate>
			<description>Hello, can somebody help error with unterminated string constant., its only happen in ie10, not in firefox or chrome.</description>
			<content:encoded><![CDATA[<div>Hello, can somebody help error with unterminated string constant., its only happen in ie10, not in firefox or chrome.</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=2">JavaScript programming</category>
			<dc:creator>mrzell</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295616</guid>
		</item>
		<item>
			<title>simplify assignment of variables</title>
			<link>http://www.codingforums.com/showthread.php?t=295615&amp;goto=newpost</link>
			<pubDate>Mon, 20 May 2013 01:49:21 GMT</pubDate>
			<description>There are five sets of text data in variables named in the following pattern: 
var1_1 
var1_2 
... 
var1_5 
 
var2_1 
... 
... 
var5_5</description>
			<content:encoded><![CDATA[<div>There are five sets of text data in variables named in the following pattern:<br />
var1_1<br />
var1_2<br />
...<br />
var1_5<br />
<br />
var2_1<br />
...<br />
...<br />
var5_5<br />
<br />
depending on which of  five radiobuttons is checked, variables chosen1...chosen5 should be assigned the data from one of the five sets.<br />
<br />
Is there a way to simplify this process, rathen than<br />
<br />
if radiobu1 checked then chosen1=var1_1 chosen2=var1_2<br />
etc</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=2">JavaScript programming</category>
			<dc:creator>eydg</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295615</guid>
		</item>
		<item>
			<title>How to contact someone here privately.</title>
			<link>http://www.codingforums.com/showthread.php?t=295613&amp;goto=newpost</link>
			<pubDate>Mon, 20 May 2013 00:41:23 GMT</pubDate>
			<description><![CDATA[How do I contact someone here privately. I know who I want to contact. But don't see the IM in there profile.]]></description>
			<content:encoded><![CDATA[<div>How do I contact someone here privately. I know who I want to contact. But don't see the IM in there profile.</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=13"><![CDATA[HTML & CSS]]></category>
			<dc:creator>charisma44</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295613</guid>
		</item>
		<item>
			<title>Cross Page Bar</title>
			<link>http://www.codingforums.com/showthread.php?t=295612&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 23:09:52 GMT</pubDate>
			<description><![CDATA[I've used html and css for some time now (off and on), dabbled in javascript and jquery for dynamic page loads, menus, etc, and use php as much as possible, but I'm kind of lost on what the best way to implement this and how. 
 
Basically I want a bar that will have things like info along with...]]></description>
			<content:encoded><![CDATA[<div>I've used html and css for some time now (off and on), dabbled in javascript and jquery for dynamic page loads, menus, etc, and use php as much as possible, but I'm kind of lost on what the best way to implement this and how.<br />
<br />
Basically I want a bar that will have things like info along with music and a chat bar. The chat bar is something I will learn later, but it all needs to be cross page, which I may be saying wrong and mean that the music needs to consistently play without reloading on every page on my site. With a chat (similar to facebook but not exactly) in mind, what is the best way to implement the music on this bar? Is a frame the best idea, and if so, how (in the most general sense) should it be implemented? Yes, I don't know much on this, that's why I'm asking so I can learn how through research and trial and error and do it. <br />
<br />
Again, if a frame will end up making the chat worse in the end, what is another way to do this? Also how to do it either way said.<br />
<br />
Thanks in advance. Any documents to point me to to read more on what you say to understand better is also appreciated.</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=2">JavaScript programming</category>
			<dc:creator>gkjr1</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295612</guid>
		</item>
		<item>
			<title>RoCanvas drawing board</title>
			<link>http://www.codingforums.com/showthread.php?t=295611&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 22:26:24 GMT</pubDate>
			<description><![CDATA[Hi 
 
i wanted to have a mini drawing board on my website for fun, and let visitors draw a pic that will remain there until the next person clears it or adds to it. 
 
I got the .zip files and extracted. 
I added the html into my html page 
 
I added the folder which contains the .css & .js 
 
The...]]></description>
			<content:encoded><![CDATA[<div>Hi<br />
<br />
i wanted to have a mini drawing board on my website for fun, and let visitors draw a pic that will remain there until the next person clears it or adds to it.<br />
<br />
I got the .zip files and extracted.<br />
I added the html into my html page<br />
<br />
I added the folder which contains the .css &amp; .js<br />
<br />
The drawing board appears as i want it to.<br />
<br />
BUT as you can guess, the 'save' button does nothing.<br />
<br />
I am at a basic beginners level of programming, but have some understanding.<br />
<br />
Can you guide me on what to do to get the save function to work please?<br />
<br />
Here is the link to my page so you can see what ive done (and any mistakes)<br />
<a href="http://www.blutideweb.webspace.virgi...m/gallery.html" target="_blank">http://www.blutideweb.webspace.virgi...m/gallery.html</a><br />
<br />
I would be ever so grateful.<br />
<br />
Regards<br />
<br />
Paul.</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=2">JavaScript programming</category>
			<dc:creator>paulypj</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295611</guid>
		</item>
		<item>
			<title>Need Help on Loading Data in HTML Choose Your Own Adventure Game</title>
			<link>http://www.codingforums.com/showthread.php?t=295610&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 21:52:41 GMT</pubDate>
			<description><![CDATA[Well I am trying to make a Choose Your Own Adventure Game in HTML(with JS) and I currently have a save function which works pretty well, you make a character (race, name, and gender), it saves a text file with the race, name and gender written inside the .txt file named "Character_<name>.txt", what...]]></description>
			<content:encoded><![CDATA[<div>Well I am trying to make a Choose Your Own Adventure Game in HTML(with JS) and I currently have a save function which works pretty well, you make a character (race, name, and gender), it saves a text file with the race, name and gender written inside the .txt file named &quot;Character_&lt;name&gt;.txt&quot;, what I want to do is save the file, then when you hit load it opens a File Input and you search for the file and open it up. &lt;-- That's where I am at.<br />
<br />
But I do not know what to do after that... I would like it to read the file and extract the data. Maybe it would be better if it was XML not a text file. But I do not know how to save those files.<br />
<br />
So if anyone can help me, you will get a spot in the game's credits when it is done.<br />
<br />
P.S. It is going to be a downloaded game, not a Server hosted game, so all the stuff is client side, not server side.</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=13"><![CDATA[HTML & CSS]]></category>
			<dc:creator>RickChavez</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295610</guid>
		</item>
		<item>
			<title>How to Loop through Records to Display Data?</title>
			<link>http://www.codingforums.com/showthread.php?t=295609&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 21:45:54 GMT</pubDate>
			<description>Okay, I feel embarrassed asking this question, because it seems like it should NOT be so confusing, but here goes... 
 
 
I have joined together several tables in my database to get this resultant Data Set... 
 
Code: 
--------- 
Dimension		SubSection 
----------		----------- 
Business...</description>
			<content:encoded><![CDATA[<div>Okay, I feel embarrassed asking this question, because it seems like it should NOT be so confusing, but here goes...<br />
<br />
<br />
I have joined together several tables in my database to get this resultant Data Set...<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left">Dimension&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; SubSection<br />
----------&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; -----------<br />
Business Structure&nbsp; &nbsp; &nbsp; &nbsp; Sole Proprietorship<br />
Business Structure&nbsp; &nbsp; &nbsp; &nbsp; Partnership<br />
Business Structure&nbsp; &nbsp; &nbsp; &nbsp; LLC<br />
Business Structure&nbsp; &nbsp; &nbsp; &nbsp; S-Corp<br />
Business Structure&nbsp; &nbsp; &nbsp; &nbsp; C-Corp<br />
Store Type&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Brick &amp; Mortar<br />
Store Type&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Online<br />
Store Type&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Hybrid<br />
Offering&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Products<br />
Offering&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Services<br />
Offering&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Full Service<br />
Accounting&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Bookkeeping<br />
Accounting&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Payroll<br />
Accounting&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Taxes<br />
Seasonal&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Tax Season</code><hr />
</div><br />
On my website's &quot;Section Landing Page&quot;, I am looking to take this data, and create a series of &quot;Boxes&quot; stacked on top of each other in the right margin like this...<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left"><b>Business Structure:</b><br />
&nbsp; &nbsp; Sole Proprietorship<br />
&nbsp; &nbsp; Partnership<br />
&nbsp; &nbsp; LLC<br />
&nbsp; &nbsp; S-Corp<br />
&nbsp; &nbsp; C-Corp</code><hr />
</div><div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left"><b>Store Type:</b><br />
&nbsp; &nbsp; Brick &amp; Mortar<br />
&nbsp; &nbsp; Online<br />
&nbsp; &nbsp; Hybrid</code><hr />
</div><div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left"><b>Offering:</b><br />
&nbsp; &nbsp; Products<br />
&nbsp; &nbsp; Services<br />
&nbsp; &nbsp; Full Service</code><hr />
</div><div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left"><b>Seasonal:</b><br />
&nbsp; &nbsp; Tax Season</code><hr />
</div><br />
<b>What is the best way to use PHP to take the Data Set mentioned and get the desired Output above??</b><br />
<br />
<br />
(BTW, maybe joining all of those table together wasn't the best approach?!  I just figured it would be better to have ONE QUERY, than a series of queries...)<br />
<br />
Hope all of this makes sense?!  :o<br />
<br />
Sincerely,<br />
<br />
<br />
Debbie</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=6">PHP</category>
			<dc:creator>doubledee</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295609</guid>
		</item>
		<item>
			<title>Javascript Crystal Ball</title>
			<link>http://www.codingforums.com/showthread.php?t=295608&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 21:40:29 GMT</pubDate>
			<description><![CDATA[Hello, 
I am trying to find some help here. This script opens a new window after clicking the 'Ask Me' button. This is a two part question - first, I want to center the forms. See attachment to align with the rest of the lettering. Or just center. 
 
 Second, I would like the "answer" to appear in...]]></description>
			<content:encoded><![CDATA[<div>Hello,<br />
I am trying to find some help here. This script opens a new window after clicking the 'Ask Me' button. This is a two part question - first, I want to center the forms. See attachment to align with the rest of the lettering. Or just center.<br />
<br />
 Second, I would like the &quot;answer&quot; to appear in the box with my current  script, perhaps just below the &quot;question&quot; form - not in a  new window. Sort of like this script <a href="http://www.mysticalball.com" target="_blank">http://www.mysticalball.com</a>  here is the link to my actual script and page <a href="http://www.sphynxlair.com/crystal%20ball.php" target="_blank">http://www.sphynxlair.com/crystal%20ball.php</a><br />
<br />
Any help would be appreciated.<br />
<br />
-Tom<br />
<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left">&lt;table border=&quot;0&quot; bgcolor=&quot;#000000&quot; cellspacing=&quot;0&quot; cellpadding=&quot;3&quot;&gt;<br />
&nbsp; &lt;tr&gt;<br />
&nbsp; &nbsp; &lt;td width=&quot;100%&quot;&gt;<br />
&lt;img src=&quot;http://www.sphynxlair.com/images/Crystal Ball.png&quot; border=&quot;0&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;<br />
&lt;center&gt;&lt;img src=&quot;http://www.sphynxlair.com/images/crystalball.gif&quot; border=&quot;0&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;/center&gt;<br />
&lt;img src=&quot;http://www.sphynxlair.com/images/yes.png&quot; border=&quot;0&quot; alt=&quot;&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;<br />
&lt;form name=&quot;input1&quot;&gt;<br />
&lt;input name=&quot;textfield&quot; size=63&gt;<br />
&lt;/form&gt;&lt;br /&gt;<br />
&lt;form&gt;<br />
&lt;input type=&quot;button&quot; name=&quot;button1&quot; value=&quot;Ask Me!&quot;<br />
onClick=&quot;getAnswers()&quot;&gt;<br />
&lt;/form&gt;<br />
&lt;/td&gt;<br />
&lt;/tr&gt;<br />
&lt;/table&gt;<br />
&lt;script language=&quot;JavaScript&quot;&gt;<br />
function getAnswers() {<br />
time = new Date()<br />
randominteger = time.getSeconds()<br />
if (document.input1.textfield.value == &quot;&quot;) { <br />
alert(&quot;You didn't enter anything into the Crystal Ball!!!&quot;)<br />
return<br />
}<br />
if (randominteger &lt;= 3) answer=&quot;Did you really think so? Hahaha, I'm laughing now at your pitiful chances.&quot;<br />
if ((randominteger &gt;= 4) &amp;&amp; (randominteger &lt;= 6)) answer =&quot;Yeah, it it's got a 65% chance of happening.&quot;<br />
if ((randominteger &gt;= 7) &amp;&amp; (randominteger &lt;= 9)) answer =&quot;Oh come on! No way!&quot;<br />
if ((randominteger &gt;= 10) &amp;&amp; (randominteger &lt;= 12)) answer =&quot;As sure as I'm made of glass, this is likely to happen.&quot;<br />
if ((randominteger &gt;= 13) &amp;&amp; (randominteger &lt;= 15)) answer =&quot;Why are you asking A CRYSTAL BALL? Do you really believe the answers?&quot;<br />
if ((randominteger &gt;= 16) &amp;&amp; (randominteger &lt;= 18)) answer =&quot;Give me a break, give me a break, break me off a piece of that NO!&quot;<br />
if ((randominteger &gt;= 19) &amp;&amp; (randominteger &lt;= 21)) answer =&quot;Good chances lie on the horizon.&quot;<br />
if ((randominteger &gt;= 22) &amp;&amp; (randominteger &lt;= 24)) answer =&quot;Ask me again, I am restless and overworked.&quot;<br />
if ((randominteger &gt;= 25) &amp;&amp; (randominteger &lt;= 27)) answer =&quot;Do you know how the Crystal Ball works? There's your answer.&quot;<br />
if ((randominteger &gt;= 28) &amp;&amp; (randominteger &lt;= 30)) answer =&quot;As the sun is hot, your answer is YES.&quot;<br />
if ((randominteger &gt;= 31) &amp;&amp; (randominteger &lt;= 33)) answer =&quot;Did you get drunk last weekend? There's your answer.&quot;<br />
if ((randominteger &gt;= 34) &amp;&amp; (randominteger &lt;= 36)) answer =&quot;Forget about it&quot;<br />
if ((randominteger &gt;= 37) &amp;&amp; (randominteger &lt;= 39)) answer =&quot;Yeah, it could happen. 80% chance.&quot;<br />
if ((randominteger &gt;= 40) &amp;&amp; (randominteger &lt;= 42)) answer =&quot;Hitler has a better chance of raising from the dead.&quot;<br />
if ((randominteger &gt;= 43) &amp;&amp; (randominteger &lt;= 45)) answer =&quot;If you really think so, then it shall be.&quot;<br />
if ((randominteger &gt;= 46) &amp;&amp; (randominteger &lt;= 48)) answer =&quot;Who said ambiguous answers were bad? Not me, so YES!&quot;<br />
if ((randominteger &gt;= 49) &amp;&amp; (randominteger &lt;= 51)) answer =&quot;You think I'm going to answer that after a day of hard work? Ask again later.&quot;<br />
if ((randominteger &gt;= 52) &amp;&amp; (randominteger &lt;= 54)) answer =&quot;If you own a pet, yes. Otherwise, no.&quot;<br />
if ((randominteger &gt;= 55) &amp;&amp; (randominteger &lt;= 57)) answer =&quot;The sun will rise in the east and set in the west. Thank you Captain Obvious. YES!&quot;<br />
if ((randominteger &gt;= 58) &amp;&amp; (randominteger &lt;= 60)) answer =&quot;I'm laughing hard, very hard. You'd better ask again.&quot;<br />
<br />
var newWindow = window.open(&quot;&quot;,&quot;Results&quot;,&quot;width=300,height=300&quot;)<br />
newWindow.document.write(&quot;&lt;html&gt;&lt;body bgcolor='#000000' text='#FFFFCC' link='#00FFFF' alink='#000066' vlink='#6666FF'&gt;&quot;)<br />
newWindow.document.write(&quot;&lt;P align='center'&gt;Your Question:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&quot;)<br />
newWindow.document.write(&quot;&lt;P align='center'&gt;&quot; + document.input1.textfield.value + &quot;&lt;/P&gt;&quot;)<br />
newWindow.document.write(&quot;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P align='center'&gt;The Great Crystal Ball Has Answered:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&quot;)<br />
newWindow.document.write(&quot;&quot;)<br />
newWindow.document.write(&quot;&lt;P align='center'&gt;&quot; + answer + &quot;&lt;/P&gt;&quot;)<br />
newWindow.document.write(&quot;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P align='center'&gt;&lt;A HREF='javascript<b></b>:window.close()'&gt;Close Me&lt;/A&gt;&lt;/P&gt;&quot;)<br />
}<br />
<br />
&lt;/script&gt;<br />
<br />
&lt;/tbody&gt;<br />
&lt;/table&gt;</code><hr />
</div></div>


	<br />
	<div style="padding:6px">

	
		<fieldset class="fieldset">
			<legend>Attached Thumbnails</legend>
			<div style="padding:3px">
			
<a href="http://www.codingforums.com/attachment.php?attachmentid=12121&amp;d=1368999541" rel="Lightbox_1336503" id="attachment12121" target="_blank"><img class="thumbnail" src="http://www.codingforums.com/attachment.php?attachmentid=12121&amp;stc=1&amp;thumb=1&amp;d=1368999541" border="0" alt="Click image for larger version

Name:	Screen Shot 2013-05-19 at 5.38.39 PM.jpg
Views:	N/A
Size:	38.9 KB
ID:	12121" /></a>
&nbsp;

			</div>
		</fieldset>
	

	

	

	

	</div>
]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=2">JavaScript programming</category>
			<dc:creator>tommydamic68</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295608</guid>
		</item>
		<item>
			<title>Problem with some bugs I have found</title>
			<link>http://www.codingforums.com/showthread.php?t=295607&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 21:39:45 GMT</pubDate>
			<description>Hi guys, 
 
I need your help. When I hired the PHP devloper, he created the list of code in my php which it seem to be a bit of mess. I have found some bugs that I need to get it fixing it asap.  
 
When I pressed on the keyboard right arrow button which it start to fire, I can see the first block...</description>
			<content:encoded><![CDATA[<div>Hi guys,<br />
<br />
I need your help. When I hired the PHP devloper, he created the list of code in my php which it seem to be a bit of mess. I have found some bugs that I need to get it fixing it asap. <br />
<br />
When I pressed on the keyboard right arrow button which it start to fire, I can see the first block start to change to blue from yellow and the next block will change from blue to yellow. When I pressed the right arrow button on the big block, it will move to the next page which it supposed to be stay on the first page. I believe the problem is somewhere in javascript.<br />
<br />
After when I pressed on the keyboard right arrow button on the big block, i pressed on the left arrow button of the keyboard, I can see that I will not be able to go back to the first page. This is only work on the small block.<br />
<br />
There is a missing text after when I pressed on the keyboard right arrow button on the big block, and the block size is come next to the channel blocks which it supposed to be get separate. I want to make them to get seperate. You will see it in the picture blockbugs.jpg.<br />
<br />
Here is the code:<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">PHP Code:</div>
	<div class="alt2">
		<hr />
		<code style="white-space:nowrap">
		<div dir="ltr" style="text-align:left;">
			<!-- php buffer start --><code><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #007700">&lt;!</span><span style="color: #0000BB">DOCTYPE&nbsp;html&nbsp;</span><span style="color: #007700">PUBLIC</span><span style="color: #DD0000">"-//W3C//DTD&nbsp;XHTML&nbsp;1.0&nbsp;Strict//EN"<br />"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"</span><span style="color: #007700">&gt;<br />&lt;</span><span style="color: #0000BB">html&nbsp;xmlns</span><span style="color: #007700">=</span><span style="color: #DD0000">"http://www.w3.org/1999/xhtml"</span><span style="color: #007700">&gt;<br />&lt;</span><span style="color: #0000BB">head</span><span style="color: #007700">&gt;<br />&lt;</span><span style="color: #0000BB">meta&nbsp;http</span><span style="color: #007700">-</span><span style="color: #0000BB">equiv</span><span style="color: #007700">=</span><span style="color: #DD0000">"content-type"&nbsp;</span><span style="color: #0000BB">content</span><span style="color: #007700">=</span><span style="color: #DD0000">"text/html;&nbsp;charset=utf-8"&nbsp;</span><span style="color: #007700">/&gt;<br />&lt;</span><span style="color: #0000BB">script&nbsp;src</span><span style="color: #007700">=</span><span style="color: #DD0000">"http://code.jquery.com/jquery-1.9.1.min.js"&nbsp;</span><span style="color: #0000BB">type</span><span style="color: #007700">=</span><span style="color: #DD0000">"text/javascript"</span><span style="color: #007700">&gt;</span><span style="color: #0000BB">&lt;/script&gt;<br /></span>&lt;script&nbsp;type="text/javascript"&gt;<br />function&nbsp;GetXmlHttpObject()<br />{<br />&nbsp;&nbsp;if(window.XMLHttpRequest)<br />&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;//&nbsp;code&nbsp;for&nbsp;IE7+,&nbsp;Firefox,&nbsp;Chrome,&nbsp;Opera,&nbsp;Safari<br />&nbsp;&nbsp;&nbsp;&nbsp;return&nbsp;new&nbsp;XMLHttpRequest();<br />&nbsp;&nbsp;}<br />&nbsp;&nbsp;else<br />&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;//&nbsp;code&nbsp;for&nbsp;IE6,&nbsp;IE5<br />&nbsp;&nbsp;&nbsp;&nbsp;return&nbsp;new&nbsp;ActiveXObject("Microsoft.XMLHTTP");<br />&nbsp;&nbsp;}<br />&nbsp;&nbsp;return&nbsp;null;<br />}<br /><br />var&nbsp;current_col&nbsp;=&nbsp;1;<br />var&nbsp;current_row&nbsp;=&nbsp;1;<br /><br />$(document).ready(function()&nbsp;{<br />&nbsp;&nbsp;$("div").hide();<br />&nbsp;&nbsp;$(".div_"+current_col+'_'+current_row).addClass(&nbsp;"yellowbg"&nbsp;);<br />&nbsp;&nbsp;getAllChannels();&nbsp;<br />});<br /><br />$(document).keyup(function(event){<br />var&nbsp;yellowbg&nbsp;=&nbsp;$(".yellowbg");<br />var&nbsp;rowwidth&nbsp;=&nbsp;$(".row").css(&nbsp;"width").split("px");<br />var&nbsp;yellowbgdivclass&nbsp;=&nbsp;yellowbg.attr('class');<br />var&nbsp;splitclass&nbsp;=&nbsp;yellowbgdivclass.split("&nbsp;");<br />var&nbsp;getcurrentrow&nbsp;=&nbsp;splitclass&#91;1&#93;.split("_");<br /><br />var&nbsp;mainWraptop&nbsp;=&nbsp;$(".mainWrap").position().top;<br />var&nbsp;mainWrapheight&nbsp;=&nbsp;$(".mainWrap").height();<br />var&nbsp;rowmove=$("#rowmove").val();<br />//alert($(".row").length);<br />var&nbsp;totalrowcount&nbsp;=&nbsp;8;<br />var&nbsp;displayrowcount&nbsp;=&nbsp;6;<br />var&nbsp;rowheight&nbsp;=&nbsp;42;<br />var&nbsp;rowwidth&nbsp;=&nbsp;1053;<br />var&nbsp;totalwidth_current&nbsp;=&nbsp;0;<br />var&nbsp;totalwidth_current1&nbsp;=&nbsp;0;<br /><br />if(parseInt(current_row)+parseInt(1)&nbsp;&lt;=4)<br />{<br />&nbsp;&nbsp;for(var&nbsp;i=1;&nbsp;i&lt;=(parseInt(current_row)+parseInt(1));i++&nbsp;)<br />&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;yellowbgnextdivwidth&nbsp;=&nbsp;$(".div_"+current_col+'_'+i).css(&nbsp;"width");&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;yellowbgnextdivwidthsplit&nbsp;=&nbsp;yellowbgnextdivwidth.split("px");<br />&nbsp;&nbsp;&nbsp;&nbsp;totalwidth_current=parseInt(totalwidth_current)+parseInt(yellowbgnextdivwidthsplit&#91;0&#93;);<br />&nbsp;&nbsp;}<br />}<br /><br /><br />&nbsp;&nbsp;if&nbsp;(event.keyCode&nbsp;==&nbsp;39)&nbsp;<br />&nbsp;&nbsp;{&nbsp;&nbsp;//right<br />&nbsp;&nbsp;&nbsp;&nbsp;if&nbsp;(yellowbg.next().length)<br />&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;currentrowleft&nbsp;=&nbsp;$(".rowSubPgm&nbsp;div.pgmFirstRow:first").css(&nbsp;"margin-left").split("px");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowleft1&nbsp;=&nbsp;currentrowleft&#91;0&#93;.split("-");<br />&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(typeof(currentrowleft1&#91;1&#93;)!=&nbsp;"undefined")<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowleft&nbsp;=&nbsp;currentrowleft1&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowleft&nbsp;=&nbsp;currentrowleft&#91;0&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;nextdivwidth&nbsp;=&nbsp;$(".div_"+current_col+'_'+(parseInt(current_row)+parseInt(1))).css(&nbsp;"width").split("px");&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//alert((parseInt(rowwidth)+parseInt(currentrowleft)));<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//alert(totalwidth_current);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//alert((parseInt(rowwidth)+parseInt(currentrowleft))&nbsp;&lt;&nbsp;totalwidth_current);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//alert(nextdivwidth);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if((parseInt(rowwidth)+parseInt(currentrowleft))&nbsp;&lt;&nbsp;totalwidth_current)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;$("body").find('.rowSubPgm').each(function(index)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;$(this).find('.pgmFirstRow:first').css(&nbsp;"margin-left",&nbsp;"-"+rowwidth+"px"&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;});<br />&nbsp;&nbsp;&nbsp;&nbsp;$(".rows&nbsp;div:nth-child(2)").css(&nbsp;"margin-left",&nbsp;"-"+parseInt(rowleft)-70&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else&nbsp;if((parseInt(rowwidth)+parseInt(currentrowleft))&nbsp;&gt;&nbsp;totalwidth_current)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;$("body").find('.rowSubPgm').each(function(index)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;$(this).find('.pgmFirstRow:first').css(&nbsp;"margin-left",&nbsp;"-"+rowwidth+"px"&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;});<br />&nbsp;&nbsp;&nbsp;&nbsp;$(".rows&nbsp;div:nth-child(2)").css(&nbsp;"margin-left",&nbsp;"-"+parseInt(rowleft)-170&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(yellowbg.next().position().top&nbsp;==&nbsp;yellowbg.position().top)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;$(".div_"+current_col+'_'+current_row).css(&nbsp;"margin-left",&nbsp;"-"+rowleft&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;currentrowleft&nbsp;=&nbsp;parseInt(currentrowleft)+rowwidth;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;rowleft&nbsp;=&nbsp;currentrowleft+="px";<br />&nbsp;&nbsp;&nbsp;&nbsp;$("body").find('.rowSubPgm').each(function(index)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;$(this).find('.pgmFirstRow:first').css(&nbsp;"margin-left",&nbsp;"-"+rowleft&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;});<br />&nbsp;&nbsp;&nbsp;&nbsp;$(".rows&nbsp;div:nth-child(2)").css(&nbsp;"margin-left",&nbsp;"-"+parseInt(rowleft)-70&nbsp;);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;current_row++;<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;}<br />&nbsp;&nbsp;else&nbsp;if&nbsp;(event.keyCode&nbsp;==&nbsp;37)&nbsp;<br />&nbsp;&nbsp;{&nbsp;&nbsp;&nbsp;//left<br />&nbsp;&nbsp;&nbsp;&nbsp;for(var&nbsp;i=2;&nbsp;i&lt;&nbsp;parseInt(current_row);i++&nbsp;)<br />&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;yellowbgnextdivwidth1&nbsp;=&nbsp;$(".div_"+current_col+'_'+i).css(&nbsp;"width");&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;yellowbgnextdivwidthsplit1&nbsp;=&nbsp;yellowbgnextdivwidth1.split("px");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;totalwidth_current1=parseInt(totalwidth_current1)+parseInt(yellowbgnextdivwidthsplit1&#91;0&#93;);<br />&nbsp;&nbsp;&nbsp;&nbsp;}&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;currentrowleft&nbsp;=&nbsp;$(".rowSubPgm&nbsp;div.pgmFirstRow:first").css(&nbsp;"margin-left").split("px");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowleft1&nbsp;=&nbsp;currentrowleft&#91;0&#93;.split("-");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(typeof(currentrowleft1&#91;1&#93;)!=&nbsp;"undefined")<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowleft&nbsp;=&nbsp;currentrowleft1&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowleft&nbsp;=&nbsp;currentrowleft&#91;0&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;currentdivwidth&nbsp;=&nbsp;yellowbg.css(&nbsp;"width").split("px");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(parseInt(currentrowleft)&nbsp;&gt;&nbsp;totalwidth_current1&nbsp;&amp;&amp;&nbsp;parseInt(current_row)&nbsp;!=&nbsp;2)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//alert("-"+(parseInt(currentrowleft)-parseInt(currentdivwidth))+"px");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(currentdivwidth&#91;0&#93;&nbsp;==&nbsp;517)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentdivwidth&#91;0&#93;&nbsp;=&nbsp;533;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$("body").find('.rowSubPgm').each(function(index)&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(parseInt(current_row)&nbsp;==&nbsp;3)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$(this).find('.pgmFirstRow:first').css(&nbsp;"margin-left",&nbsp;"0px"&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$(this).find('.pgmFirstRow:first').css(&nbsp;"margin-left",&nbsp;"-"+(parseInt(currentdivwidth&#91;0&#93;))+"px"&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;});<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$(".rows&nbsp;div:nth-child(2)").css(&nbsp;"margin-left",&nbsp;"-"+parseInt(rowleft)-70&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(currentdivwidth&#91;0&#93;&nbsp;==&nbsp;1303)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;alert("test");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//yellowbg.prev().length<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/*var&nbsp;currentrowright&nbsp;=&nbsp;$(".mainWrap&nbsp;div.rowSubPgm&nbsp;.pgmFirstRow:first").css(&nbsp;"margin-left");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;margin_right&nbsp;=currentrowright.replace('-',&nbsp;'').replace('px',&nbsp;'');<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(margin_right&nbsp;&gt;&nbsp;rowwidth)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowright&nbsp;=&nbsp;parseInt(currentrowright)+rowwidth;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;rowleft&nbsp;=&nbsp;currentrowright+="px";<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$("body").find('.rowSubPgm').each(function(index)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$(this).find('.pgmFirstRow:first').css(&nbsp;"margin-left",&nbsp;rowleft&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;});<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$(".rows&nbsp;div:nth-child(2)").css(&nbsp;"margin-left",&nbsp;rowleft);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$("body").find('.row').each(function(index)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$(this).find('.pgmFirstRow:first').css(&nbsp;"margin-left",&nbsp;"4px"&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;});<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}*/<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;current_row--;<br />&nbsp;&nbsp;}<br />&nbsp;&nbsp;else&nbsp;if&nbsp;(event.keyCode&nbsp;==&nbsp;38)&nbsp;<br />&nbsp;&nbsp;{&nbsp;&nbsp;//up<br />&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;if(current_col&nbsp;&gt;&nbsp;1&nbsp;&amp;&amp;&nbsp;current_row&nbsp;==&nbsp;1)<br />&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;currentrowtop&nbsp;=&nbsp;$(".mainWrap&nbsp;div.row:first-child").css(&nbsp;"margin-top");&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;calcuatedrowtop&nbsp;=&nbsp;-(current_col*rowheight);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowtop&nbsp;=&nbsp;parseInt(currentrowtop)-rowheight;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if((currentrowtop&nbsp;-&nbsp;calcuatedrowtop)&nbsp;&lt;&nbsp;rowheight)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowtop&nbsp;=&nbsp;parseInt(currentrowtop)+rowheight;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowtop&nbsp;=&nbsp;parseInt(currentrowtop)+rowheight;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;rowtop&nbsp;=&nbsp;currentrowtop+="px";<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$(".mainWrap&nbsp;div.row:first-child").css(&nbsp;"margin-top",&nbsp;rowtop&nbsp;);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;current_col--;<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;}<br />&nbsp;&nbsp;else&nbsp;if&nbsp;(event.keyCode&nbsp;==&nbsp;40)&nbsp;<br />&nbsp;&nbsp;{&nbsp;&nbsp;&nbsp;&nbsp;//down<br />&nbsp;&nbsp;&nbsp;&nbsp;if(current_col&nbsp;&lt;&nbsp;totalrowcount&nbsp;&amp;&amp;&nbsp;current_row&nbsp;==&nbsp;1)<br />&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(current_col&nbsp;&gt;=&nbsp;displayrowcount)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;currentrowtop&nbsp;=&nbsp;$(".mainWrap&nbsp;div.row:first-child").css(&nbsp;"margin-top");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currentrowtop&nbsp;=&nbsp;parseInt(currentrowtop)-rowheight;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;rowtop&nbsp;=&nbsp;currentrowtop+="px";<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$(".mainWrap&nbsp;div.row:first-child").css(&nbsp;"margin-top",&nbsp;rowtop&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;current_col++;<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;}<br />&nbsp;&nbsp;$('div').removeClass(&nbsp;"yellowbg"&nbsp;);<br />&nbsp;&nbsp;//alert(".div_"+current_col+'_'+current_row);<br />&nbsp;&nbsp;$(".div_"+current_col+'_'+current_row).addClass(&nbsp;"yellowbg"&nbsp;);<br />});<br /><br />width=new&nbsp;Array();<br />imagecontent&nbsp;=&nbsp;new&nbsp;Array();<br />pgmcontent=new&nbsp;Array();<br /><br />var&nbsp;checksuminit&nbsp;=&nbsp;0;<br />var&nbsp;checksum&nbsp;=&nbsp;0;<br />function&nbsp;getAllChannels()<br />{<br />&nbsp;&nbsp;$.ajax({<br />&nbsp;&nbsp;url:'get-listing.php',<br />&nbsp;&nbsp;type:'POST',<br />&nbsp;&nbsp;data:'',<br />&nbsp;&nbsp;success:&nbsp;function(result)<br />&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;$doc&nbsp;=&nbsp;$(result);<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;i=1;<br />&nbsp;&nbsp;&nbsp;&nbsp;$doc.filter('p#channels').each(function(index)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;imagecontent&#91;i&#93;&nbsp;=&nbsp;$(this).html();<br />&nbsp;&nbsp;&nbsp;&nbsp;i++;<br />&nbsp;&nbsp;});<br />&nbsp;&nbsp;var&nbsp;j=1;<br />&nbsp;&nbsp;$doc.filter('#links').each(function(index)&nbsp;{<br />&nbsp;&nbsp;var&nbsp;$link&nbsp;=&nbsp;$(this).html();<br />&nbsp;&nbsp;$link1&nbsp;=&nbsp;$link.replace("&amp;amp;",&nbsp;"&amp;");&nbsp;<br />&nbsp;&nbsp;if($.trim($link1)&nbsp;!='')<br />&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;checksuminit+=j;<br />&nbsp;&nbsp;&nbsp;&nbsp;getSchule($link1,j);<br />&nbsp;&nbsp;}<br />&nbsp;&nbsp;j++;<br />&nbsp;&nbsp;});<br />&nbsp;}<br />});<br />}<br /><br />function&nbsp;getSchule($link,j)<br />{<br />&nbsp;&nbsp;//var&nbsp;widthval&nbsp;=&nbsp;350;<br />&nbsp;&nbsp;var&nbsp;widthval&nbsp;=&nbsp;&nbsp;850;<br />&nbsp;&nbsp;var&nbsp;parts&nbsp;=&nbsp;$link.split("/");<br />&nbsp;&nbsp;var&nbsp;links&nbsp;=&nbsp;parts&#91;parts.length-1&#93;;<br />&nbsp;&nbsp;var&nbsp;programlength&nbsp;=&nbsp;0;<br />&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;$.ajax({<br />&nbsp;&nbsp;url:$.trim(links),<br />&nbsp;&nbsp;type:'GET',<br />&nbsp;&nbsp;data:'',<br />&nbsp;&nbsp;success:&nbsp;function(data)<br />&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;$data&nbsp;=&nbsp;$(data);&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;title1&nbsp;=&nbsp;$data.filter("#title1").html();<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;title2&nbsp;=&nbsp;$data.filter("#title2").html();<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;title3&nbsp;=&nbsp;$data.filter("#title3").html();<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;title4&nbsp;=&nbsp;$data.filter("#title4").html();<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;time1&nbsp;=&nbsp;$data.filter("#time1").html();<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;time2&nbsp;=&nbsp;$data.filter("#time2").html();<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;time3&nbsp;=&nbsp;$data.filter("#time3").html();<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;time4&nbsp;=&nbsp;$data.filter("#time4").html();<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;time1&nbsp;=&nbsp;time1.split("&nbsp;");<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;time1AMPM&nbsp;=&nbsp;time1&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;time1&nbsp;=&nbsp;time1&#91;0&#93;.split(":");<br />&nbsp;&nbsp;&nbsp;&nbsp;time1=&nbsp;time1&#91;0&#93;+'.'+time1&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;if($.trim(time1AMPM)&nbsp;==&nbsp;'PM'&nbsp;&amp;&amp;&nbsp;time1&lt;12)<br />&nbsp;&nbsp;&nbsp;&nbsp;time1&nbsp;=&nbsp;parseFloat(time1)+12;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;time2&nbsp;=&nbsp;time2.split("&nbsp;");<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;time2AMPM&nbsp;=&nbsp;time2&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;time2&nbsp;=&nbsp;time2&#91;0&#93;.split(":");<br />&nbsp;&nbsp;&nbsp;&nbsp;time2=&nbsp;time2&#91;0&#93;+'.'+time2&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;if($.trim(time2AMPM)&nbsp;==&nbsp;'PM'&nbsp;&amp;&amp;&nbsp;time2&lt;12)<br />&nbsp;&nbsp;&nbsp;&nbsp;time2&nbsp;=&nbsp;parseFloat(time2)+12;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;time3&nbsp;=&nbsp;time3.split("&nbsp;");<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;time3AMPM&nbsp;=&nbsp;time3&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;time3&nbsp;=&nbsp;time3&#91;0&#93;.split(":");<br />&nbsp;&nbsp;&nbsp;&nbsp;time3=&nbsp;time3&#91;0&#93;+'.'+time3&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;if($.trim(time3AMPM)&nbsp;==&nbsp;'PM'&nbsp;&amp;&amp;&nbsp;time3&lt;12)<br />&nbsp;&nbsp;&nbsp;&nbsp;time3&nbsp;=&nbsp;parseFloat(time3)+12;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;time4&nbsp;=&nbsp;time4.split("&nbsp;");<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;time4AMPM&nbsp;=&nbsp;time4&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;time4&nbsp;=&nbsp;time4&#91;0&#93;.split(":");<br />&nbsp;&nbsp;&nbsp;&nbsp;time4=&nbsp;time4&#91;0&#93;+'.'+time4&#91;1&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;if($.trim(time4AMPM)&nbsp;==&nbsp;'PM'&nbsp;&amp;&amp;&nbsp;time4&lt;12)<br />&nbsp;&nbsp;&nbsp;&nbsp;time4&nbsp;=&nbsp;parseFloat(time4)+12;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;difftime2time1&nbsp;=&nbsp;(parseFloat(time2)&nbsp;-&nbsp;parseFloat(time1)).toFixed(2);<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;difftime3time2&nbsp;=&nbsp;(parseFloat(time3)&nbsp;-&nbsp;parseFloat(time2)).toFixed(2);<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;difftime4time3&nbsp;=&nbsp;(parseFloat(time4)&nbsp;-&nbsp;parseFloat(time3)).toFixed(2);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;if(isNaN(difftime2time1))<br />&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;difftime2time1=0;<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;if(isNaN(difftime3time2))<br />&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;difftime3time2=0;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;if(isNaN(difftime4time3))<br />&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;difftime4time3=0;<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;currenttotal&nbsp;=&nbsp;0;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;firstele&nbsp;=&nbsp;((j-1)*3)+1;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;lastele&nbsp;=&nbsp;parseInt(firstele)+2;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;k=1;<br />&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;programlength&nbsp;=&nbsp;0;<br />&nbsp;&nbsp;&nbsp;&nbsp;for(;firstele&nbsp;&lt;=&nbsp;lastele;firstele++)<br />&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;var&nbsp;nexttimedate&nbsp;=&nbsp;parseInt(k)+1;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;programlength&nbsp;=&nbsp;parseFloat(programlength)&nbsp;+&nbsp;parseFloat(eval('difftime'+nexttimedate+'time'+k));<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if((eval('difftime'+nexttimedate+'time'+k))&nbsp;&gt;&nbsp;0.70&nbsp;&amp;&amp;&nbsp;(eval('difftime'+nexttimedate+'time'+k))&nbsp;&lt;=1.00&nbsp;)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span1hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=517;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else&nbsp;if((eval('difftime'+nexttimedate+'time'+k))&nbsp;&gt;&nbsp;1.00&nbsp;&amp;&amp;&nbsp;(eval('difftime'+nexttimedate+'time'+k))&nbsp;&lt;=1.30&nbsp;)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span1_5hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=701;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else&nbsp;if((eval('difftime'+nexttimedate+'time'+k))&nbsp;&gt;&nbsp;2.00&nbsp;&amp;&amp;&nbsp;(eval('difftime'+nexttimedate+'time'+k))&nbsp;&lt;=2.30&nbsp;)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span2hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=1303;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else&nbsp;if((eval('difftime'+nexttimedate+'time'+k))&nbsp;&gt;&nbsp;3.00&nbsp;&amp;&amp;&nbsp;(eval('difftime'+nexttimedate+'time'+k))&nbsp;&lt;=3.30&nbsp;)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span3hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=1802;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;&nbsp;=&nbsp;250;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(programlength&nbsp;==&nbsp;1.00)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(currenttotal==0)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span1hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=517;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span0hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=250;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(programlength&nbsp;&gt;=&nbsp;1.30)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(currenttotal==0)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span1_5hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=701;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span0hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=250;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(programlength&nbsp;==&nbsp;2.00)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(currenttotal==0)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span2hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=1303;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;else<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+firstele).addClass("span0hr");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;width&#91;j&#93;=250;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;currenttotal++;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;pgmcontent&#91;firstele&#93;&nbsp;=&nbsp;eval('title'+k);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;k++;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;checksum+=j;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;if(checksuminit&nbsp;==&nbsp;checksum)<br />&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for(var&nbsp;ii=1;ii&lt;width.length-1;ii++)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;widthval+=width&#91;ii&#93;;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for(var&nbsp;jj=1;jj&nbsp;&lt;=&nbsp;pgmcontent.length-1;jj++)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#programe'+jj).html(pgmcontent&#91;jj&#93;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for(var&nbsp;kk=1;kk&nbsp;&lt;=&nbsp;imagecontent.length-1;kk++)<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$('#image'+kk).html(imagecontent&#91;kk&#93;);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$("body").find('.rowSubPgm').each(function(index)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$(this).css(&nbsp;"width",&nbsp;widthval+"px");<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;});<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$("div").show();&nbsp;&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />&nbsp;&nbsp;}&nbsp;&nbsp;&nbsp;<br />&nbsp;&nbsp;});<br />}<br />&lt;/body&gt;<br />&lt;/html&gt;&nbsp;<br /></span>
</code><!-- php buffer end -->
		</div>
		</code>
		<hr />
	</div>
</div><br />
If you know how to fix the bugs I have mention on above, i would be very grateful if you could help me out to solve my problem.<br />
<br />
Thanks in advance</div>


	<br />
	<div style="padding:6px">

	
		<fieldset class="fieldset">
			<legend>Attached Thumbnails</legend>
			<div style="padding:3px">
			
<a href="http://www.codingforums.com/attachment.php?attachmentid=12122&amp;d=1368999580" rel="Lightbox_1336502" id="attachment12122" target="_blank"><img class="thumbnail" src="http://www.codingforums.com/attachment.php?attachmentid=12122&amp;stc=1&amp;thumb=1&amp;d=1368999580" border="0" alt="Click image for larger version

Name:	blockrows01.jpg
Views:	N/A
Size:	47.2 KB
ID:	12122" /></a>
&nbsp;

			</div>
		</fieldset>
	

	

	

	

	</div>
]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=6">PHP</category>
			<dc:creator>mark103</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295607</guid>
		</item>
		<item>
			<title>Page down/up scrolling on a site with a fixed header</title>
			<link>http://www.codingforums.com/showthread.php?t=295606&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 20:43:44 GMT</pubDate>
			<description><![CDATA[Hello, 
 
I recently posed this question in a thread I started (and marked resolved) months ago (URL]http://www.codingforums.com/showthread.php?t=281870[/URL]) about coding issues related to a site I'm building.  I'm starting a new thread because I wanted to make sure the resolved status didn't...]]></description>
			<content:encoded><![CDATA[<div>Hello,<br />
<br />
I recently posed this question in a thread I started (and marked resolved) months ago (URL]http://www.codingforums.com/showthread.php?t=281870[/URL]) about coding issues related to a site I'm building.  I'm starting a new thread because I wanted to make sure the resolved status didn't turn people away from seeing my newer issue.<br />
<br />
Anyway, my site has a fixed header.  When scrolling down/up a page using the page buttons on the keyboard, it moves too far - instead of scrolling the length of the content (or less), it's including the height of the header (and possibly the small bit of padding below it).  This is undesirable as someone hitting the page down while viewing the content ends up missing stuff and would have to manually go back up a bit with the arrow buttons or their mouse.<br />
<br />
I've dug around online a bit for a solution, but perhaps my wording/search terms are making it difficult to find.  One solution suggested adding a fixed height code, but all that did was limit the amount of content that could be viewed at all.  Not good.  Another solution noted finding some sort of Javascript or jQuery to adjust the scroll distance on page down/up.  So far, I haven't found anything.  One concern is that I do not want to have an additional scroll bar show up on the side next to the one normally shows from the browser itself.  I don't like the way that looks...<br />
<br />
I'm hoping someone could come up with a solution/fix for this.  I've noticed on my Facebook news feed (for instance), the short blue section at the top stays fixed, but content never gets hidden when paging down by this.  If anything, paging down doesn't always go all the way in moving all the visible content down (which I'd be fine with vs. too much like my site is doing).  Does anyone know how they control page button scrolling distance?<br />
<br />
My code is below.  It has content removed with generic as I'm not quite ready to have that public, but code wise is the same (though some pages have different parameters in the UL, OL, DL code that match the h1, etc. section).<br />
<br />
I'm not a web-developer by any means - I'm only doing this for a business I'm launching.  Thanks again in advance...<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left">&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.01//EN&quot; <br />
<br />
&quot;http://www.w3.org/TR/html4/strict.dtd&quot;&gt;<br />
&lt;html&gt;<br />
&lt;head&gt;<br />
&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=utf-8&quot;&gt;<br />
&lt;title&gt;XXX&lt;/title&gt;<br />
&lt;meta name=&quot;description&quot; content=&quot;XXX&quot;&gt;<br />
&lt;meta name=&quot;keywords&quot; content=&quot;XXX&quot;&gt;<br />
&lt;meta name=&quot;geo.region&quot; content=&quot;XXX&quot;&gt;<br />
&lt;meta name=&quot;geo.placename&quot; content=&quot;XXX&quot;&gt;<br />
&lt;meta name=&quot;geo.position&quot; content=&quot;XXX&quot;&gt;<br />
&lt;meta name=&quot;ICBM&quot; content=&quot;XXX&quot;&gt;<br />
&lt;style type=&quot;text/css&quot;&gt;<br />
&lt;!--<br />
html, body {<br />
&nbsp; &nbsp; &nbsp; &nbsp; font: 100%/1.4 Verdana, Arial, Helvetica, sans-serif;<br />
&nbsp; &nbsp; &nbsp; &nbsp; background-color: #C9D6A0;<br />
&nbsp; &nbsp; &nbsp; &nbsp; margin: 0;<br />
&nbsp; &nbsp; &nbsp; &nbsp; padding: 0;<br />
&nbsp; &nbsp; &nbsp; &nbsp; color: #000;<br />
&nbsp; &nbsp; &nbsp; &nbsp; font-family: &quot;Century Gothic&quot;;<br />
}<br />
<br />
/* ~~ Element/tag selectors ~~ */<br />
ul, ol, dl { /* Due to variations between browsers, it's best practices to zero <br />
<br />
padding and margin on lists. For consistency, you can either specify the <br />
<br />
amounts you want here, or on the list items (LI, DT, DD) they contain. Remember <br />
<br />
that what you do here will cascade to the .nav list unless you write a more <br />
<br />
specific selector. */<br />
&nbsp; &nbsp; &nbsp; &nbsp; padding: 0;<br />
&nbsp; &nbsp; &nbsp; &nbsp; margin: 0;<br />
}<br />
h1, h2, h3, h4, h5, h6, p {<br />
&nbsp; &nbsp; &nbsp; &nbsp; margin-top: 0;&nbsp; &nbsp; &nbsp; &nbsp;  /* removing the top margin gets around an issue where <br />
<br />
margins can escape from their containing div. The remaining bottom margin will <br />
<br />
hold it away from any elements that follow. */<br />
&nbsp; &nbsp; &nbsp; &nbsp; padding-right: 15px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; padding-left: 15px; /* adding the padding to the sides of the elements <br />
<br />
within the divs, instead of the divs themselves, gets rid of any box model <br />
<br />
math. A nested div with side padding can also be used as an alternate method. <br />
<br />
*/<br />
&nbsp; &nbsp; &nbsp; &nbsp; text-shadow: #A2C8CA 0 0 1px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; font-smoothing: antialiased;<br />
&nbsp; &nbsp; &nbsp; &nbsp; text-rendering: optimizeLegibility<br />
&nbsp; &nbsp; &nbsp; &nbsp; color: #AED6D9;<br />
&nbsp; &nbsp; &nbsp; &nbsp; font-weight: 500;<br />
&nbsp; &nbsp; &nbsp; &nbsp; font-size: .92em;<br />
&nbsp; &nbsp; &nbsp; &nbsp; line-height: 150%;<br />
}<br />
a img { /* this selector removes the default blue border displayed in some <br />
<br />
browsers around an image when it is surrounded by a link */<br />
&nbsp; &nbsp; &nbsp; &nbsp; border: none;<br />
}<br />
/* ~~ Styling for your site's links must remain in this order - including the <br />
<br />
group of selectors that create the hover effect. ~~ */<br />
a:link {<br />
&nbsp; &nbsp; &nbsp; &nbsp; color: #AED6D9;<br />
&nbsp; &nbsp; &nbsp; &nbsp; text-decoration: none; /* unless you style your links to look extremely <br />
<br />
unique, it's best to provide underlines for quick visual identification */<br />
}<br />
a:visited {<br />
&nbsp; &nbsp; &nbsp; &nbsp; color: #AED6D9;<br />
&nbsp; &nbsp; &nbsp; &nbsp; text-decoration: underline;<br />
}<br />
a:hover, a:active, a:focus { /* this group of selectors will give a keyboard <br />
<br />
navigator the same hover experience as the person using a mouse. */<br />
&nbsp; &nbsp; &nbsp; &nbsp; text-decoration: none;<br />
}<br />
<br />
/* ~~ this fixed width container surrounds the other divs ~~ */<br />
.container {<br />
&nbsp; &nbsp; &nbsp; &nbsp; width: 960px;<br />
overflow: auto;<br />
&nbsp; &nbsp; &nbsp; &nbsp; background-color: #603B3D;<br />
&nbsp; &nbsp; &nbsp; &nbsp; margin: 0 auto; /* the auto value on the sides, coupled with the width, <br />
<br />
centers the layout */<br />
}<br />
<br />
/* ~~ the header is not given a width. It will extend the full width of your <br />
<br />
layout. It contains an image placeholder that should be replaced with your own <br />
<br />
linked logo ~~ */<br />
.header {<br />
&nbsp; &nbsp; &nbsp; &nbsp; height: 200px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; width: 960px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; background-color: #603B3D;<br />
&nbsp; &nbsp; &nbsp; &nbsp; text-align: left;<br />
&nbsp; &nbsp; &nbsp; &nbsp; position: fixed;<br />
&nbsp; &nbsp; &nbsp; &nbsp; z-index: 1000;<br />
}<br />
.header img {float: left;}<br />
&nbsp; &nbsp; &nbsp; &nbsp; .header ul {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; margin: 5px 0 0 400px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; text-align: center;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; list-style: none;<br />
&nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; .header ul li {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; width: 127px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; margin: 0px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; float: left;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
<br />
/* ~~ This is the layout information. ~~ <br />
<br />
1) Padding is only placed on the top and/or bottom of the div. The elements <br />
<br />
within this div have padding on their sides. This saves you from any &quot;box model <br />
<br />
math&quot;. Keep in mind, if you add any side padding or border to the div itself, <br />
<br />
it will be added to the width you define to create the *total* width. You may <br />
<br />
also choose to remove the padding on the element in the div and place a second <br />
<br />
div within it with no width and the padding necessary for your design.<br />
<br />
*/<br />
<br />
.content {<br />
margin: 186px 0 0;<br />
&nbsp; &nbsp; &nbsp; &nbsp; padding: 10px 0;<br />
&nbsp; &nbsp; &nbsp; &nbsp; font-family: &quot;Century Gothic&quot;;<br />
&nbsp; &nbsp; &nbsp; &nbsp; font-size: 12pt;<br />
}<br />
<br />
.bigger { font-size:85%; }<br />
<br />
<br />
/* ~~ The footer ~~ */<br />
.footer {<br />
&nbsp; &nbsp; &nbsp; &nbsp; height: 15px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; width: 960px;<br />
&nbsp; margin: 0 0 0 -480px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; padding: 10px 0;<br />
&nbsp; &nbsp; &nbsp; &nbsp; position: fixed;<br />
&nbsp; &nbsp; &nbsp; &nbsp; bottom: 0;<br />
&nbsp; &nbsp; &nbsp; &nbsp; left: 50%;<br />
&nbsp; &nbsp; &nbsp; &nbsp; background: #603B3D;<br />
}<br />
/* ~~ miscellaneous float/clear classes ~~ */<br />
.fltrt {&nbsp; /* this class can be used to float an element right in your page. The <br />
<br />
floated element must precede the element it should be next to on the page. */<br />
&nbsp; &nbsp; &nbsp; &nbsp; float: right;<br />
&nbsp; &nbsp; &nbsp; &nbsp; margin-left: 8px;<br />
}<br />
.fltlft { /* this class can be used to float an element left in your page. The <br />
<br />
floated element must precede the element it should be next to on the page. */<br />
&nbsp; &nbsp; &nbsp; &nbsp; float: left;<br />
&nbsp; &nbsp; &nbsp; &nbsp; margin-right: 8px;<br />
}<br />
.clearfloat { /* this class can be placed on a &lt;br /&gt; or empty div as the final <br />
<br />
element following the last floated div (within the #container) if the #footer <br />
<br />
is removed or taken out of the #container */<br />
&nbsp; &nbsp; &nbsp; &nbsp; clear:both;<br />
&nbsp; &nbsp; &nbsp; &nbsp; height:0;<br />
&nbsp; &nbsp; &nbsp; &nbsp; font-size: 1px;<br />
&nbsp; &nbsp; &nbsp; &nbsp; line-height: 0px;<br />
}<br />
body,td,th {<br />
&nbsp; &nbsp; &nbsp; &nbsp; color: #AED6D9;<br />
}<br />
--&gt;<br />
&lt;/style&gt;<br />
&lt;link href=&quot;century_gothic_font/stylesheet.css&quot; rel=&quot;stylesheet&quot; <br />
<br />
type=&quot;text/css&quot;&gt;<br />
&lt;link href=&quot;century_gothic_bold_font/stylesheet.css&quot; rel=&quot;stylesheet&quot; <br />
<br />
type=&quot;text/css&quot;&gt;<br />
&lt;script type=&quot;text/javascript&quot; src=&quot;jquery-1.9.1.js&quot;&gt;&lt;/script&gt;<br />
<br />
<br />
&lt;script&gt;<br />
$(function(){<br />
&nbsp; &nbsp; &nbsp; &nbsp; $('.fadein img:gt(0)').hide();<br />
&nbsp; &nbsp; &nbsp; &nbsp; setInterval(function(){$('.fadein :first-child').fadeOut().next<br />
<br />
('img').fadeIn().end().appendTo('.fadein');}, 7250);<br />
});<br />
&lt;/script&gt;<br />
&lt;/head&gt;<br />
<br />
&lt;body&gt;<br />
<br />
&lt;div class=&quot;container&quot;&gt;<br />
&nbsp; &lt;div class=&quot;header&quot;&gt;&lt;img src=&quot;XXX&quot; width=&quot;443&quot; height=&quot;186&quot; alt=&quot;XXX&quot;&gt;&lt;ul&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;XXX&quot;&gt;&lt;img src=&quot;XXX&quot; width=&quot;127&quot; <br />
<br />
height=&quot;90&quot; alt=&quot;XXX&quot;&gt;&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;XXX&quot;&gt;&lt;img src=&quot;XXX&quot; width=&quot;127&quot; <br />
<br />
height=&quot;90&quot; alt=&quot;XXX&quot;&gt;&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;XXX&quot;&gt;&lt;img src=&quot;XXX&quot; width=&quot;127&quot; height=&quot;90&quot; <br />
<br />
alt=&quot;XXX&quot;&gt;&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;XXX&quot;&gt;&lt;img src=&quot;XXX&quot; width=&quot;127&quot; height=&quot;90&quot; <br />
<br />
alt=&quot;XXX&quot;&gt;&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;XX&quot;&gt;&lt;img src=&quot;XXX&quot; width=&quot;127&quot; height=&quot;90&quot; <br />
<br />
alt=&quot;XXX&quot;&gt;&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;XXX&quot;&gt;&lt;img src=&quot;XXX&quot; width=&quot;127&quot; height=&quot;90&quot; <br />
<br />
alt=&quot;XXX&quot;&gt;&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;XXX&quot;&gt;&lt;img src=&quot;XXX&quot; width=&quot;127&quot; height=&quot;90&quot; <br />
<br />
alt=&quot;XXX&quot;&gt;&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;XXX&quot;&gt;&lt;img src=&quot;XXX&quot; width=&quot;127&quot; <br />
<br />
height=&quot;90&quot; alt=&quot;XXX&quot;&gt;&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;/ul&gt;&lt;/div&gt;<br />
&nbsp; &lt;div class=&quot;content&quot;&gt;<br />
&nbsp; &nbsp; &lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style=&quot;float: left; width: 80px;&quot;&gt;&lt;img src=&quot;Brown <br />
<br />
fill.png&quot; alt=&quot;left side fill&quot;&gt;&lt;/div&gt;&lt;div style= &quot;display:block;max-height: <br />
<br />
429px; overflow:hidden;&quot; id=&quot;slideshow&quot;&gt;<br />
&lt;div class=&quot;fadein&quot;&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &lt;img src=&quot;XXX&quot; alt=&quot;XXX&quot;&gt;<br />
&nbsp; &nbsp; &lt;img src=&quot;XXX&quot; alt=&quot;XXX&quot;&gt;<br />
&nbsp; &nbsp; &lt;img src=&quot;XXX&quot; alt=&quot;XXX&quot;&gt;<br />
&nbsp; &nbsp; &lt;img src=&quot;XXX&quot; alt=&quot;XXX&quot;&gt;<br />
&nbsp; &nbsp; &lt;img src=&quot;XXX&quot; alt=&quot;XXX&quot;&gt;<br />
&nbsp; &nbsp; &lt;img src=&quot;XXX&quot; alt=&quot;XXX&quot;&gt;<br />
&nbsp; &nbsp; &lt;img src=&quot;XXX&quot; alt=&quot;XXX&quot;&gt;<br />
&nbsp; &nbsp; &lt;img src=&quot;XXX&quot; alt=&quot;XXX&quot;&gt;&lt;/div&gt;&lt;/div&gt;<br />
&nbsp; &nbsp; &lt;br&gt;<br />
&nbsp; &nbsp; &lt;p&gt;This is generic text inserted to show the problem I'm having on my page <br />
<br />
with scrolling up too much when using the page up/down keyboard buttons.&nbsp; I <br />
<br />
need to limit/reduce the scroll when performed in this manner by the height of <br />
<br />
the header and any padding directly below it so when one hits page down, no <br />
<br />
text/content is missed out on without having to adjust their position on the <br />
<br />
page with arrow keys, a thumbwheel, etc.&nbsp; This is generic text inserted to show <br />
<br />
the problem I'm having on my page with scrolling up too much when using the <br />
<br />
page up/down keyboard buttons.&nbsp; I need to limit/reduce the scroll when <br />
<br />
performed in this manner by the height of the header and any padding directly <br />
<br />
below it so when one hits page down, no text/content is missed out on without <br />
<br />
having to adjust their position on the page with arrow keys, a thumbwheel, <br />
<br />
etc.&lt;/p&gt;<br />
&nbsp; &nbsp; &lt;br&gt;<br />
&nbsp; &nbsp; &lt;p&gt;This is generic text inserted to show the problem I'm having on my page <br />
<br />
with scrolling up too much when using the page up/down keyboard buttons.&nbsp; I <br />
<br />
need to limit/reduce the scroll when performed in this manner by the height of <br />
<br />
the header and any padding directly below it so when one hits page down, no <br />
<br />
text/content is missed out on without having to adjust their position on the <br />
<br />
page with arrow keys, a thumbwheel, etc.&nbsp; This is generic text inserted to show <br />
<br />
the problem I'm having on my page with scrolling up too much when using the <br />
<br />
page up/down keyboard buttons.&nbsp; I need to limit/reduce the scroll when <br />
<br />
performed in this manner by the height of the header and any padding directly <br />
<br />
below it so when one hits page down, no text/content is missed out on without <br />
<br />
having to adjust their position on the page with arrow keys, a thumbwheel, <br />
<br />
etc.&lt;/p&gt;<br />
&nbsp; &nbsp; &lt;br&gt;<br />
&nbsp; &nbsp; &lt;p&gt;This is generic text inserted to show the problem I'm having on my page <br />
<br />
with scrolling up too much when using the page up/down keyboard buttons.&nbsp; I <br />
<br />
need to limit/reduce the scroll when performed in this manner by the height of <br />
<br />
the header and any padding directly below it so when one hits page down, no <br />
<br />
text/content is missed out on without having to adjust their position on the <br />
<br />
page with arrow keys, a thumbwheel, etc.<br />
&nbsp; &nbsp; &lt;/p&gt;<br />
&nbsp; &nbsp; &lt;br&gt;<br />
&nbsp; &nbsp; &lt;p&gt;&lt;/p&gt;<br />
&nbsp; &nbsp; &lt;h1&gt;&amp;nbsp;&lt;/h1&gt;<br />
&nbsp; &nbsp; &lt;strong&gt;<br />
&nbsp; &nbsp; &lt;!-- end .content --&gt;<br />
&nbsp; &lt;/strong&gt;&lt;/div&gt;<br />
&nbsp; &lt;div class=&quot;footer&quot;&gt;<br />
&nbsp; &nbsp; &lt;CENTER&gt;&lt;p&gt;&lt;span class=bigger&gt;&lt;a target=&quot;_blank&quot; href=&quot;XXX&quot;&gt;XXX &lt;img <br />
<br />
src=&quot;XXX&quot; width=&quot;15&quot; height=&quot;15&quot; alt=&quot;XXX&quot;&gt;&lt;/a&gt;, &lt;a target=&quot;_blank&quot; <br />
<br />
href=&quot;XXX&quot;&gt;XXX &lt;img src=&quot;XXX&quot; width=&quot;15&quot; height=&quot;15&quot; alt=&quot;XXX&quot;&gt;&lt;/a&gt;, &lt;a <br />
<br />
target=&quot;_blank&quot; href=&quot;XXX&quot;&gt;XXX &lt;img src=&quot;XXX&quot; width=&quot;15&quot; height=&quot;14&quot; <br />
<br />
alt=&quot;XXX&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;&lt;/CENTER&gt;<br />
&nbsp; &nbsp; &lt;!-- end .footer --&gt;&lt;/div&gt;<br />
&nbsp; &lt;!-- end .container --&gt;&lt;/div&gt;<br />
&lt;/body&gt;<br />
&lt;/html&gt;</code><hr />
</div></div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=13"><![CDATA[HTML & CSS]]></category>
			<dc:creator>MMM717</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295606</guid>
		</item>
		<item>
			<title>Hiring a backend coder!</title>
			<link>http://www.codingforums.com/showthread.php?t=295605&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 18:58:56 GMT</pubDate>
			<description><![CDATA[PixolStudios.co.uk ! 
 
We're hiring a backend coder! 
 
You must have a good knowledge of the following languages: 
 
 
* 
* Javascript 
* jQuery]]></description>
			<content:encoded><![CDATA[<div>PixolStudios.co.uk !<br />
<br />
We're hiring a backend coder!<br />
<br />
You must have a good knowledge of the following languages:<br />
<br />
<br />
<b><ul><li>Javascript</li>
<li>jQuery</li>
<li>PHP</li>
</ul></b><br />
<br />
These are <i>vital</i>, as well as HTML &amp; CSS.<br />
This position will be paying, if you are interested please email <br />
<b>info@pixolstudios.co.uk</b> or add <b>LlangyPetes</b> on skype.<br />
<br />
Please note that you will have to present 2+ examples of previous work<br />
with those languages.<br />
<br />
Thank you,<br />
Josh Peters.</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=42">Career, job, and business ideas or advice</category>
			<dc:creator>PixolStudios</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295605</guid>
		</item>
		<item>
			<title>Drop down menu not working correctly</title>
			<link>http://www.codingforums.com/showthread.php?t=295604&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 18:14:26 GMT</pubDate>
			<description><![CDATA[Hi there, 
 
I have just installed a drop down menu but I cant get the sub categories to work correctly. Could someone take a look and advise me what I am missing. 
 
It's a wordpress site <a href="http://www.antiquesilveronline.co.uk" target="_blank">www.antiquesilveronline.co.uk</a> (under...]]></description>
			<content:encoded><![CDATA[<div>Hi there,<br />
<br />
I have just installed a drop down menu but I cant get the sub categories to work correctly. Could someone take a look and advise me what I am missing.<br />
<br />
It's a wordpress site <a href="http://www.antiquesilveronline.co.uk" target="_blank">www.antiquesilveronline.co.uk</a> (under construction obv)<br />
<br />
The CSS is:-<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left">/*** Menu *****************************/<br />
#menu{height:40px; margin-top:20px;}<br />
#navigation{height:40px;}&nbsp; &nbsp; &nbsp; &nbsp; <br />
#nav ul,<br />
#nav li,<br />
#nav span,<br />
#nav a {<br />
&nbsp; margin: 0;<br />
&nbsp; padding: 0;<br />
&nbsp; position: relative;<br />
}<br />
#nav {<br />
&nbsp; height: 40px;<br />
&nbsp; width:100%;<br />
}<br />
#nav:after,<br />
#nav ul:after {<br />
&nbsp; content: '';<br />
&nbsp; display: block;<br />
&nbsp; clear: both;<br />
}<br />
#nav a {<br />
&nbsp; background: #ccc;<br />
&nbsp; background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAxCAIAAACUDVRzAAAAA3NCSVQICAjb4U/gAAAALElEQVQImWMwMrJi+v//PxMDw3+m//8ZoPR/qBgDEhuXGLoeYswhXg8R5gAAdVpfoJ3dB5oAAAAASUVORK5CYII=) 100% 100%; <br />
&nbsp; background: -moz-linear-gradient(top, #fff 0%, #d7d7d7 100%);<br />
&nbsp; background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #fff), color-stop(100%, #d7d7d7));<br />
&nbsp; background: -webkit-linear-gradient(top, #fff 0%, #d7d7d7 100%);<br />
&nbsp; background: -o-linear-gradient(top, #fff 0%, #d7d7d7 100%);<br />
&nbsp; background: -ms-linear-gradient(top, #fff 0%, #d7d7d7 100%);<br />
&nbsp; background: linear-gradient(to bottom, #fff 0%, #d7d7d7 100%);<br />
&nbsp; color: #555555;<br />
&nbsp; display: inline-block;<br />
&nbsp; font-family: Helvetica, Arial, Verdana, sans-serif;<br />
&nbsp; font-size: 12px;<br />
&nbsp; line-height: 40px;<br />
&nbsp; padding: 0 20px;<br />
&nbsp; text-decoration: none;<br />
}<br />
#nav ul {<br />
&nbsp; list-style: none;<br />
}<br />
#nav &gt; ul {<br />
&nbsp; float: left;<br />
}<br />
#nav &gt; ul &gt; li {<br />
&nbsp; float: left;<br />
}<br />
#nav &gt; ul &gt; li:hover:after {<br />
<br />
}<br />
#nav &gt; ul &gt; li:first-child &gt; a {<br />
}<br />
#nav &gt; ul &gt; li:last-child &gt; a {<br />
}<br />
#nav &gt; ul &gt; li.active &gt; a {<br />
&nbsp; box-shadow: inset 0 0 3px #000000;<br />
&nbsp; -moz-box-shadow: inset 0 0 3px #000000;<br />
&nbsp; -webkit-box-shadow: inset 0 0 3px #000000;<br />
&nbsp; background: #070707;<br />
&nbsp; background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAxCAIAAACUDVRzAAAAA3NCSVQICAjb4U/gAAAALklEQVQImWNQU9Nh+v//PxMDw3+m//8ZkNj/mRgYIHxy5f//Z0BSi18e2TwS5QG4MGB54HL+mAAAAABJRU5ErkJggg==) 100% 100%; <br />
&nbsp; background: -moz-linear-gradient(top, #26262c 0%, #070707 100%);<br />
&nbsp; background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #26262c), color-stop(100%, #070707));<br />
&nbsp; background: -webkit-linear-gradient(top, #26262c 0%, #070707 100%);<br />
&nbsp; background: -o-linear-gradient(top, #26262c 0%, #070707 100%);<br />
&nbsp; background: -ms-linear-gradient(top, #26262c 0%, #070707 100%);<br />
&nbsp; background: linear-gradient(to bottom, #26262c 0%, #070707 100%);<br />
}<br />
#nav &gt; ul &gt; li:hover &gt; a {<br />
&nbsp; background: #85ad74;<br />
&nbsp; color:#FFF;<br />
&nbsp; background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAxCAIAAACUDVRzAAAAA3NCSVQICAjb4U/gAAAALklEQVQImWNQU9Nh+v//PxMDw3+m//8ZkNj/mRgYIHxy5f//Z0BSi18e2TwS5QG4MGB54HL+mAAAAABJRU5ErkJggg==) 100% 100%; <br />
&nbsp; background: -moz-linear-gradient(top, #b1cfa5 0%, #85ad74 100%);<br />
&nbsp; background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #b1cfa5), color-stop(100%, #85ad74));<br />
&nbsp; background: -webkit-linear-gradient(top, #b1cfa5 0%, #85ad74 100%);<br />
&nbsp; background: -o-linear-gradient(top, #b1cfa5 0%, #85ad74 100%);<br />
&nbsp; background: -ms-linear-gradient(top, #b1cfa5 0%, #85ad74 100%);<br />
&nbsp; background: linear-gradient(to bottom, #b1cfa5 0%, #85ad74 100%);<br />
}<br />
#nav .has-sub {<br />
&nbsp; z-index: 1;<br />
}<br />
#nav .has-sub:hover &gt; ul {<br />
&nbsp; display: block;<br />
}<br />
#nav .has-sub ul {<br />
&nbsp; display: none;<br />
&nbsp; position: absolute;<br />
&nbsp; width: 200px;<br />
&nbsp; top: 100%;<br />
&nbsp; left: 0;<br />
}<br />
#nav .has-sub ul li {<br />
&nbsp; *margin-bottom: -1px;<br />
}<br />
#nav .has-sub ul li a {<br />
&nbsp; background: #85ad74;<br />
&nbsp; border-bottom: 1px dotted #6fc7ec;<br />
&nbsp; filter: none;<br />
&nbsp; font-size: 11px;<br />
&nbsp; display: block;<br />
&nbsp; line-height: 120%;<br />
&nbsp; padding: 10px;<br />
}<br />
#nav .has-sub ul li:hover a {<br />
&nbsp; background: #85ad74;<br />
}<br />
#nav .has-sub .has-sub:hover &gt; ul {<br />
&nbsp; display: block;<br />
}<br />
#nav .has-sub .has-sub ul {<br />
&nbsp; display: none;<br />
&nbsp; position: absolute;<br />
&nbsp; left: 100%;<br />
&nbsp; top: 0;<br />
}<br />
#nav .has-sub .has-sub ul li a {<br />
&nbsp; background: #85ad74;<br />
&nbsp; border-bottom: 1px dotted #6db2d0;<br />
}<br />
#nav .has-sub .has-sub ul li a:hover {<br />
&nbsp; background: #095c80;<br />
}</code><hr />
</div>Thanks in advance :thumbsup:</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=13"><![CDATA[HTML & CSS]]></category>
			<dc:creator>charlyanderson</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295604</guid>
		</item>
		<item>
			<title>using JSON as database</title>
			<link>http://www.codingforums.com/showthread.php?t=295602&amp;goto=newpost</link>
			<pubDate>Sun, 19 May 2013 17:37:23 GMT</pubDate>
			<description><![CDATA[Hi all! 
 
Need a little help here: I need to use a .json file instead of a SQL Database (for framework reasons). It´s gonna be a highscore database for a mobile game and looks like so (example data): 
 
 
Code: 
--------- 
{"Highscores":[ 
    {"Name":"Marina","Time":"2:30","Points":1320}, 
   ...]]></description>
			<content:encoded><![CDATA[<div>Hi all!<br />
<br />
Need a little help here: I need to use a .json file instead of a SQL Database (for framework reasons). It´s gonna be a highscore database for a mobile game and looks like so (example data):<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left">{&quot;Highscores&quot;:[<br />
&nbsp; &nbsp; {&quot;Name&quot;:&quot;Marina&quot;,&quot;Time&quot;:&quot;2:30&quot;,&quot;Points&quot;:1320},<br />
&nbsp; &nbsp; {&quot;Name&quot;:&quot;Stefano&quot;,&quot;Time&quot;:&quot;2:32&quot;,&quot;Points&quot;:1319},<br />
&nbsp; &nbsp; {&quot;Name&quot;:&quot;Christine&quot;,&quot;Time&quot;:&quot;1:30&quot;,&quot;Points&quot;:2435},<br />
&nbsp; &nbsp; {&quot;Name&quot;:&quot;Michael&quot;,&quot;Time&quot;:&quot;3:42&quot;,&quot;Points&quot;:878},<br />
&nbsp; &nbsp; {&quot;Name&quot;:&quot;Myriam&quot;,&quot;Time&quot;:&quot;1:55&quot;,&quot;Points&quot;:2590},<br />
&nbsp; &nbsp; ]}</code><hr />
</div>Now I need to READ and WRITE into that &quot;database&quot; but have no clue how to do this. I managed to insert a row like this:<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left">function setHighscore(newtime, newhighscore, newname) {<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; //open highscore.json<br />
&nbsp; &nbsp; &nbsp; &nbsp; var dh = Stream.openFile(this._datei,&quot;r&quot;);<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; var jsonobject=parseData(dh);//h.toString();<br />
&nbsp; &nbsp; &nbsp; &nbsp; dh.close;<br />
<br />
&nbsp; &nbsp; &nbsp;  //set new values<br />
&nbsp; &nbsp; &nbsp; &nbsp; jsonobject[&quot;Highscores&quot;][5][&quot;Time&quot;]=newtime;<br />
&nbsp; &nbsp; &nbsp; &nbsp; jsonobject[&quot;Highscores&quot;][5][&quot;Points&quot;]=newhighscore;<br />
&nbsp; &nbsp; &nbsp; &nbsp; jsonobject[&quot;Highscores&quot;][5][&quot;Name&quot;]=newname;<br />
<br />
&nbsp; &nbsp; &nbsp;  <br />
&nbsp; &nbsp; &nbsp; &nbsp; var dh2 = Stream.openFile(this._datei,&quot;w+&quot;);<br />
&nbsp; &nbsp; &nbsp; &nbsp; dh2.printf(&quot;%v&quot;,jsonobject);<br />
&nbsp; &nbsp; &nbsp; &nbsp; dh2.close();<br />
&nbsp; &nbsp; }</code><hr />
</div>however this only works if I have an empty data-record on position &quot;5&quot; which will then be filled. But I want it to append whatever new values to the END of the array. since the highscore database will be growing it should determine the last position and insert the new values accordingly.<br />
<br />
Next thing, I also need to display the &quot;Top Ten&quot; of this database on a seperate screen. I´m a noob so please bear with me. This is what I tried to retrieve data:<br />
<br />
<div style="margin:20px; margin-top:5px">
	<div class="smallfont" style="margin-bottom:2px">Code:</div>
	<hr /><code style="margin:0px" dir="ltr" style="text-align:left">function getHighscore(nr) {<br />
&nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; //TODO: Exceptions<br />
&nbsp; &nbsp; &nbsp; &nbsp; var dh = Stream.openFile(this._datei,&quot;r&quot;);<br />
&nbsp; &nbsp; &nbsp; &nbsp; //Parse JSON File<br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; var data = parseData(dh);<br />
&nbsp; &nbsp; &nbsp; &nbsp; //return data<br />
&nbsp; &nbsp; &nbsp; &nbsp; console &lt;&lt; data[&quot;Highscores&quot;][nr-1][&quot;Time&quot;];<br />
&nbsp; &nbsp; &nbsp; &nbsp; //dh.print(text);<br />
&nbsp; &nbsp; &nbsp; &nbsp; dh.close;<br />
&nbsp; &nbsp; }</code><hr />
</div>this works fine for just one parameter (in this case Time) but as soon as I add the other ones (name, points) it returns &quot;undefined&quot;. What am I doing wrong here?<br />
<br />
btw I´m using Moscrif framework which is a JavaScript derivate...but very similar to it.<br />
<br />
many thanks in advance</div>

]]></content:encoded>
			<category domain="http://www.codingforums.com/forumdisplay.php?f=2">JavaScript programming</category>
			<dc:creator>tchintchie</dc:creator>
			<guid isPermaLink="true">http://www.codingforums.com/showthread.php?t=295602</guid>
		</item>
	</channel>
</rss>
