Well . . . you're wanting this to display in an HTML page, right? Just call the image using HTML tags within an echo:
$myDate = "1/1/2003"; // target date
$today = (date ("n/j/Y")); // today's date
if ($myDate == $today) {
// display one-time graphic
echo...
Just check the date against your target date every time the page is accessed:
$myDate = "1/1/2003"; // target date
$today = (date ("n/j/Y")); // today's date
if ($myDate == $today) {
// display one-time graphic
}
else {
// standard behavior
}
Now . . ...
To begin with, I'd ask your server administrator to include index.php in the server directory index. That way you don't have to worry about the redirect from index.htm.
You're running this in a frameset, so the URL doesn't show any of the GET data. I don't even see it appearing in the status...
I'm not sure I'm completely following you on this. It might help to see a snippet of your code, if that's possible. I get the feeling that you can do what you want easily in a standard form submission, but you want to retain the onChange in the pulldown, right?
BigBadDave, I can't say that I know why it's crashing ( maybe the space between the limit args?), but I know that saying "LIMIT 0,10" is the same as "LIMIT 10"
Why not give that a try and see what happens.
Good luck.
--Jeff
Sessions is definitely the way to go. If you haven't used sessions yet, they're really pretty simple. On every page that must use this information---before sending out any headers---write
session_start();
You must declare your session variables with the syntax used below (I like to put mine in...
The first thing I notice regarding the MySQL calls is that you're hitting your MySQL server as root with no password. If that's how your server is set up, okay . . . I hope it's a test server and not something publicly available.
On each of your calls, just put in an echo statement to use as a...
The only way I know to do it is to set that data in the value. Set the cookie like this:
$stime = (date ("n/j/Y g:i"));
setcookie ("cookieName", "cookieValue, set=$stime, exp= set + 3600", time()+3600);
and then read the cookie with
echo $cookieName;
You'll...
I haven't converted a guestbook, but I've converted several database-integrated web apps from Perl to PHP. I've found that the conversion went quite smoothly. Many functions and control structures remained virtually unchanged. Some things became simpler (my makeshift switch in Perl rolled over...
I'm probably missing something here, but according to your last post . . . given your directory structure, you should be using require "../../kategorier.php" because it's two directories up. That seems too simple AND it doesn't explain why your absolute path didn't work. Did you try...
I don't think you can do that with JavaScript. There's no object I know of that you can grab for each line or for the EOL. Your best bet--if your situation allows it--is to get the textarea as it is submitted and use Perl to break apart the lines.
--Jeff
I'm flying a bit blind (not working on a Win 98 right now) but I'll still put in my two cents . . .
You may have already done this, but I'm not sure from what's in your post.
The instructions in the link you included had you use FrontPage to set permissions on the cgi folder. Have you used...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.