<?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>PHPBuilder.com - ClientSide Technologies</title>
		<link>http://board.phpbuilder.com/</link>
		<description>Discuss HTML/CSS/Javascript, and any other client-side technologies, here.</description>
		<language>en</language>
		<lastBuildDate>Sun, 19 May 2013 05:49:21 GMT</lastBuildDate>
		<generator>vBulletin</generator>
		<ttl>60</ttl>
		<image>
			<url>http://board.phpbuilder.com/images/misc/rss.png</url>
			<title>PHPBuilder.com - ClientSide Technologies</title>
			<link>http://board.phpbuilder.com/</link>
		</image>
		<item>
			<title>Iterate through JSON data like a multi-d array?/Show all fields/vals for clicked row?</title>
			<link>http://board.phpbuilder.com/showthread.php?10389717-Iterate-through-JSON-data-like-a-multi-d-array-Show-all-fields-vals-for-clicked-row&amp;goto=newpost</link>
			<pubDate>Wed, 15 May 2013 18:30:45 GMT</pubDate>
			<description><![CDATA[Hi;  My head hurts.  I am not _quite_ getting this JSON object stuff.

Three goals here:
1. Run a MySQL query and return the results in JSON
(I can do this...it seems to work fine) 

2. show a table that shows short/summary CLICKABLE record rows (that show just a couple of the fields for each of the JSON rows/elements) ...
(I've actually figured out this first part and it seems to work fine)

3. The result of clicking on a specific row (in the table refered to above) results a display in a table/form being shown that will show ALL fields/values for that specific, clicked record.
When I click a row, the row ID _does_ magically appear in the <span> tags located above the summary table.
(THIS IS WHERE I AM STUCK...instead of just seeing that number, I want to see all available details for that specific record/row)

[I can do all of this stuff in php with sessions, and arrays and forms and all that good stuff...but I would like to understand how to do this in javascript/client-side in order to make use of the page more efficient]

Here is the code that seems to be working fine to accomplish steps 1 and 2.
My offerdata.js file:

Code:
---------
$(document).ready(function() {	
$.getJSON('offerdata.php', function(data) {//a summary table that shows, say, 4 out of 12 fields that exist in JSON for each row
      var table='<table>'; 
      	 table+='<tr><th>OFFER_ID</th><th>PROPERTY</th><th>STAFF</th><th>OFFER_STATUS</th></tr><tbody class="hrow">';   
      $.each(data, function(index, item){
	 table+='<tr valign="top"onclick="selectRow(this)" id="'+index+'"><td>'+item.OFFER_ID+'</td><td>'+item.PROPERTY+'</td><td>'+item.STAFF+'</td><td>'+item.OFFER_STATUS+'</td></tr>';
       });
      table+='</tbody></table>';
      $("#content").html(table);	//refer to this id in <table> tags back at the page 
});	
});
---------
and back in the <body> of the page, I have this:

HTML:
---------
<span id="offer_id"></span><hr />
<!-- I would like to have a details table to appear here when any row is clicked (all details for that row)  ie. for each field that exists in the JSON for that selected row <tr><th>$fld</th><td>$val</td></tr> --->
<table id="content"></table>
---------
I am assuming, because I _CAN_ see my summary table, that the complete JSON array (object?) remains available to populate the details table I would like to be able to display.

Somebody give me a nudge in the right direction?

Thanks.]]></description>
			<content:encoded><![CDATA[<div>Hi;  My head hurts.  I am not _quite_ getting this JSON object stuff.<br />
<br />
Three goals here:<br />
1. Run a MySQL query and return the results in JSON<br />
(I can do this...it seems to work fine) <br />
<br />
2. show a table that shows short/summary CLICKABLE record rows (that show just a couple of the fields for each of the JSON rows/elements) ...<br />
(I've actually figured out this first part and it seems to work fine)<br />
<br />
3. The result of clicking on a specific row (in the table refered to above) results a display in a table/form being shown that will show ALL fields/values for that specific, clicked record.<br />
When I click a row, the row ID _does_ magically appear in the &lt;span&gt; tags located above the summary table.<br />
(THIS IS WHERE I AM STUCK...instead of just seeing that number, I want to see all available details for that specific record/row)<br />
<br />
[I can do all of this stuff in php with sessions, and arrays and forms and all that good stuff...but I would like to understand how to do this in javascript/client-side in order to make use of the page more efficient]<br />
<br />
Here is the code that seems to be working fine to accomplish steps 1 and 2.<br />
My offerdata.js file:<br />
<div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">$(document).ready(function() {&nbsp; &nbsp; &nbsp; &nbsp; <br />
$.getJSON('offerdata.php', function(data) {//a summary table that shows, say, 4 out of 12 fields that exist in JSON for each row<br />
&nbsp; &nbsp; &nbsp; var table='&lt;table&gt;'; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  table+='&lt;tr&gt;&lt;th&gt;OFFER_ID&lt;/th&gt;&lt;th&gt;PROPERTY&lt;/th&gt;&lt;th&gt;STAFF&lt;/th&gt;&lt;th&gt;OFFER_STATUS&lt;/th&gt;&lt;/tr&gt;&lt;tbody class=&quot;hrow&quot;&gt;';&nbsp;  <br />
&nbsp; &nbsp; &nbsp; $.each(data, function(index, item){<br />
&nbsp; &nbsp; &nbsp; &nbsp;  table+='&lt;tr valign=&quot;top&quot;onclick=&quot;selectRow(this)&quot; id=&quot;'+index+'&quot;&gt;&lt;td&gt;'+item.OFFER_ID+'&lt;/td&gt;&lt;td&gt;'+item.PROPERTY+'&lt;/td&gt;&lt;td&gt;'+item.STAFF+'&lt;/td&gt;&lt;td&gt;'+item.OFFER_STATUS+'&lt;/td&gt;&lt;/tr&gt;';<br />
&nbsp; &nbsp; &nbsp;  });<br />
&nbsp; &nbsp; &nbsp; table+='&lt;/tbody&gt;&lt;/table&gt;';<br />
&nbsp; &nbsp; &nbsp; $(&quot;#content&quot;).html(table);&nbsp; &nbsp; &nbsp; &nbsp; //refer to this id in &lt;table&gt; tags back at the page <br />
});&nbsp; &nbsp; &nbsp; &nbsp; <br />
});</code><hr />
</div> and back in the &lt;body&gt; of the page, I have this:<br />
<div class="bbcode_container">
	<div class="bbcode_description">HTML Code:</div>
	<hr /><code class="bbcode_code"><span style="color:#000080">&lt;span id=<span style="color:#0000FF">&quot;offer_id&quot;</span>&gt;</span><span style="color:#000080">&lt;/span&gt;</span><span style="color:#000080">&lt;hr /&gt;</span><br />
<i><span style="color:#000080">&lt;!-- I would like to have a details table to appear here when any row is clicked (all details for that row)&nbsp; ie. for each field that exists in the JSON for that selected row &lt;tr&gt;</span><span style="color:#008080">&lt;th&gt;</span>$fld<span style="color:#008080">&lt;/th&gt;</span><span style="color:#008080">&lt;td&gt;</span>$val<span style="color:#008080">&lt;/td&gt;</span><span style="color:#008080">&lt;/tr&gt;</span> ---&gt;</i><br />
<span style="color:#008080">&lt;table id=<span style="color:#0000FF">&quot;content&quot;</span>&gt;</span><span style="color:#008080">&lt;/table&gt;</span></code><hr />
</div> I am assuming, because I _CAN_ see my summary table, that the complete JSON array (object?) remains available to populate the details table I would like to be able to display.<br />
<br />
Somebody give me a nudge in the right direction?<br />
<br />
Thanks.</div>

 ]]></content:encoded>
			<category domain="http://board.phpbuilder.com/forumdisplay.php?27-ClientSide-Technologies">ClientSide Technologies</category>
			<dc:creator>Joseph Sliker</dc:creator>
			<guid isPermaLink="true">http://board.phpbuilder.com/showthread.php?10389717-Iterate-through-JSON-data-like-a-multi-d-array-Show-all-fields-vals-for-clicked-row</guid>
		</item>
		<item>
			<title>Help with setting page size</title>
			<link>http://board.phpbuilder.com/showthread.php?10389705-Help-with-setting-page-size&amp;goto=newpost</link>
			<pubDate>Tue, 14 May 2013 18:47:13 GMT</pubDate>
			<description><![CDATA[Hi, hope someone can help.
I either need a very simple 'set page size' so the "echo" page isn't too large for the table it appears in or somehow change dimensions somewhere.
I am using a PHP form, where people type in the fields in feedback.php, and when they submit, it parses to sendemail.php with the following response:

Thanks for your<br> entry <?php echo $visitor ?>. Good luck!

(I am all a bit new to this so I apologise, especially if my terminology usage is out.)

Unfortunately, as the image below shows (comparing the before and after sumbission), the sendemail.php is taking up too much space in the rounded table.  It's for a facebook app I am trying to build.  

Attachment 4889 (http://board.phpbuilder.com/attachment.php?attachmentid=4889)]]></description>
			<content:encoded><![CDATA[<div>Hi, hope someone can help.<br />
I either need a very simple 'set page size' so the &quot;echo&quot; page isn't too large for the table it appears in or somehow change dimensions somewhere.<br />
I am using a PHP form, where people type in the fields in feedback.php, and when they submit, it parses to sendemail.php with the following response:<br />
<br />
Thanks for your&lt;br&gt; entry &lt;?php echo $visitor ?&gt;. Good luck!<br />
<br />
(I am all a bit new to this so I apologise, especially if my terminology usage is out.)<br />
<br />
Unfortunately, as the image below shows (comparing the before and after sumbission), the sendemail.php is taking up too much space in the rounded table.  It's for a facebook app I am trying to build.  <br />
<br />
<a href="http://board.phpbuilder.com/attachment.php?attachmentid=4889"  title="Name:  
Views: 
Size:  ">Attachment 4889</a></div>


	<div style="padding:10px">

	

	

	
		<fieldset class="fieldset">
			<legend>Attached Images</legend>
			<ul>
			<li>
	<img class="inlineimg" src="/jpg.gif" alt="File Type: jpg" />
	<a href="http://board.phpbuilder.com/attachment.php?attachmentid=4889&amp;d=1368557150" target="_blank">error.jpg&lrm;</a> 
(37.6 KB)
</li> 
			</ul>
			</fieldset>
	

	

	</div>
 ]]></content:encoded>
			<category domain="http://board.phpbuilder.com/forumdisplay.php?27-ClientSide-Technologies">ClientSide Technologies</category>
			<dc:creator>Mike_ZA</dc:creator>
			<guid isPermaLink="true">http://board.phpbuilder.com/showthread.php?10389705-Help-with-setting-page-size</guid>
		</item>
		<item>
			<title>jQuery Hiding the close button URL for jQueryUI.dialog()</title>
			<link>http://board.phpbuilder.com/showthread.php?10389567-Hiding-the-close-button-URL-for-jQueryUI.dialog()&amp;goto=newpost</link>
			<pubDate>Tue, 30 Apr 2013 08:49:10 GMT</pubDate>
			<description><![CDATA[Hello,

When the mouse is over X (close) button on the dialog window, URL seems in the status bar. I want to hide this URL.
How can I do this?

PHP:
---------
<script>
$(function() {
$( "#dialog" ).dialog({
        width: 800,
        height: "auto",
autoOpen: false,
resizable: false,
show: {
effect: "blind",
duration: 1000
},
hide: {
effect: "explode",
duration: 1000
}
});

$( "#opener" ).click(function() {
$( "#dialog" ).dialog( "open" );
});
});
</script>
---------

HTML:
---------
<div id="dialog" title="SÖZLE&#350;ME METN&#304;">
<p><?=$oku['sozlesme_metni']?></p>
</div>
---------

Thank you in advance]]></description>
			<content:encoded><![CDATA[<div>Hello,<br />
<br />
When the mouse is over X (close) button on the dialog window, URL seems in the status bar. I want to hide this URL.<br />
How can I do this?<br />
<div class="bbcode_container">
	<div class="bbcode_description">PHP Code:</div>
	<hr /><code class="bbcode_code"><code><span style="color: #000000">
<span style="color: #0000BB"></span><span style="color: #007700">&lt;</span><span style="color: #0000BB">script</span><span style="color: #007700">&gt;<br />$(function()&nbsp;{<br />$(&nbsp;</span><span style="color: #DD0000">"#dialog"&nbsp;</span><span style="color: #007700">).</span><span style="color: #0000BB">dialog</span><span style="color: #007700">({<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">width</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">800</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">height</span><span style="color: #007700">:&nbsp;</span><span style="color: #DD0000">"auto"</span><span style="color: #007700">,<br /></span><span style="color: #0000BB">autoOpen</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">false</span><span style="color: #007700">,<br /></span><span style="color: #0000BB">resizable</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">false</span><span style="color: #007700">,<br /></span><span style="color: #0000BB">show</span><span style="color: #007700">:&nbsp;{<br /></span><span style="color: #0000BB">effect</span><span style="color: #007700">:&nbsp;</span><span style="color: #DD0000">"blind"</span><span style="color: #007700">,<br /></span><span style="color: #0000BB">duration</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">1000<br /></span><span style="color: #007700">},<br /></span><span style="color: #0000BB">hide</span><span style="color: #007700">:&nbsp;{<br /></span><span style="color: #0000BB">effect</span><span style="color: #007700">:&nbsp;</span><span style="color: #DD0000">"explode"</span><span style="color: #007700">,<br /></span><span style="color: #0000BB">duration</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">1000<br /></span><span style="color: #007700">}<br />});<br /><br />$(&nbsp;</span><span style="color: #DD0000">"#opener"&nbsp;</span><span style="color: #007700">).</span><span style="color: #0000BB">click</span><span style="color: #007700">(function()&nbsp;{<br />$(&nbsp;</span><span style="color: #DD0000">"#dialog"&nbsp;</span><span style="color: #007700">).</span><span style="color: #0000BB">dialog</span><span style="color: #007700">(&nbsp;</span><span style="color: #DD0000">"open"&nbsp;</span><span style="color: #007700">);<br />});<br />});<br /></span><span style="color: #0000BB">&lt;/script&gt;</span>&nbsp;<br /></span>
</code></code><hr />
</div> <div class="bbcode_container">
	<div class="bbcode_description">HTML Code:</div>
	<hr /><code class="bbcode_code"><span style="color:#000080">&lt;div id=<span style="color:#0000FF">&quot;dialog&quot;</span> title=<span style="color:#0000FF">&quot;SÖZLE&#350;ME METN&#304;&quot;</span>&gt;</span><br />
<span style="color:#000080">&lt;p&gt;</span><span style="color:#000080">&lt;?=$oku&#91;'sozlesme_metni'&#93;?&gt;</span><span style="color:#000080">&lt;/p&gt;</span><br />
<span style="color:#000080">&lt;/div&gt;</span></code><hr />
</div> <br />
Thank you in advance</div>

 ]]></content:encoded>
			<category domain="http://board.phpbuilder.com/forumdisplay.php?27-ClientSide-Technologies">ClientSide Technologies</category>
			<dc:creator>gecekule</dc:creator>
			<guid isPermaLink="true">http://board.phpbuilder.com/showthread.php?10389567-Hiding-the-close-button-URL-for-jQueryUI.dialog()</guid>
		</item>
		<item>
			<title>Running PHP as a Background Task</title>
			<link>http://board.phpbuilder.com/showthread.php?10389521-Running-PHP-as-a-Background-Task&amp;goto=newpost</link>
			<pubDate>Thu, 25 Apr 2013 12:26:13 GMT</pubDate>
			<description><![CDATA[Let me start by saying I'm not sure if this is a PHP or Javascript problem.  Here's the situation:

I have an HTML page that displays a Modal Window when it loads.  The window is a small form, which is optional.  If the viewer decides to fill it out, when they click the Submit button the form is validated and, if all is okay, the window is removed and the form data sent (via action=) to a PHP routine for further processing.

I would like the viewer not to be aware of the PHP routine running (there are no messages sent to the viewer from this routine).

I have tried ending the routine with 
Code:
---------
echo "<script>history.back();</script>";
---------
 and that returns the viewer to the HTML page without the Modal window being redisplayed in every browser that I've tried, except for IE, which redisplays the HTML page (with the Modal Window active).  So, I have 2 questions:

1) Is it possible to have the PHP routine run in the background (so the viewer never leaves the HTML page?

2) If not, is there a way to have IE just return to the HTML page without reloading it?

Thanks in advance for your help.]]></description>
			<content:encoded><![CDATA[<div>Let me start by saying I'm not sure if this is a PHP or Javascript problem.  Here's the situation:<br />
<br />
I have an HTML page that displays a Modal Window when it loads.  The window is a small form, which is optional.  If the viewer decides to fill it out, when they click the Submit button the form is validated and, if all is okay, the window is removed and the form data sent (via action=) to a PHP routine for further processing.<br />
<br />
I would like the viewer not to be aware of the PHP routine running (there are no messages sent to the viewer from this routine).<br />
<br />
I have tried ending the routine with <div class="bbcode_container">
	<div class="bbcode_description">Code:</div>
	<hr /><code class="bbcode_code">echo &quot;&lt;script&gt;history.back();&lt;/script&gt;&quot;;</code><hr />
</div>  and that returns the viewer to the HTML page without the Modal window being redisplayed in every browser that I've tried, except for IE, which redisplays the HTML page (with the Modal Window active).  So, I have 2 questions:<br />
<br />
1) Is it possible to have the PHP routine run in the background (so the viewer never leaves the HTML page?<br />
<br />
2) If not, is there a way to have IE just return to the HTML page without reloading it?<br />
<br />
Thanks in advance for your help.</div>

 ]]></content:encoded>
			<category domain="http://board.phpbuilder.com/forumdisplay.php?27-ClientSide-Technologies">ClientSide Technologies</category>
			<dc:creator>jimweinberg</dc:creator>
			<guid isPermaLink="true">http://board.phpbuilder.com/showthread.php?10389521-Running-PHP-as-a-Background-Task</guid>
		</item>
	</channel>
</rss>
