
MDCode
Members-
Posts
640 -
Joined
-
Last visited
-
Days Won
1
Everything posted by MDCode
-
LIMIT 1 will only gather 1 row from the table. So LIMIT 2 or 3 will gather 2 or 3. The query will not gather the same row twice.
-
If your short tags setting is disabled you will need to follow barand's suggestion here:
-
As you said, it can be used either way. However, using GET is a much neater way in my opinion, and I was expressing it in an example. I never said that GET was better, and I never said that POST was.
-
That's why I said sounds
-
Say you want to delete a profile comment from a user. Get would work better in this case because otherwise you would need a hidden field to carry the id of said comment. Users can edit hidden fields whenever they want.
-
Sounds like you don't have short tags enabled.
-
Insert Defaultimage.png Upon Membership Registration?
MDCode replied to justlukeyou's topic in PHP Coding Help
There is no reason to store it as a variable. Just typing out defaultimage.png in your query would've saved you all the time figuring it out. -
Short version: functions don't run automatically. You need to call them by using function_name(variables, variables); $_POST will not work in a function so you need to call them by the variables inside the parentheses ie: functions.php // variables can stay the same it doesn't matter just as long as they coincide function bored($bored_renamed, $tired) { echo "Bored = $bored_renamed"; } whatever.php <?php require("functions.php"); bored($bored, $sleepy); ?>
-
Insert Defaultimage.png Upon Membership Registration?
MDCode replied to justlukeyou's topic in PHP Coding Help
And you can't just type out defaultimage.png ...? -
You have still not put $email in apostrophes within your second query
-
In your query you can use ORDER BY RAND() but will make your site slow with large tables.
-
if(mysql_num_rows($result_set) != "0") { echo "Duplicate exists"; }
-
Put apostrophes around $email
-
It may work, but if you had error reporting on you would be getting an error message session_start(); must be called before any output or you get errors.
-
Well, "this doesn't" isn't a good explanation of your problem. What is happening that shouldn't? What is the value of $str1?
-
Ckeditor And Php Tags In Rte (Rich Text Editor)
MDCode replied to spacepoet's topic in PHP Coding Help
Try changing the opening <? tag to <?php. Your php.ini settings might be affecting it -
If they are posting here instead of looking or trying they probably don't care about looking at the code itself as long as it works
-
This is a third party script that we can not help with I believe. You will have to talk to the creators of ClipBucket.
-
Call To Undefined Function Themeheader()
MDCode replied to jmeyers's topic in PHP Installation and Configuration
Yes an ampersand is an & symbol. But psycho was referring to the @ sign. -
How are you setting them and calling them? Full page of php code would help. Also, are you saying you are using dreamweaver to use php...? In which case that is your error. Dreamweaver can not parse php.
-
You could try properly closing your echo with a semicolon
-
I see no where that you are even storing $uid as a variable.
-
Error: Column 'column_Name' In Where Clause Is Ambiguous
MDCode replied to EzwanAbid's topic in PHP Coding Help
$sql = "SELECT * FROM student,surat WHERE table_name.student_id like '%$term%' AND student.student_id=surat.student_id"; -
Error: Column 'column_Name' In Where Clause Is Ambiguous
MDCode replied to EzwanAbid's topic in PHP Coding Help
If in your database, the tables student and surat both have a student_id column you need to specify which one to select it from in WHERE student_id like '%$term%'