fugix
-
Posts
1,483 -
Joined
-
Last visited
Posts posted by fugix
-
-
in your failed address function, change to
function FailedAddress() { return $this->failedAddress; //remove the $ }
you will also need to change the messageText function as well
function MessageText() { return $this->messageText; // remove the $ }
-
welcome to phpfreaks.
-
you need to create an instance of your class first, you have not defined the variable that you are trying to use
<?php include ('PopmongerClass.php'); $Popmonger = new Popmonger(); echo $Popmonger->FailedAddress(); echo $Popmonger->MessageText(); ?>
-
function headerReturnImages() { $query = mysql_query("SELECT image_image FROM reviews ORDER BY image_id ASC"); while ($fetch = mysql_fetch_array($query)) { if($fetch[0]) { echo'<img src="images/'; echo $fetch["image_image"]; echo '" alt="" class="active" />'; } else { echo'<img src="images/'; echo $fetch["image_image"]; echo '" alt="" />'; } } }
-
absolutely, if you need help with this, please post you code
-
the reason why $_SERVER['PHP_SELF'] poses such an issue as far as injection is concerned, is because it incorporates $_SERVER['PATH_INFO'] which can be tampered with by users. To my knowledge, $_SERVER['SCRIPT_NAME'] does not incorporate PATH_INFO, however I would check a reference before being confident
-
Aha.
The culprit? This:
header("Location: http://" . $HTTP_HOST . $SCRIPT_NAME . "?id=" . $validentry);
Needed to be this:
header("Location: http://" . $_SERVER['HTTP_HOST'] . $_SERVER['SCRIPT_NAME'] . "?id=" . $validentry);
I guess the syntax for predefined variables must have changed some time after the publication of the manual I'm using. Either way, I've spent years working with and debugging C, Java and VB, but php is clearly an all-new sort of monster in this sense.
None the less, thanks for all your help and hopefully I didn't waste too much of this board's time. I'll try to keep the n00b issues to a minimum
wow yeah, didn't even notice that, dumb of me...those variables are stored in the $_SERVER predefined array. Glad you found your error
-
before using it in your header, try to echo it to validate that it is a legitimate url
-
mockery is not needed.. sorry i brought the issue up
-
why cant you call the arrays in the functions themselves?
-
It was changed to something a little offensive. Normally i wouldn't even care
Was it a picture of you?
nope
-
No offense but it isn't an invasion of privacy. It's more like somebody printed you some new business cards and swapped your old ones out without you noticing.
It was changed to something a little offensive. Normally i wouldn't even care
-
first thing that i notice is you are trying to concatenate 2 queries together, cannot do this
-
Well, if you would stop posting links to people having sex with animals, I am sure they would allow it.
you okay?
-
im not sure who changed my signature, but I do not find it funny and consider it an invasion of my privacy. Obviously it was an admin or mod, please do not do this again
-
can you post your new code
-
so you're saying that when you click the submit button, it doesn't refresh the screen at all? or just the actual page that your tables are on?
-
huh? can you be clearer with your explanation
-
what exactly is your problem? and you need to use = not == to assign a value to a variable.
if(($descText=='') || ($descText==' ') || ($descText == null)){ $descText = $altText; }
-
-
there is a button in the bottom left hand of this page.
-
you will need to move your images into your server directory
-
PFM is right, try this
$increment_count = "UPDATE $this->tablename SET count = count + 1 Where confirmcode = '$referid'";
-
try this
<?php /** * @author ohyeah * @copyright 2011 */ $dir = 'C:/wamp/uploads/'; $files = scandir($dir); foreach($files as $filedownload){ if(substr($filedownload, 0, 1) != '.'){ $file_size = round((filesize("$dir/$filedownload")) / 1024) . "kb"; $filedownload = urlencode($filedownload); echo "\t<tr> \t\t<td><a href=\"{$dir}{$filedownload}\">$filedownload</a></td> \t\t<td>$file_size</td> \t</tr>\n"; } } ?>
foreach error
in PHP Coding Help
Posted
to make sure that $xml is an array, yes you can do that