
davidannis
Members-
Posts
627 -
Joined
-
Last visited
-
Days Won
2
Everything posted by davidannis
-
It will say invalid input if you try to send it twice because of the spam check. If you close and reopen your browser you'll get a new session and it will let you send again.
-
If you just want a secure formmail script, I would suggest using http://www.tectite.com/ instead of coding it yourself.
-
I did it for you send_form_email1.php
-
if you delete the leading whitespace on the lines with red on the left (and then reformat just to make it readable) it should be OK I think.
-
I have heard that the mailto: action type is not always reliable and the reasoning makes sense to me. I often use computers that don't have a mail client configured.
-
I opened the file and you do have a white space character that sows up at the beginning of lines as a little cross in my IDE when I display whitespace.
-
generate unique strings of characters
davidannis replied to needs_upgrade's topic in PHP Coding Help
You could do the md5 thing and just take a substring, but I'd look at modifying this if you want really random strings. -
Try changing $contents = file_get_contents('http://tvlistings.zap2it.com/tvlistings/ZCSGrid.do?stnNum=10179'); to $data = file_get_contents('http://tvlistings.zap2it.com/tvlistings/ZCSGrid.do?stnNum=10179'); also remember that arrays normally start at element 0 not 1 so you are looking for $matches[0] if the data is put into an array.
-
looks like you put the data into $contents and then look for a match in $data. I think you need to use a single variable.
-
Items not showing in My Content
davidannis replied to davidannis's topic in PHPFreaks.com Website Feedback
Thank you. Looks better now. I dropped the ball on replying to a couple of posts but others picked it up. It's nice that it works that way. -
Items not showing in My Content
davidannis replied to davidannis's topic in PHPFreaks.com Website Feedback
I just happened across this post. I commented on it yesterday, but it too is absent from My Content. http://forums.phpfreaks.com/topic/276921-html-select-inside-table/ -
Items not showing in My Content
davidannis replied to davidannis's topic in PHPFreaks.com Website Feedback
It shows nothing since April 9 despite the fact that I've posted a lot since then. It claims a total of 67 posts though my posts say 121. I have selected "topics and posts" and sort by update time. A few examples of things since April 9 This thread and another in this forum about a disappearing (turns out deleted duplicate) thread. and http://forums.phpfreaks.com/topic/276914-confused-not-sure-how-to-go-about-this-do-not-echo-if-same/ I'm pretty sure that there have been others. Thanks, David -
FWIW you can also code it like this echo "<select name=\"category[$value]\">"; and then you get an array $_POST['category'] that looks like this ('myvalue1'=>'mycategory', 'myvalue2'=>'mycat2', ...)
-
I use the "My Content" on the drop down to try to follow up if I have left advice, because the OP may have additional questions, I might have made an error, someone may propose a better solution (and I get to learn from that too) but recently my new comments are not showing up there.
-
You need to allow multiple values for category so change this echo "<select name=\"category\">"; to echo "<select name=\"category[]\">"; You will then get an array $_POST['category'][] with all of your category values.
-
If you view source of the form page what does the hidden field look like? If the hidden field is empty are you following a link from a non-https page to get to your form. The referer is empty if you type the address into the bar directly, use a bookmark, and is stripped by some security software. I tested the form as posted and it looks like it is working.
-
confused... not sure how to go about this. do not echo if same.
davidannis replied to loren646's topic in PHP Coding Help
Can you post the section of code that you are having trouble with? It would make giving a useful answer easier. -
The point is moot now but yes, that was the thread that disappeared on me. .
-
My bad. I need to think about this.
-
Someone asked a question, posted some code. I posted a solution. They replied that my solution did not work so I coppied their code into my IDE, found my typo and an additional bug in their code, moved the working code to a production webserver where they could see it in action and when I was done and tried to post the response the board told me I didn't have permission to reply. Now, when I look for the original thread it is gone. It's not in my content and doesn't show in search. Any ideas what might be up?
-
Did it ever work? If not, find the code class objWriter { ... } and within it find function save(){ ... } and that is the code that fails to execute. Make sure error reporting is on. Insert a line before the line of code that fails echo $filename; to see what it is trying to write.
-
Use javascript to display or hide a <div> containing the other two checkboxes.
-
display column names from database in returned values table
davidannis replied to Juarez's topic in PHP Coding Help
Barand, I do something similar to the pseudocode that you propose in a lot of my programs and I keep meaning to replace it with DESCRIBE my_table; to get the column names. The problem with the pseudocode is that row = fetch_assoc() colnames = array_keys(row) fails if the select returns zero rows. -
Your new error message has a comma after the 1_ The old error message did not.
-
Looks like the OS can not find the file to rename. My guess is that the file is not in /user/user_bilder/ Look at the upload and see where the files are put before approval.