Jump to content

Problem


Psycho-Path

Recommended Posts

Ok I have my site set so so the index.php reads the rest of the .php files and puts their contents into a certain part of index.php, right?  ill give an example of the code im using.

[code]<?
$val = $_GET['id'];
$val .= ".php";
$dirty = array("..");
$clean = array("");
$val = str_replace($dirty, $clean, $val);
if (isset($_GET['id'])) {
if (file_exists($val)) {
include "$val";
}
else {
include "404.php";
}
}
else {
include "news.php";
}
?>[/code]

so anyways I followed a tut on forums ( I think I got it from here ) and so I have the forums index done - index.php?id=forums so it looks fine,  well I have a problem b/c the way these forums are made it of course sets numbers for posts made, so you would think that I would use index.php?id=message  but no, it would need to be something like index.php?id=message&id=1 so it knows which reply it is using or else it just looks at message.php rather than message.php?id=1 which is what I need.

so please help me

Thanks,
Andrew
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.