[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

9.0

Dreamweaver Navigation Bar Problem

Asked by havenboy in Adobe Dreamweaver, Developer Tools, MySQL Server

Tags: navigation bar recordset paging repeat region

HI,  I am fairly new to Dreamweaver CS3 and dynamic websites, I have been working non-stop this week and have several record sets set up and they are dynamically populating tables wth repeat region data from a PHP/MySQL database.

When I display an entire record set the records display correctly.

My problem is when I use a (text field) filter within Dreamweaver (currently single parameter) to define the recordset I want to display in my dynamic table the first page loads pefectly but using the navigation bar "forward arrow" the second page loads but the table results are empty.  And any subsequent forward/back arrow usage means empty tables as well.

I think this is because the variable I define as my text field (i.e. search term) to populate the table is not carrying over to the second page (via the nav button), any heplp on this issue wuld be much appreciated
Thank you in advance for any help offered
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
96:
97:
98:
99:
100:
101:
102:
103:
104:
105:
106:
107:
108:
109:
110:
111:
112:
113:
114:
115:
116:
117:
118:
119:
120:
121:
122:
123:
124:
125:
126:
127:
128:
129:
130:
131:
132:
133:
134:
135:
136:
137:
138:
139:
140:
141:
142:
143:
144:
145:
146:
147:
148:
149:
<?php require_once('Connections/connRecord.php'); ?>
<?php
$currentPage = $_SERVER["PHP_SELF"];
 
$maxRows_rsSearchResults = 40;
$pageNum_rsSearchResults = 0;
if (isset($_GET['pageNum_rsSearchResults'])) {
  $pageNum_rsSearchResults = $_GET['pageNum_rsSearchResults'];
}
$startRow_rsSearchResults = $pageNum_rsSearchResults * $maxRows_rsSearchResults;
 
$colname_rsSearchResults = "-1";
if (isset($_POST['search'])) {
  $colname_rsSearchResults = (get_magic_quotes_gpc()) ? $_POST['search'] : addslashes($_POST['search']);
}
mysql_select_db($database_connRecordGuide, $connRecordGuide);
$query_rsSearchResults = sprintf("SELECT `PRIMARY`, fld_artist_key, fld_title, fld_catalogue, fld_value_08 FROM tbl_albums WHERE fld_artist_key LIKE '%%%s%%'", $colname_rsSearchResults);
$query_limit_rsSearchResults = sprintf("%s LIMIT %d, %d", $query_rsSearchResults, $startRow_rsSearchResults, $maxRows_rsSearchResults);
$rsSearchResults = mysql_query($query_limit_rsSearchResults, $connRecordGuide) or die(mysql_error());
$row_rsSearchResults = mysql_fetch_assoc($rsSearchResults);
 
if (isset($_GET['totalRows_rsSearchResults'])) {
  $totalRows_rsSearchResults = $_GET['totalRows_rsSearchResults'];
} else {
  $all_rsSearchResults = mysql_query($query_rsSearchResults);
  $totalRows_rsSearchResults = mysql_num_rows($all_rsSearchResults);
}
$totalPages_rsSearchResults = ceil($totalRows_rsSearchResults/$maxRows_rsSearchResults)-1;
 
$queryString_rsSearchResults = "";
if (!empty($_SERVER['QUERY_STRING'])) {
  $params = explode("&", $_SERVER['QUERY_STRING']);
  $newParams = array();
  foreach ($params as $param) {
    if (stristr($param, "pageNum_rsSearchResults") == false && 
        stristr($param, "totalRows_rsSearchResults") == false) {
      array_push($newParams, $param);
    }
  }
  if (count($newParams) != 0) {
    $queryString_rsSearchResults = "&" . htmlentities(implode("&", $newParams));
  }
}
$queryString_rsSearchResults = sprintf("&totalRows_rsSearchResults=%d%s", $totalRows_rsSearchResults, $queryString_rsSearchResults);
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
 
<title>Untitled Document</title>
 
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
 
 
 
 
 
 
<link href="Accessible_Design.css" rel="stylesheet" type="text/css" />
<style type="text/css">
<!--
body {
	background-color: #000000;
}
.style2 {color: #FFFFFF}
.style3 {color: #FF0000}
.style4 {color: #FF0000; font-size: small; }
-->
</style></head>
<body class="BodyBackgroundColor">
<img src="spacer.gif" alt="Skip to Content" width="1" height="1" />
<table width="100%" border="0" cellpadding="4" cellspacing="0">
  <tr>
    <td height="114" class="HeaderColor style2"><img src="" alt=" Thumbnail Image" name="image" width="100" height="81" id="image" /></td>
    <td width="100%" class="HeaderColor style2"><table width="573" border="1" cellpadding="2" cellspacing="1" bordercolor="#FF0000">
      <tr valign="bottom" bordercolor="#FF0000">
        <td width="573" class="NavigationBackgroundColor" style="text-align: center"><a href="rrpg_advsearch.html" class="style4">Advanced Search </a> </td>
        <td width="573" class="NavigationBackgroundColor" style="text-align: center"><a href="rrpg_forums.html" class="style4">Forums</a> </td>
        <td width="573" class="NavigationBackgroundColor" style="text-align: center"><a href="rrpg_grading.html" class="style4">Grading/Glossary</a> </td>
        <td width="573" class="NavigationBackgroundColor" style="text-align: center"><a href="rrpg_faq.html" class="style4">FAQ</a> </td>
        <td width="573" class="NavBackgroundColor" style="text-align: center"><a href="rrpg_contactus.html" class="style4">Contact Us </a> </td>
      </tr>
    </table>
        <table width="573" height="25" border="1" bordercolor="#FF0000">
          <tr align="left" valign="top">
            <th width="263" height="38" scope="col"><div align="left">
                <form id="searchart" name="searchart" method="get" action="rrpg_results.php">
                  Artist
                  <label for="textfield"></label>
                  <input type="text" name="search" id="search" />
                  <label for="Submit"></label>
                  <input type="submit" name="Submit" value="Go" id="Submit" />
              </form>
            </div></th>
            <th width="257" scope="col"><form id="searchtit" name="searchtit" method="post" action="rrpg_resultstit.php">
                <label for="label"></label>
              Title
              <input type="text" name="searchtitle" id="label" />
              <label for="label2"></label>
              <input type="submit" name="Submit2" value="Go" id="label2" />
            </form></th>
          </tr>
      </table></td>
  </tr>
</table>
<p class="style2">&nbsp;</p>
 
<table border="1" cellpadding="2" cellspacing="2">
  <tr align="center" valign="top">
    <td height="25"><span class="style2 style2 style3">Record No. </span></td>
    <td height="25"><span class="style3">Artist Key </span></td>
    <td height="25"><span class="style3">Title</span></td>
    <td height="25"><span class="style3">Catalogue</span></td>
    <td height="25"><span class="style2">Value</span></td>
  </tr>
  <?php do { ?>
    <tr>
      <td><span class="style2"><a href="rrpg_detail.php?recordID=<?php echo $row_RsRecordTable['PRIMARY']; ?>"><?php echo $row_rsSearchResults['PRIMARY']; ?></a></span></td>
      <td><span class="style2"><?php echo $row_rsSearchResults['fld_artist_key']; ?></span></td>
      <td><span class="style2"><?php echo $row_rsSearchResults['fld_title']; ?></span></td>
      <td><span class="style2"><?php echo $row_rsSearchResults['fld_catalogue']; ?></span></td>
      <td><span class="style2"><?php echo $row_rsSearchResults['fld_value_08']; ?></span></td>
    </tr>
    <?php } while ($row_rsSearchResults = mysql_fetch_assoc($rsSearchResults)); ?>
</table>
<p class="style2"> Records <?php echo ($startRow_rsSearchResults + 1) ?> to <?php echo min($startRow_rsSearchResults + $maxRows_rsSearchResults, $totalRows_rsSearchResults) ?> of <?php echo $totalRows_rsSearchResults ?>
<table border="0" width="50%" align="center">
  <tr>
    <td width="23%" align="center"><?php if ($pageNum_rsSearchResults > 0) { // Show if not first page ?>
        <a href="<?php printf("%s?pageNum_rsSearchResults=%d%s", $currentPage, 0, $queryString_rsSearchResults); ?>"><img src="First.gif" border=0></a>
        <?php } // Show if not first page ?>
    </td>
    <td width="31%" align="center"><?php if ($pageNum_rsSearchResults > 0) { // Show if not first page ?>
        <a href="<?php printf("%s?pageNum_rsSearchResults=%d%s", $currentPage, max(0, $pageNum_rsSearchResults - 1), $queryString_rsSearchResults); ?>"><img src="Previous.gif" border=0></a>
        <?php } // Show if not first page ?>
    </td>
    <td width="23%" align="center"><?php if ($pageNum_rsSearchResults < $totalPages_rsSearchResults) { // Show if not last page ?>
        <a href="<?php printf("%s?pageNum_rsSearchResults=%d%s", $currentPage, min($totalPages_rsSearchResults, $pageNum_rsSearchResults + 1), $queryString_rsSearchResults); ?>"><img src="Next.gif" border=0></a>
        <?php } // Show if not last page ?>
    </td>
    <td width="23%" align="center"><?php if ($pageNum_rsSearchResults < $totalPages_rsSearchResults) { // Show if not last page ?>
        <a href="<?php printf("%s?pageNum_rsSearchResults=%d%s", $currentPage, $totalPages_rsSearchResults, $queryString_rsSearchResults); ?>"><img src="Last.gif" border=0></a>
        <?php } // Show if not last page ?>
    </td>
  </tr>
</table>
</p>
first page ?>
          First
</td>
[+][-]08/25/09 07:13 PM, ID: 25183967Accepted Solution

View this solution now by starting your 30-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

About this solution

Zones: Adobe Dreamweaver, Developer Tools, MySQL Server
Tags: navigation bar recordset paging repeat region
Sign Up Now!
Solution Provided By: jason1178
Participating Experts: 2
Solution Grade: A
 
[+][-]08/25/09 08:53 PM, ID: 25184313Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/09 08:54 PM, ID: 25184316Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/09 08:57 PM, ID: 25184330Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/09 09:08 PM, ID: 25184378Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/25/09 09:14 PM, ID: 25184396Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/26/09 03:58 AM, ID: 25186194Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/26/09 05:25 AM, ID: 25186766Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091021-EE-VQP-81 - Hierarchy / EE_QW_3_20080625