Bruno B B Magalhães wrote:
how to determine if the last char of a string is a '/'...
The problem, a webpage can be accessed by www.domain.com/page.php or
www.domain.com/page.php/
Use substr()...
http://www.php.net/substr
$url = 'http://example.com/index.php/';
if (strcmp(substr($url, -1), '/') ==
Henry Grech-Cini wrote:
Hi All,
I am trying to check if a website is up (reachable) and I have used the
standard code below:
Unfortunately this works for most sites but Microsoft doesn't work most of
the time even thought the site is definiately up! (Occassionally it does say
it is reachable but
Open a connection? Maybe fopen, dns search, ip search, anything. I just
don't know which way is faster (I think it's fopen).
--
Julio Nobrega.
Um dia eu chego lá:
http://sourceforge.net/projects/toca
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.n
Outsch, sorry, I just found what I wanted...
> Is there any posibility to check if there is
> actually a website behind a link or just, let's
> say a 404?
http://www.hotscripts.com/PHP/Scripts_and_Programs/Link_Checking/
Have a nice day ;)
Kiko
-
It's not a bug, it's a feature.
christoph s
So sprach »Fredrik Arild Takle« am 2001-09-22 um 18:00:37 +0200 :
> session_register("valid_session");
>
> OR SOMETHING LIKE THIS?
>
> if (session_is_registered($valid_session)) {
Yep, that seems better.
Thanks to both of you!
Alexander Skwar
--
How to quote: http://learn.to/quote (germ
session_start();
$valid_session = true;
session_register("valid_session");
OR SOMETHING LIKE THIS?
if (session_is_registered($valid_session)) {
// Do something?!
}
"Gaylen Fraley" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Why not populate a
Why not populate a session variable, in the page that starts the session,
like :
session_start();
session_register("valid_session");
$valid_session = true;
Then in the page that you need to check, like:
if ($session_valid) {
// Do something since a session is already running
}
--
Gay
To check if a type checkbox variable has been set use
isset() i.e.
if (
isset($interest)
or isset($interest2)
or isset($interest3)
or isset($interest4)
or isset($interest1)
)
{
// Everthing is ok
} else {
$error = .
)
This should do exactly what you want, and a
8 matches
Mail list logo