Search found 12 matches

by Brenden
Mon May 31, 2010 2:54 am
Forum: PHP - Code
Topic: Array foreach loop proplem
Replies: 19
Views: 1311

Re: Array foreach loop proplem

edit: cancel that. I need more time to figure out how your code is meant to work
by Brenden
Sat May 29, 2010 6:02 pm
Forum: PHP - Code
Topic: PHP Submit Recipient HELP
Replies: 4
Views: 752

Re: PHP Submit Recipient HELP

Ok you still have five inputs named 'MsgBody'. They need to be called different things, or your form will only receive one of them. You are missing an open round bracket after the first IF, and you are missing curly brackets all over the place during your actual message sending, after the IF and on ...
by Brenden
Sat May 29, 2010 5:57 pm
Forum: PHP - Code
Topic: Adding multiple records at ones
Replies: 6
Views: 494

Re: Adding multiple records at ones

$_POST['dllGenres'] is now an array, not a number, you need to loop through it, and for each one make a new record in the Genres table
by Brenden
Sat May 29, 2010 4:57 am
Forum: PHP - Code
Topic: Session Problem in Shopping Cart
Replies: 5
Views: 758

Re: Session Problem in Shopping Cart

Perhaps your main point of concern is this $_SESSION["cart"][$prod_id]++; $_SESSION["cart"][$size_id]++; prod_id and size_id are taken from two different tables and represent two different things, yet you're storing them both in exactly the same way, as $_SESSION["cart"...
by Brenden
Fri May 28, 2010 10:08 pm
Forum: PHP - Code
Topic: [question] auto uploading system
Replies: 3
Views: 108

Re: [question] auto uploading system

The internet is like a series of tubes. On one end there's someone uploading, on the other end there's someone downloading. Your server "uploading" to someone's computer is the same thing as them "downloading" from your server. The different terms are usually used in relation to ...
by Brenden
Fri May 28, 2010 10:06 pm
Forum: PHP - Code
Topic: PHP Submit Recipient HELP
Replies: 4
Views: 752

Re: PHP Submit Recipient HELP

The first problem that I can see is that you're trying to email the post variable "MsgBody", which doesn't appear anywhere in the actual form. Is it giving you any error messages, a blank screen, the form again? Be more specific than "will not send" Also you have four inputs all ...
by Brenden
Fri May 28, 2010 6:05 pm
Forum: PHP - Code
Topic: Session issues
Replies: 5
Views: 1087

Re: Session issues

I know this is unlikely, but I once discovered that my session issues were caused by me using a local hostname with an underscore in it. http://l_testsite/dosession.php
by Brenden
Fri May 28, 2010 6:03 pm
Forum: PHP - Code
Topic: Adding multiple records at ones
Replies: 6
Views: 494

Re: Adding multiple records at ones

Change your genre <select name="ddlRating"> to something like <select name="ddlGenres" size="5" multiple> When your movie is added, $genrearray = $_POST['dllGenres']; After the movie is entered, use mysql_insert_id() to get the MovieID Go through the array and make a g...
by Brenden
Fri May 28, 2010 3:23 am
Forum: PHP - Code
Topic: What shall i add in Apache in order php files see new paths?
Replies: 1
Views: 103

Re: What shall i add in Apache in order php files see new pa

If you have Dreamweaver you can do a folder-wide find/replace
by Brenden
Fri May 28, 2010 2:42 am
Forum: PHP - Code
Topic: How to create string PAssword, PaSsword, etc.
Replies: 18
Views: 4202

Re: How to create string PAssword, PaSsword, etc.

Personally I would put each word in once, in lowercase, then run strtolower() on any word before searching for it in the database. But perhaps I'm just not complicated enough.
by Brenden
Fri May 28, 2010 2:21 am
Forum: PHP - Code
Topic: Session issues
Replies: 5
Views: 1087

Re: Session issues

This can sometimes happen if you accidentally put a space or a blank new line before <?php - it will output information to the browser, causing the "headers already sent" message.
by Brenden
Fri May 28, 2010 2:18 am
Forum: PHP - Code
Topic: Making an Advanced cache system
Replies: 3
Views: 117

Re: Making an Advanced cache system

Well that's just the thing. In order to detect if the page has changed, you need to run the process that creates the page, in which case there's no point at caching at all. What I would do is approach it by either doing it at a regular interval, or running enough of the script to determine if the fu...