Thanks Zak,
Its really amazing.
It worked Properly.
Thanks once again.
Rinku
Zachary Krakov <[EMAIL PROTECTED]> wrote:
Hi Rinku,
The statement syntax that I believe will work you is the following:
If (($VARIABLE1 !== '') && ($VARIABLE2 !== '')) {
print "Rinku";
}
Let me know if this
Hi there,
>A drop down with 365 days !?!? Isn't that a "little" big?
Actually it's Fridays, Sundays and Tuesdays for 2 years (365 was an example)
it's for an Admin for a client, and he asked that it be in a dropdown box
and he's the boss, so he gets what he wants :-)
One thing he wanted which
Is there such thing as SSL connections to MySQL?
Edgar Hassler wrote:
Does PHP support SSL connections to MySQL? If no, does anyone have an idea
how to make an SSL conncetion to MySQL using PHP?
Thanks,
Edgar Hassler
--
This message has been scanned for viruses and
dangerous content by Mail
Hi Neil,
I have tried it like that with no luck, what is below just happens to be
my latest attempts to get it working.
What is happening is that it is saying that $C and $G are zero, when in
fact there is data in there.
How do I get it to 'refresh' the variables? That is what I am trying to
do
A drop down with 365 days !?!? Isn't that a "little" big?
> I have a problem, I currently have some code which populates a dropdown
> box
> - this code gives me every day for the next x amount of days (EG: a years
> worth of days), however what I really need to be able to do, is to find a
> way
Hello Pablo,
I made a Typo:
change this: while ($key<80) echo "$lastgroup." . ($key++) . " is free\n";
for this: while ($key<255) echo "$lastgroup." . ($key++) . " is free\n";
;)
--
Best regards,
Pablo
--
PHP Database Mailing List (http://www.php.net/)
To unsu
Hello redhat,
Hey... look at this:
CREATE TABLE `testip` (
`id` int(10) unsigned NOT NULL auto_increment,
`theip` varchar(100) NOT NULL default '',
PRIMARY KEY (`id`),
UNIQUE KEY `theip` (`theip`)
) TYPE=MyISAM AUTO_INCREMENT=7 ;
SELECT theip, SUBSTRING_INDEX( theip, ".", 1
Does PHP support SSL connections to MySQL? If no, does anyone have an idea
how to make an SSL conncetion to MySQL using PHP?
Thanks,
Edgar Hassler
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hi there,
Just got back and tried it and it works perfectly, thank you so much for
your help, you've got me out of a bind here ;-)
Chris
You could loop through the weeks and put those 3 specifically in:
$days = array();
for($i = 0; $i < 365; $i +=7) {
$days[] = strtotime('next Monday', strtoti
You could loop through the weeks and put those 3 specifically in:
$days = array();
for($i = 0; $i < 365; $i +=7) {
$days[] = strtotime('next Monday', strtotime('+ '.$i.' days'));
$days[] = strtotime('next Friday', strtotime('+ '.$i.' days'));
$days[] = strtotime('next Sunday', strtotime('+ '.
Hi there everyone,
I have a problem, I currently have some code which populates a dropdown box
- this code gives me every day for the next x amount of days (EG: a years
worth of days), however what I really need to be able to do, is to find a
way to display this data in the dropdown box but ONL
[snip]
The IP's (for example 192.168.1.1) are all in a single field.
[/snip]
If it is a possiblity, I would store each IP in its own row, with a
column in that row being some kind of flag, like: is_issued as a logical
column.
Can you change you db layout or is it set in stone?
--
PHP Database M
I have a small script that I mangled together to enable me to input user
IP addresses into a MySQL db. The IP's (for example 192.168.1.1) are
all in a single field. The IP field is set to VARCHAR(100) Unique but
it is not the primary key. I have found that my IPs are not consecutive
and I would
[snip]
That does not work either... I can not make the statement fail!!!
I have tried
$password = "123456";
and
$password = "abcdef";
I have change the if statement to what is below and past in all letters
and
it still works?
if (preg_match ('/\d/', $password)) {
die ("You must have a numb
you only want to check to see if there is at least one digit?
If that is true, this should work:
if(preg_match('/\d/',$password)) {
echo 'password ok';
}
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
i see... so the pattern you need is
$atLeast = 2;
$pattern = '#\d{1}#';
if(preg_match_all($pattern, $password, $a) > $atLeast) {
echo 'password ok; contains at least '.$atLeast.' digits.';
}
hth greez ma
Larry Sandwick wrote:
I would like to make sure that there is at least 1 number in the
ok... this still does not do what you want, because it does not consider
that only digits should be between the letters... here is the correct
solution:
// dies
$password = 'alfgoesswimming';
// dies too
$password = 'a2lf4g2o4e7s9s3w9i0m5m7i0n3g';
// survives
$password = 'a2$5l5f4g2o4e7s9s3w9i0
hi!
is this correct: you want to check if there are two letters in the
password wich do not surround a digit? if so this is what you need:
// dies
$password = 'alfgoesswimming';
// dies too
$password = 'a2lf4g2o4e7s9s3w9i0m5m7i0n3g';
// survives
$password = 'a2l5f4g2o4e7s9s3w9i0m5m7i0n3g';
$foun
That does not work either... I can not make the statement fail!!!
I have tried
$password = "123456";
and
$password = "abcdef";
I have change the if statement to what is below and past in all letters and
it still works?
if (preg_match ('/\d/', $password)) {
die ("You must have a number betw
On Thursday 24 June 2004 18:07, Rinku wrote:
> I had written the code :
> if(isset($_POST['Variable1'])&&isset($_POST['Variable2']))
> {
> Print "Rinku";
> }
> Here, even if variables are not set then even I am getting Output as
> "Rinku".
Some form elements, eg , are always "isset()" even wh
OK then, couple more questions.
1. What is user.php? Is it the code you posted under "second page"?
2. Also, on your first page, are you sure that your
$check_user_res = mysql_query($check_user_query) or
die(mysql_error().": $check_user_query");
query is firing properly? If it isn't then your
Hi Rinku,
The statement syntax that I believe will work you is the following:
If (($VARIABLE1 !== '') && ($VARIABLE2 !== '')) {
print "Rinku";
}
Let me know if this works.
Hope this helps.
Best,
-Zak
From: Rinku <[EMAIL PROTECTED]>
Date: Thu, 24 Jun 2004 03:07:12 -0700 (PDT)
To: Zachary Krak
try this
$password = 'abcdef';
if (preg_match ('/\w\d\w/', $password)) {
die ("You must have a number between 2 letters in your password ...
0-9");
}
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
this is the output:
Array
(
)
very empty ;)
From: "Matt Matijevich" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]>
Subject: Re: [PHP-DB] [PHP]: session problem
Date: Thu, 24 Jun 2004 10:50:01 -0500
MIME-Version: 1.0
Received: from stimpy.alliancetechnologies.net ([63.86.10.3]) by
What are you setting $_SESSION['sid'] to?
> i do ($_SESSION['sid']), but the variables remain empty...
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
The *if* statement should fail with the password abcdef being qualified but
it never fails ?
If I understand the expression right, it should have at 1 number in it
between 2 letters ?
$password = abcdef;
if (preg_match ("/[A-z]+[0-9]+[A-z]+/", $password)) {
die ("You must have a n
indeed...
From: "Hutchins, Richard" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: RE: [PHP-DB] [PHP]: session problem
Date: Thu, 24 Jun 2004 11:52:38 -0400
MIME-Version: 1.0
Received: from pb1.pair.com ([216.92.131.4]) by mc6-f23.hotmail.com with
Microsoft SMTPSVC(5.0.2195.6713); Thu, 24 Jun
agreed - poor design.
-Original Message-
From: Torsten Roehr [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 24, 2004 11:21 AM
To: [EMAIL PROTECTED]
Subject: Re: [PHP-DB] Re: Posting Data to MySQL
"Mark A Galbreath" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Doesn't mat
On Thursday 24 June 2004 23:43, H. J. Wils wrote:
[snip]
>$_SESSION['logged_in'] = true;
>$_SESSION['sid'] = $sid;
>$_SESSION['user'] = $uid;
>
>$dt = date("Y-m-d H:i:s");
You should always session_wr
So, on your second page you NEVER see the "Welcome..." get echoed out? It
always forwards you to the user.php page?
> -Original Message-
> From: H. J. Wils [mailto:[EMAIL PROTECTED]
> Sent: Thursday, June 24, 2004 11:44 AM
> To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Subject: Re: [PHP-DB]
do you get any output on the second page if you do this?
';
print_r($_SESSION);
print '';
if ( isset($_SESSION['logged_in'])){
echo "Welcome...";
}else{
header("location: user.php?action=9");
}
?>
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.
Are you getting any errors displayed?
The php.ini file has to have a directory specified for the session temp
variables.
> I want to use sessions to check wether a user is logged in or not.
> Therefore,I use session_start and session_register. When I registere the
> values on the same page, they
this is the code, but this code works on my hosting provider but not on my
own server. I think i have to change settings in php.ini but dont know
which...
first page:
session_start();
include "connect.php";
include "functions.php";
$user= $_GET["email"];
$ww = $_GET["ww"]
Is there any obvious reason why you're not doing this in one query
$query = "UPDATE media SET A='$A', B='$B', C='$C', G=E*'$C'";
Or have I missed something here ?
Cheers - Neil
At 10:07 24/06/2004 +, you wrote:
MIME-Version: 1.0
Content-Type: multipart/alternative;
boundary="_=_Next
[snip]
i do ($_SESSION['sid']), but the variables remain empty...
[/snip]
If you are using the array forget about session_register.
http://www.php.net/session_register
Could you post a little code? That will make this easier to solve.
--
PHP Database Mailing List (http://www.php.net/)
To unsu
i do ($_SESSION['sid']), but the variables remain empty...
From: "Matt Matijevich" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]>
Subject: Re: [PHP-DB] [PHP]: session problem
Date: Thu, 24 Jun 2004 09:58:15 -0500
MIME-Version: 1.0
Received: from pb1.pair.com ([216.92.131.4]) by mc
"Mark A Galbreath" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Doesn't matter how many fields are on a form; they are returned as an
array
> of strings in the request object. Just iterate through the array and
update
> the corresponding database fields.
Mark, what I was trying t
[snip]
But when I ask the value of
a registered session variable on another page, it is empty?!?! Does
anyone
know how this comes? i am using session_start() at every page..
[/snip]
try the $_SESSION array for starage of session variables.
--
PHP Database Mailing List (http://www.php.net/)
To
I want to use sessions to check wether a user is logged in or not.
Therefore,I use session_start and session_register. When I registere the
values on the same page, they all seem to work. But when I ask the value of
a registered session variable on another page, it is empty?!?! Does anyone
know
Doesn't matter how many fields are on a form; they are returned as an array
of strings in the request object. Just iterate through the array and update
the corresponding database fields.
Mark
-Original Message-
From: Torsten Roehr [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 24, 2004 1
"Tom Chubb" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> I am trying to design a form that posts the data to a DB, but being new to
> PHP/MySQL, it takes me ages to hand write the code and I'm sure there must
> be an easier way to do it?
> My form has 100 fields using 20 rows and 5
I am trying to design a form that posts the data to a DB, but being new to
PHP/MySQL, it takes me ages to hand write the code and I'm sure there must
be an easier way to do it?
My form has 100 fields using 20 rows and 5 columns and it's taking me ages
to write the code for it.
Can anyone advise how
Hi Zak,
Thanks for your suggestion.
It really worked.
Now pls answer for the query described below :
I had written the code :
if(isset($_POST['Variable1'])&&isset($_POST['Variable2']))
{
Print "Rinku";
}
Here, even if variables are not set then even I am getting Output as "Rinku".
Could y
43 matches
Mail list logo