<?xml version="1.0" encoding="UTF-8"?>    <rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
      <channel>
        <title>Get record # from end of url error</title>
        <link>https://interactivetools.com/forum/forum-posts.php?Get-record-from-end-of-url-error-80087</link>
        <description></description>
        <pubDate>Fri, 10 Apr 2026 09:13:22 -0700</pubDate>
        <language>en-us</language>
        <atom:link href="https://interactivetools.com/forum/forum-posts.php?rss=1&amp;Get-record-from-end-of-url-error-80087" rel="self" type="application/rss+xml" />

                <item>
          <title>Get record # from end of url error</title>
          <link>https://interactivetools.com/forum/forum-posts.php?postNum=2236809#post2236809</link>
          <description><![CDATA[<p>Duh!</p>
<p>I could just kick myself -  thanks Clair.</p>
]]></description>
          <pubDate>Wed, 03 Jun 2015 12:15:25 -0700</pubDate>
          <guid isPermaLink="true">forum-posts.php?postNum=2236809#post2236809</guid>
        </item>
                <item>
          <title>Get record # from end of url error</title>
          <link>https://interactivetools.com/forum/forum-posts.php?postNum=2236808#post2236808</link>
          <description><![CDATA[<p>Yeah, you're missing a 'where' parameter there. You need to tell the getRecords that the record to get has a num of 3. like so:</p>
<p><code>// load record from 'code_types'<br />   list($code_typesRecords, $code_typesMetaData) = getRecords(array(<br />     'tableName'   =&gt; 'code_types',<br />    'where'       =&gt; 'num = '. mysql_escape($_REQUEST['num']),<br />     'orderBy'     =&gt; 'title',<br />     ));<br />   $code_typesRecord = @$claim_typesRecords[0]; // get first record</code></p>
]]></description>
          <pubDate>Wed, 03 Jun 2015 12:09:28 -0700</pubDate>
          <guid isPermaLink="true">forum-posts.php?postNum=2236808#post2236808</guid>
        </item>
                <item>
          <title>Get record # from end of url error</title>
          <link>https://interactivetools.com/forum/forum-posts.php?postNum=2236806#post2236806</link>
          <description><![CDATA[<p>The get record should grab the record number from the end of the URL such as code_type?num=3!</p>
<p>Do I have an incorrect 'get' statement?</p>]]></description>
          <pubDate>Wed, 03 Jun 2015 12:05:34 -0700</pubDate>
          <guid isPermaLink="true">forum-posts.php?postNum=2236806#post2236806</guid>
        </item>
                <item>
          <title>Get record # from end of url error</title>
          <link>https://interactivetools.com/forum/forum-posts.php?postNum=2236805#post2236805</link>
          <description><![CDATA[<p>Okay, what's the action variable on the &lt;form&gt; tag?</p>
<p>Also, this getRecords for the code type doesn't appear to be getting any specific record - is that intended?</p>
<p><code>// load record from 'code_types'<br />   list($code_typesRecords, $code_typesMetaData) = getRecords(array(<br />     'tableName'   =&gt; 'code_types',<br />     'orderBy'     =&gt; 'title',<br />     ));<br />   $code_typesRecord = @$claim_typesRecords[0]; // get first record</code></p>
]]></description>
          <pubDate>Wed, 03 Jun 2015 12:01:03 -0700</pubDate>
          <guid isPermaLink="true">forum-posts.php?postNum=2236805#post2236805</guid>
        </item>
                <item>
          <title>Get record # from end of url error</title>
          <link>https://interactivetools.com/forum/forum-posts.php?postNum=2236803#post2236803</link>
          <description><![CDATA[<p>Hi Claire,</p>
<p>On submit it should append the record num to the end of the URL and subsequently load the page with the data. The URL address 'code-type-edit.php?num=3' should work. It maybe in the PHP header code!</p>
<p><code>&lt;?php header('Content-type: text/html; charset=utf-8'); ?&gt;<br />&lt;?php require_once "../cmsAdmin/lib/viewer_functions.php"; ?&gt;<br />&lt;?php if (!$CURRENT_USER) { websiteLogin_redirectToLogin(); } ?&gt;<br />&lt;?php<br />  /* STEP 1: LOAD RECORDS - Copy this PHP code block near the TOP of your page */<br />  <br />  // load viewer library<br />  $libraryPath = '../cmsAdmin/lib/viewer_functions.php';<br />  $dirsToCheck = array('/home/report/public_html/','','../','../../','../../../');<br />  foreach ($dirsToCheck as $dir) { if (@include_once("$dir$libraryPath")) { break; }}<br />  if (!function_exists('getRecords')) { die("Couldn't load viewer library, check filepath in sourcecode."); }<br /><br />  <br /> // load record from 'code_types'<br />  list($code_typesRecords, $code_typesMetaData) = getRecords(array(<br />    'tableName'   =&gt; 'code_types',<br />    'orderBy'     =&gt; 'title',<br />    ));<br />  $code_typesRecord = @$claim_typesRecords[0]; // get first record<br /><br />    <br />  // load records from 'agency'<br />  list($agencyRecords, $agencyMetaData) = getRecords(array(<br />    'tableName'   =&gt; 'agency',<br />    'orderBy'     =&gt; 'agency_name',<br />    'loadUploads' =&gt; false,<br />    'allowSearch' =&gt; false,<br />  ));<br /><br />   $index_color = "15497D";<br />   //$index_color = "0944CE";<br />   $sub_color   = "C5D9ED";<br />   //$sub_color = "#92";<br />   $errorsAndAlerts = "";<br /><br />  //<br />  $showSignupForm = true;<br /><br />  // process form<br />  if (@$_REQUEST['save']) {<br /><br />        <br />    // turn off strict mysql error checking for: STRICT_ALL_TABLES<br />    mysqlStrictMode(false); // disable Mysql strict errors for when a field isn't defined below (can be caused when fields are added later)<br /><br />    // add member company<br />    <br />  <br />      //<br />      $query = "UPDATE `{$TABLE_PREFIX}code_types` SET<br /><br />                      title                        = '".mysql_escape( $_REQUEST['title'] )."',<br />                      company                      = '".mysql_escape( $_REQUEST['company'] )."',               <br />                      discontinue                  = '".mysql_escape( $_REQUEST['discontinue'] )."',<br />                      updatedByUserNum             = '".mysql_escape( $CURRENT_USER['num'] )."',<br />                      updatedDate                  = NOW()<br />                      <br />                 WHERE num = '".mysql_escape( $_REQUEST['num'] )."'";<br />      mysql_query($query) or die("MySQL Error:&lt;br/&gt;\n". htmlspecialchars(mysql_error()) . "\n");<br />      $userNum = mysql_insert_id();<br /><br /><br />      // show thanks<br />      $errorsAndAlerts  = "Thanks, We've created/updated your Code Type.&lt;br/&gt;&lt;br/&gt;\n";<br />      $errorsAndAlerts .= "&lt;a href='<a href="http://www.reportpro1.com/start/code_types.php" rel="nofollow">http://www.reportpro1.com/start/code_types.php</a>'&gt;Click here to enter/edit another Code Type&lt;/a&gt;.";<br /><br />      $_REQUEST        = array(); // clear form values<br />      $showSignupForm  = false;<br />  <br />     }<br />   else<br />    // prepopulate form with current user values<br />    foreach ($code_typesRecords as $name =&gt; $value) {<br />    if (array_key_exists($name, $_REQUEST)) { continue; }<br />    $_REQUEST[$name] = $value;<br />  }<br />  <br />   $index_color = "15497D";<br />   //$index_color = "0944CE";<br />   $sub_color   = "C5D9ED";<br />  //$sub_color = "#92";<br /><br /><br />?&gt;<br /></code></p>
]]></description>
          <pubDate>Wed, 03 Jun 2015 11:37:03 -0700</pubDate>
          <guid isPermaLink="true">forum-posts.php?postNum=2236803#post2236803</guid>
        </item>
                <item>
          <title>Get record # from end of url error</title>
          <link>https://interactivetools.com/forum/forum-posts.php?postNum=2236802#post2236802</link>
          <description><![CDATA[<p>I think I need more info here. Can you tell me what kind of behaviour are you seeing when the form is submitted? What are the contents of the $_REQUEST array?</p>
<p>I don't see anything offhand that looks wrong about this code.</p>]]></description>
          <pubDate>Wed, 03 Jun 2015 09:06:17 -0700</pubDate>
          <guid isPermaLink="true">forum-posts.php?postNum=2236802#post2236802</guid>
        </item>
                <item>
          <title>Get record # from end of url error</title>
          <link>https://interactivetools.com/forum/forum-posts.php?postNum=2236800#post2236800</link>
          <description><![CDATA[<p>I have the following code below. When I submit the selected 'num' will not execute through to the URL - any ideas what I'm doing wrong here?</p>
<p>Thanks - nmsinc</p>
<p><code>&lt;select name="num"&gt;<br />&lt;?php foreach ($code_typesRecords as $type): ?&gt;<br />&lt;?php if ($CURRENT_USER['isAdmin']): ?&gt;<br />&lt;?php if ($type['discontinue'] = '0' || !$type['discontinue']): ?&gt;<br />&lt;option value = "&lt;?php echo $type['num'];?&gt;"&gt;&lt;?php echo $type['title'];?&gt; - &lt;?php echo $type['company:label'];?&gt;&lt;/option&gt;<br />&lt;?php else: ?&gt;<br />&lt;option value = "&lt;?php echo $type['num'];?&gt;"&gt;&lt;?php echo $type['title'];?&gt; - DISCONTINUED - &lt;?php echo $type['company:label'];?&gt;&lt;/option&gt;<br />&lt;?php endif; ?&gt;<br />&lt;?php elseif ($type['company'] == $CURRENT_USER['assigned_to']): ?&gt;<br />&lt;?php if ($type['discontinue'] = '0' || !$type['discontinue']): ?&gt;<br />&lt;option value = "&lt;?php echo $type['num'];?&gt;"&gt;&lt;?php echo $type['title'];?&gt;&lt;/option&gt;<br />&lt;?php else: ?&gt;<br />&lt;option value = "&lt;?php echo $type['num'];?&gt;"&gt;&lt;?php echo $type['title'];?&gt; - DISCONTINUED&lt;/option&gt;<br />&lt;?php endif; ?&gt;<br />&lt;?php endif; ?&gt;<br />&lt;?php endforeach ?&gt;<br />&lt;/select&gt;<br />                            &lt;input type="submit" name="submit" value="Edit Claim Type"&gt;</code></p>
]]></description>
          <pubDate>Wed, 03 Jun 2015 06:27:14 -0700</pubDate>
          <guid isPermaLink="true">forum-posts.php?postNum=2236800#post2236800</guid>
        </item>
              </channel>
    </rss>
  