Search found 8 matches
- Mon Oct 07, 2013 1:04 pm
- Forum: PHP - Code
- Topic: Problems clipping & displaying an image
- Replies: 0
- Views: 764
Problems clipping & displaying an image
I am trying to upload an image, extract a clip of a particular size and display that clip. I have some code that will do that, however, I don't know how to use it within the context of an actual page as it includes the use of header() which crashes the code since it is not the first thing sent to th...
- Thu Sep 30, 2010 4:34 pm
- Forum: PHP - Code
- Topic: Mystery array
- Replies: 3
- Views: 93
Re: Mystery array
Well, I solved the problem with help from another forum. Somehow, I was generating a multidimensional array with out noticing it.
Thanks,
--Kenoli
Thanks,
--Kenoli
- Thu Sep 30, 2010 2:47 pm
- Forum: PHP - Code
- Topic: Mystery array
- Replies: 3
- Views: 93
Mystery array
In the following code, $admin->editPage($id) returns an array from an object method with column data from a row in a table. Here's the method that returns the array: public function editPage ($id) { global $db; $query = "SELECT * FROM web_content WHERE id_content = '$id'"; $result = mysql_...
- Tue Jun 03, 2008 7:58 pm
- Forum: PHP - Code
- Topic: looping through multiple arrays
- Replies: 5
- Views: 291
Re: looping through multiple arrays
Everah -- Thanks for your attention and patience. Your solution makes a lot sense for accessing the data from each array. I'm not sure if it gets me what I need. I'm still feeling a bit clueless. I'm trying to update a database with a query made up of elements from each array combined into one query...
- Tue Jun 03, 2008 12:43 am
- Forum: PHP - Code
- Topic: looping through multiple arrays
- Replies: 5
- Views: 291
Re: looping through multiple arrays
Everah wrote: >>What is not working for you the way it is now? I am only looping through one of the arrays. I don't know how to loop through both of them. I want to be able to do something like: foreach . . . { $query = "UPDATE table SET column1 = '$_POST['test']', column2 = '$_POST['help']' WH...
- Mon Jun 02, 2008 9:20 pm
- Forum: PHP - Code
- Topic: looping through multiple arrays
- Replies: 5
- Views: 291
looping through multiple arrays
I am trying to capture the data from a form with several fields in a way that I can update a number of database records, each with several fields, from one form submittal. I can capture the data from one of the form inputs like this: <?php if ($_POST['Submit']) { foreach($_POST['test'] as $ke...
- Tue Oct 24, 2006 5:31 pm
- Forum: Regex
- Topic: Practical application of regex in forms
- Replies: 3
- Views: 1994
Practical application of regex in forms
Guess I have to bite the bullet. So, here's a specific question. What is a good way to validate phone numbers when they are coming from many different countries, since there are so many different formats and different habits, like some people include country codes and others do not (most people from...
- Tue Oct 24, 2006 10:36 am
- Forum: Regex
- Topic: Practical application of regex in forms
- Replies: 3
- Views: 1994
Practical application of regex in forms
I wonder if anyone can point me to a good discussion about the practical application of regex in forms. Trying to validate every field in a form can be quite daunting and it seems necessary to make some choices about what is validated and to what degree. I'm interested in what experienced coders hav...