Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. Tarianna

    Passing Data Thru Pages

    Thanks Spookie for verifying what I thought I shoudl do. Yes it's a LOT easier to do a database hit than it is to attempt to 'cache' the results. I was reading up on creating an external file and temporary SQL tables which are a maintenance nightmare in the long run.
  2. Tarianna

    Passing Data Thru Pages

    I'm new to html programming, perl and the like...and need advice and could use a few insights on how to tackle this problem. I'm writing the paging part of a simple search web application where a query returned more results than it can display. I'm using perl, cgi, html templates and mysql. I...
  3. Tarianna

    How to ref and pass an array of hash from HTML template to cgi script

    Ok, I think avoiding the complex multidimensional array is a good idea! It wasn't my code, it's currently in an existing program that I need to work around. O.o The data is read into a structure like I described before and i figured out a way to put it into a simpler structure and yet not...
  4. Tarianna

    How to handle single/double quotes when inputing?

    I wrote a validation routine to handle invalid input but if the user types in a single or double quote in the first column of any text input in a html page, then the code appears in the input box: <input id="itemNum" type="text" name="itemNum" value='> I'm unsure how to handle this. I'm...
  5. Tarianna

    How to access a hash vairable if in a while loop?

    I'm going to have to try it today in a .pl program. It differs in this way: in my cgi script..when I type: $debug2Template->param(s4=>"listprice: $row{'00001'}->{'LISTPRCE'}"; I'd expect to see the listprice that I just init'ed with $row with. But instead, it's blank. But if i replace...
  6. Tarianna

    How to access a hash vairable if in a while loop?

    Agh! I was mistaken. Removing the quotes did not make any difference. I want this as a result: $row{'00001'} = {'ITEMDESC'=> $data_row[1], ... etc} without having to hardcode the '00001' into the assignment statement like so: $row{$data_row[0]} = {'ITEMDESC'=> $data_row[1], ... etc}...
  7. Tarianna

    How to access a hash vairable if in a while loop?

    Nm! I found the answer...all i Had to do was remove the quotes (double or single) and it's interpreted and assigned the way I want it to. :) Yay!
  8. Tarianna

    How to access a hash vairable if in a while loop?

    Hello all, I want to add to a hash, values read in after a sql sth read. while (my @data_row = $sth->fetchrow_array){ #$row {'00001'} = {'ITEMDESC' => $data_row[1], $row {"$data_row[0]"} = {'ITEMDESC' => $data_row[1], 'LISTPRCE' => FormatPrice($data_row[2]), 'ITEMQTY' => $data_row[3]...
  9. Tarianna

    Drop Box Form values retain values after POSTing?

    Hello Chris, After reading your post, y'know that's what I do (yeah caught me at a lie *gasp* It was crazy yesterday..sorry.) What I do is I pass parms to the display cgi, it queries, it displays the results. Right now, if the user wants to sort on another column, it requeries and sorts it...
  10. Tarianna

    Drop Box Form values retain values after POSTing?

    Hrmm..I like that solution...inserting the selected word when the list is being generated. That's actually what I want. BUT..I've already put in the code to have the top option always selected and inserted the user's choice there (where it starts at the defaulted value for that type of...
  11. Tarianna

    Drop Box Form values retain values after POSTing?

    Hello all, I hope I'm posting in the right forum. O.o Data is going from cgi to form...given a value for a drop down box choice, and given also that the drop down box values are dynamically generated. How can you preserve the value of a drop down box choice a user has chosen after it's been...
  12. Tarianna

    How to ref and pass an array of hash from HTML template to cgi script

    Nm! I just discovered dereferencing ($$)! wowee. ok, I have a lot to do today and when (and if) I'm able to get back to this subject, I'll use that in my sort command. I believe that was the source of my problem..I didn't know how to DE-reference a referenced variable. :)) One problem...
  13. Tarianna

    How to ref and pass an array of hash from HTML template to cgi script

    Thanks for taking the time to help me. I've been thru several references and many tutorials for the last few days..I'm sure one more won't hurt me. Ok, here it is..the code that inits the array of hashes. <do the query sql statement here> my @rows; while (my...
  14. Tarianna

    How to ref and pass an array of hash from HTML template to cgi script

    I wish I could simply use Data::Dumper to display this array of referenced hashes but it's in a cgi script and that script gets info that's run by another cgi script...like so: 1. Input.cgi : asks for 10 or so values (user hits submit) 2. display.cgi: sql query done here and then displayed...
  15. Tarianna

    How to ref and pass an array of hash from HTML template to cgi script

    Hello Keith, Thanks for your reply. :) Yah, the pseudocode I provided is rather loose. I should have posted this comment with it: "assume all work code to be done across 3 to 4 cgi's and multiple displays after each results are achieved for each cgi." (ie. sort.cgi sorts an array of stuff...
  16. Tarianna

    How to ref and pass an array of hash from HTML template to cgi script

    Hello all, I'm fairly new to cgi scripting, html templates and perl. I am trying to sort an array of hash (which represents rows of a table) and having trouble with passing the data from html to cgi script (so I can sort). I know how to pass the array to the template but not vice versa...

Part and Inventory Search

Back
Top