[PHP] cookie problemes

2003-02-24 Thread kale
hy,
i have a probleme with cookie.
this is my code "Setcookie($n_sessid, $sessid, time()+$cookie_life);"
and work, 80%. 
some machines (all windows - 98 and XP) with internet explorer 
(ver.5 and 6, some with the last upgrade) can write the cookie. same
machines have
cookie enable because the users can read the mail from yahoo. 
somebody can help me with what i made wrong?
kale

 


RE: [PHP] cookie problemes

2003-02-24 Thread kale

What "path" and what "domain"? 
Thanks.
Kale

-Original Message-
From: Gonzo [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 24, 2003 12:04 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] cookie problemes


> hy,
> i have a probleme with cookie.
> this is my code "Setcookie($n_sessid, $sessid, time()+$cookie_life);" 
> and work, 80%. some machines (all windows - 98 and XP) with internet 
> explorer (ver.5 and 6, some with the last upgrade) can write the 
> cookie. same machines have
> cookie enable because the users can read the mail from yahoo.
> somebody can help me with what i made wrong?
> kale

This is a known issue with IE.  You should set the "path" and "domain"
also and most likely these problems will vanish.

Gonzo




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] cookie problemes

2003-02-24 Thread kale
:( don't work.
I put "Setcookie($n_sessid, $sessid, time()+$cookie_life, $path,
$domain, 0);"
In script but don't work. Same. No cookie in cookie folder. 
Other idea?
Kale


-Original Message-
From: Gonzo [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 24, 2003 12:13 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP] cookie problemes



> What "path" and what "domain"?

See "path" and "domain" here:

  http://php.net/setcookie

Gonzo





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] cookie problemes

2003-02-24 Thread kale
$path = "/";
$domain = ".mydomain.ro";
And in my cookie folder i find a cookie named: [EMAIL PROTECTED]
But other computer (with problems) i don't have any cookie with same
name.
And if i reload the page and print $HTTP_COOKIE_VARS[$n_sessid] 
it's nothing. I have 12 computers and 10 are ok. 
kale

-Original Message-
From: Gonzo [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 24, 2003 1:30 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP] cookie problemes


> :( don't work.
> I put "Setcookie($n_sessid, $sessid,
> time()+$cookie_life, $path,
> $domain, 0);"
> In script but don't work. Same. No cookie in cookie
> folder.
> Other idea?

Nothing other than 1) What are in the $path and $domain variables? and
2) did you grep in your cookies folder?

Sometimes IE does not name the file like you would expect.

Gonzo



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] cookie problemes

2003-02-24 Thread kale
The clock is ok. I write cookie with javascript and read with php.
For moment is the best solution i have. In future i hope to resolve 
this problem and i find solution i post it here.
Thanks for help.
kale

-Original Message-
From: Gonzo [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 24, 2003 8:11 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP] cookie problemes


> $path = "/";
> $domain = ".mydomain.ro";
> And in my cookie folder i find a cookie named: [EMAIL PROTECTED] 
> But other computer (with
> problems) i don't have any cookie with same name.
> And if i reload the page and print $HTTP_COOKIE_VARS[$n_sessid]
> it's nothing. I have 12 computers and 10 are ok.

Check the clocks on the 2 machines that do not have the cookies.

Gonzo



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



RE: [PHP] cookie problemes (solved with javascript)

2003-02-25 Thread kale
I not a expert in javascript but this code is working. 
I guess it is easy to change some line of code to work for your neads.
Kale


// kale's code 

_


function setCookie(name, value)
{
var the_name = name;
var the_value = value;
var the_cookie = the_name + "=" + escape(the_value);
var the_date = new Date("December 31, 2050");
var the_cookie_date = the_date.toGMTString();
the_cookie = the_cookie + ";expires=" + the_cookie_date;
document.cookie = the_cookie;
alert("Thanks, now go to the next page.");
}






__
// end kale's code

__

-Original Message-
From: Awlad Hussain [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, February 25, 2003 11:15 AM
To: kale
Subject: Re: [PHP] cookie problemes


Hi Kale,
I have the same problem with cookie, i would appericiate if you can
share the java script code you used to create the cookie and how it
solved the problem.

-awlad

- Original Message -
From: "kale" <[EMAIL PROTECTED]>
To: "Php. Net" <[EMAIL PROTECTED]>
Sent: Tuesday, February 25, 2003 7:59 AM
Subject: RE: [PHP] cookie problemes


> The clock is ok. I write cookie with javascript and read with php. For

> moment is the best solution i have. In future i hope to resolve this 
> problem and i find solution i post it here. Thanks for help.
> kale
>
> -Original Message-
> From: Gonzo [mailto:[EMAIL PROTECTED]
> Sent: Monday, February 24, 2003 8:11 PM
> To: [EMAIL PROTECTED]
> Cc: [EMAIL PROTECTED]
> Subject: RE: [PHP] cookie problemes
>
>
> > $path = "/";
> > $domain = ".mydomain.ro";
> > And in my cookie folder i find a cookie named: 
> > [EMAIL PROTECTED] But other computer (with
> > problems) i don't have any cookie with same name.
> > And if i reload the page and print $HTTP_COOKIE_VARS[$n_sessid] it's

> > nothing. I have 12 computers and 10 are ok.
>
> Check the clocks on the 2 machines that do not have the cookies.
>
> Gonzo
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] controls "list menu"

2002-08-13 Thread kale

hy,
I have a list menu:


one
two
three
  

I want when I select value "two" my page reloads and 
it prints "You selected value TWO". 
How can I do this?

thx 
kale.



Re: [PHP] Re: controls "list menu"

2002-08-13 Thread kale

hy, I have next lines of code:
1.
  
  
All Open Leads
My Unread Leads
Recently Viewed Leads
Today's Leads
   
   
2.
">
Select
One:
  
>My Unread Leads
>Recently Created
>Recently Viewed
  



both forms are in same page. second form it works fine without problems.
first form it works with one exception. If select "All Open Leads" don't
happend anything
For rest of values it works.
For example if select "My Unread Leads" I see page leadview.php.
What is it wrong?

kale

- Original Message -
From: "Peter Bottenberg" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, August 13, 2002 1:35 PM
Subject: [PHP] Re: controls "list menu"


> Hy,
>
> Save this script as select.php
>
> 
> if (!isset($action))
> {
>   $action = "select";
> }
>
> if ($action == "select" )
> {
>   ?>
>   
>   
> one
> two
> three
>   
>   
>   
>}
>
> if ($action == "display")
> {
>   ?>
>   You selected value 
>}
>
> ?>
>
> Greetings
> Peter




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] select distinct mysql

2002-08-15 Thread kale

hy,
I have a tabel (history) with fields:
id (uniq), date, time, name, etc.
I want to select after next rules:
- date and time been sort descendent
- only 10 recording
- value of the field name to be unique
syntax must be something this:

SELECT *, DISTINCT name FROM history 
ORDER date DESC, time DESC LIMIT 10

but this not work. how can I do this?

this is structure of tabel:
id  namedate time  ...etc
--
1. kale 2002-03-15   14:12_14 
2. smith   2002-04-17   15:14:13 
3. kale 2002-05-15   16:14:13 .

I want that result contains only recordings 2 and 3
not 1 because it's same name and it is older then 3.

I use a mysql server.
thanks for help
kale



[PHP] About html

2002-08-30 Thread kale

Hy,
I have one question about html.
1. I have a form with 8 textbox. How can I put the tab order?
When I press "tab" I want to jump from first textbox to 
textbox number 4 not to number 2.

Thanks for answer.
kale



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] Array Javascript

2002-09-05 Thread kale

Hy,
I have an array make with a javascript. 
How can I read values with PHP from it?
Kale.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] How do I use a Javascript variable in PHP?

2002-09-23 Thread kale


You cann't from php but you can from javascript.
For exemple:
 file -


Function insert_value(){
Document.form_name.text_box_name.value = javascript_value;
}






---

Now: when you click on button insert - then the javascript value insert
value into textbox.
If you open a window with a calendar and choose a value the syntax of
function will be:
"Window.opener.form_name.text_box_name.value = your_value; "
and close windows with
"Window.close();"

I hope this help you
Kale.


-Original Message-
From: Tom [mailto:[EMAIL PROTECTED]] 
Sent: Monday, September 23, 2002 4:09 PM
To: [EMAIL PROTECTED]
Subject: [PHP] How do I use a Javascript variable in PHP?


Hi all,



I hope this is the right place to pose my question, so here goes: -



I have a javascript function called calcMonth() and given a number it
will
return a date i.e. month = calcMonth( 57 )   -  month will be 'sept
2002'



The problem I`m having is at the beginning of my PHP file I`m calling
this
calcMonth() then doing a load of php stuff and then trying to use the
javascript month variable, but to no avail: -



print "";



The result is, the browser displays the words 'javascript:month;' - not
a month number



I`ve looked everywhere for an answer from persistent javascript data to
using framesets to hold the variable but to no avail.



I know its quite a bit of javascript, but its mixed in  with PHP too so
I thought it`d be the right place.



Anyways, I hope someone can provide the answer to my problem.



Thanks in advance,

Tom




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php