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 TouchToneTommy 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: *

  • Users: rdyoll
  • Content: Threads
  • Order by date
  1. rdyoll

    Raw Mime Questions???

    Hello, I've read the raw mime FAQ (http://www.tek-tips.com/gfaqs.cfm/lev2/4/lev3/32/pid/219/fid/2901) and understand everything except the way in which you actually print the different types of attachments. Let's say you want to attach a .gif. Once you set the Content-Type and disposition, does...
  2. rdyoll

    Easy associative array question

    Hi, In my form I have a select box with the name="beverage". I have 3 options: coffee, tea and milk. I have in my script set up an associative array: $beverage = param('beverage'); %beverage = (coffee => 'Folgers', tea => 'Lipton', milk => 'DairyFresh'); foreach...
  3. rdyoll

    Deleting a cookie

    Hi, I'm setting cookies, and reading them just fine, but how do I delete a cookie. I'm setting the cookie via the print header(-cookie => $cookie); method. Do I just overwrite it, or what? I tried delete(cookie('name')), unlink(cookie('name')) and several others, but to no avail. I've read...
  4. rdyoll

    Perl Back Button Issues.

    I'm trying to come up with a Perl back button in my scripts. I know using the referer will produce this, and generally suits me fine, but sometimes I want to return to the prior invocation of my script and retain the exact state it was in. So, using the self_url() returns the current state of...
  5. rdyoll

    Is there an easy way to find the length of a substring...?

    If I have a variable such as $data ($data will be a string of text), and: if (substr($data, 0) > 30) { do something; } obviously, this does not work. What am I missing?
  6. rdyoll

    How does one find the total (sum) of an array?

    Hi, let's say I have: @numbers = qw/34 56 78 83 23 99 10/; How can I find the "sum" of all the elements in the array? I've tried pushing a "+" (plus sign) into the array and adding it up that way, but there has to be a better way. The total is 383, but, I don't know the routine to follow to...
  7. rdyoll

    Limit table cell to only be taller in actual cell needing the extra ro

    Hi, I know the subject line is not very expressive of my dilema, but what I'm trying to accomplish is only allowing the cells in my outputted data table that need to be more than one line high...be only in "that" row, not all rows... I'm using a: foreach $_(@data) { print Tr([...
  8. rdyoll

    Image submit button using CGI.pm shortcut method

    Hi, just wondering if there is a solution for using an image for a submit button using the HTML shortcut. I've tried it using a background image, but not the way you can do it using a regular image and regular syntax: <input type=&quot;image&quot; src=&quot;the_image.gif&quot;>, but, this is...
  9. rdyoll

    Popup Menu (CGI.pm) Question

    Hi, I've written a little script that generates a popup menu with the current and preceeding 29 years (a perpetual date-type select box) that I use in a form. It works fine, but my question is &quot;Is there a better way to set up the array for the years?&quot; Programatically, I'm sure there is...
  10. rdyoll

    Using a require statement with strict?

    Hi, I recently decided to add a configuration companion file to be &quot;required&quot; in one of my scripts. After doing so, I noticed that it wouldn't run using strict mode. Is this the nature of &quot;strict&quot;, or can anyone point out what I am doing wrong? thanx, rdyoll
  11. rdyoll

    Perl CGI Security Issues

    Hi, I'd like to know what security precautions one should always implement in any cgi script. I know you must never trust the browser or the user, but what necessary steps do you need to take to safegaurd your server from malicious attempts. I'm interested in all viewpoints...whether simple...
  12. rdyoll

    Numbers Question

    I'm looking for a regular expression that will allow any number from 0 - 100, but there are some &quot;numbers&quot; that cannot be used. I have a maxlength input of 3 digits, numbers only. Here is the general break-down: numbers, only 0-9 100 is highest - so the only 3 digit number is 100 0...
  13. rdyoll

    Regex for words

    ...suppose I want to find all possible combinations of any word. $string = param('string'); If the string was, say, frost, what would I need to write to get all combinations of the letters in one shot. frost tsorf rostf ostfr stfro tfros sorft orfst and so forth... I know I need to put the...
  14. rdyoll

    Using object oriented syntax throughout a script

    I'm curious to know if it is possible to write a script using 100% object oriented syntax. I know I can use the <<EOF or the regular print &quot;blah, blah&quot;; statements, but how would I use say: print $q->header, $q->start_html, $q->table({-border=>&quot;1&quot;}...
  15. rdyoll

    Understanding X number of results per page.

    Hi, I'm trying to get the logic down for showing X amount of results per page...as in a Guestbook or similar application. I understand how to have the results print on the page, but setting a limit, and creating the link for the remaining results to be displayed on the next page is driving me...

Part and Inventory Search

Back
Top