[PHP] reading MS Excel?

2006-12-28 Thread William Stokes
Is it possible to read Excel files and store the info to DB? If so how? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Arrays help

2007-01-05 Thread William Stokes
Hello, I'm making a menu script that uses mysql, php and javascript to build a "on mouse over" dropdown menu to a page. I ran into some problems and would need help to get this working. (This is just the top level of the menusystem) 1. Get the toplevel links from DB, create array and put values

[PHP] Access array data in foreach?

2007-01-06 Thread William Stokes
Hello, I Have an array $toplevel containing arrays: Array ( [0] => Array ( [0] => 1 [1] => 1 [2] => eka [3] => eka.php ) [1] => Array ( [0] => 2 [1] => 1 [2] => toka [3] => toka.php ) [2] => Array (

Re: [PHP] Access array data in foreach?

2007-01-06 Thread William Stokes
Uh. (Embarrassed) Thanks anyway!! -W ""Casey Chu"" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > $value holds the value of the current array element. > > On 1/6/07, William Stokes <[EMAIL PROTECTED]> wrote: >> Hello, >> >

[PHP] Arrays?

2007-01-07 Thread William Stokes
Hello, How to print out the following array $test so that the print order is by the fourth[4] key? I need to print out all arrays in $test so that the data is ordered by the fourth key in ascending order. $test =Array ( [0] => Array ( [0] => 5 [1] => 2 [2] => sika [3] => sika.php [4]

[PHP] web form data to arrays?

2007-01-17 Thread William Stokes
Hello, I have a script which retrieves rows from DB and prints them to a user editable form to a web page. I don't know how to print the form objects so that all editable fields are put to arrays for updating them to DB. I have tried to create arrays sarjanID[] etc. but havent got it to work...

Re: [PHP] web form data to arrays?

2007-01-17 Thread William Stokes
tti viestissä:[EMAIL PROTECTED] > On sze, 2007-01-17 at 15:23 +0200, William Stokes wrote: >> Hello, >> >> I have a script which retrieves rows from DB and prints them to a user >> editable form to a web page. I don't know how to print the form objects >> so >

Re: [PHP] web form data to arrays?

2007-01-17 Thread William Stokes
I got it working like this: $counter = 0; foreach ($arr as $value) { //make the form ... print "\n"; $counter++; } Now I have array $ArrUpdate which contains sub-arrays with the update data. This can now be processed with another foreach loop -Will "Jochem Maas" <[EMAIL PROTECTED]> kirj

[PHP] regular expression help!

2007-01-18 Thread William Stokes
Hello, Can someone here give me a glue how to do the following. I guess I need to use regular expressions here. I have absolutely zero experience with regular expressions. (if there's another way to do this I don't mind. I jus need to get this done somehow :) I need to strip all characters fro

Re: [PHP] regular expression help!

2007-01-18 Thread William Stokes
Hello Roman, Could you specify the functionality of your script a bit please. (How it works) I forgot to mention that this part: ', is not always the same. The image properties can vary. Thanks -Will "Roman Neuhauser" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] ># [EMAIL PR

[PHP] sortind arrays

2007-01-24 Thread William Stokes
Hello, How can I sort an array like this so that it would be ASC ordered by the [1] key in subarrays? I need to maintain only the subarray key - value pairs. (Do I make sense?) Array ( [0] => Array ( [0] => Logo [1] => NameC [2] => Home

[PHP] php & javascript interaction

2007-01-26 Thread William Stokes
Hello, I need some advice on how to learn Javascript and PHP interaction. Any good tutorials on the web would be most welcome. I particulary need to learn how to pass JS user input/choices to PHP. My current problem is how to ask user confirmation over his actions on a web form after POST. "Ar

[PHP] Opera advice needed!

2007-02-06 Thread William Stokes
Hello, I just noticed when I published a new menu system that it does NOT work in the ISP hosted server. However it works ok on my test server. Here's the test I have done all in same client machine (=unchanged browser settings): My test server: IE6 & 7->OK Opera 9.02 -> OK Firefox ->OK IS

Re: [PHP] Opera advice needed!

2007-02-07 Thread William Stokes
If there's an opera expert around could you please check out the following link: http://www.fcviikingit.com/new/testimenu.php This script contacts a DB and prints out the results as javascript to the client browser. As I mentioned earlier It works ok with IE, FF, Netscape but not with Opera. H

Re: [PHP] Opera advice needed!

2007-02-07 Thread William Stokes
ShitSHitSHIT!!! I had javascript disabled in Opera. The browsed just ignored it's own settings while brosing my server??? Feeling stopid. :O -W (Just costed me 3 hours) ""William Stokes"" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > Tha

Re: [PHP] Opera advice needed!

2007-02-07 Thread William Stokes
when the files are in my test server... -W "Frank Arensmeier" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] 7 feb 2007 kl. 09.50 skrev William Stokes: > If there's an opera expert around could you please check out the > following > link: > > htt

[PHP] php login

2005-02-16 Thread William Stokes
Hello, I need to create solution for user authentication/recognition in my web page. I think it would be a good idea to use mysql database for storing the user info because the user info is later used to determine what parts of site the recognized user is allowed to update. The site is for a s

[PHP] Re: php login

2005-02-16 Thread William Stokes
OK. Thanks a lot. So I need to studu the $_Session more closely. "Jamie Alessio" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] >> I need to create solution for user authentication/recognition in my web >> page. I think it would be a good idea to use mysql database for storing >> t

[PHP] md5 passwords to db

2005-02-17 Thread William Stokes
Hello, I need to make a script/form that can create username and md5 password and save the info to mysql db. Can anyone help? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] username and password auth

2005-02-17 Thread William Stokes
Hello, What is the best or right way to compare users name and password given in a web form to data in mysql database? I saw one example where sql SELECT query was made with username and password as WHERE and the script tested how many rows was returned from database if there was 1 row returne

[PHP] hiding password in form

2005-02-23 Thread William Stokes
Hello, How can hide the typed password in web form with *** (asterix)? I dont wan't everyone to seen evereone passwords in plain text. Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: hiding password in form

2005-02-23 Thread William Stokes
OK ;-) "M. Sokolewicz" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: >> Hello, >> >> How can hide the typed password in web form with *** (asterix)? I dont >> wan't everyone to seen evereone passwords in pl

[PHP] password case sensitive

2005-02-23 Thread William Stokes
Hello, I got my little user authentication to work but now I would like to know how to make and check the (upper/lower) case in password. To put it simple. I want users password to be case sensitive. The authentication checks for returned number of rows from DB. If there is one matching row th

Re: [PHP] password case sensitive

2005-02-24 Thread William Stokes
OK. I changed to hashed passwords in now they are case sensitive. Thanks. -Will "Richard Lynch" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: >> I got my little user authentication to work but now I would like to know >> how

[PHP] Cookies

2005-02-24 Thread William Stokes
Hello, If I send a session cookie to browser where it is stored in WinXP? Or is it stored as a separate file at all. I know that the script sends the cookie but I can't find it in the client computer harddrive. I am testing with Opera, IE6 and Firefox. Thanks -Will -- PHP General Mailing Lis

[PHP] Cookies

2005-02-24 Thread William Stokes
Hello, If I send a session cookie to browser where it is stored in WinXP? Or is it stored as a separate file at all. I know that the script sends the cookie but I can't find it in the client computer harddrive. I am testing with Opera, IE6 and Firefox. Thanks -Will -- PHP General Mailing List

[PHP] combining values

2005-03-01 Thread William Stokes
Hello, I need to collect persons birth date from web form. The form is this kind: Birthday date month year Then I need to combine these in to a one $variable. Something like this... $birthday = $day . $month . $year; How can I add the . (dots) to the date so it would look like for example

[PHP] auto refresh once

2005-03-01 Thread William Stokes
Hello, Is it possible to force one automatic refresh browser when user enters to a webpage? If so, how? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] sql query

2005-03-02 Thread William Stokes
Hello Can someone explain this to me. I don't know how to read this. if (!$variable = mysql_query("select id,sessid from users where ... What is this "if(!" I mean the ! sign. Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] sql query

2005-03-02 Thread William Stokes
OK got that. Thanks... "Jason Petersen" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > On Wed, 2 Mar 2005 13:02:39 +0200, William Stokes <[EMAIL PROTECTED]> > wrote: >> Hello >> >> Can someone explain this to me. I don't know h

[PHP] User rights assignment

2005-03-04 Thread William Stokes
Hello I'am creating a web site for a soccer club with about 30 teams. The idea is that there are about 20-30 persons who will update the data on the site via web forms "admin interface". I have really hard time to figure out how to do the users right assingment. So far I have user authenticati

[PHP] cursor to text field

2005-03-15 Thread William Stokes
Hello, This might be more of a HTML question but I think that someone here can help me. How can I put, automatically, the cursor to a spesific text field in web form. So that the user doesn't have to select the first field with mouse. Thanks -Will -- PHP General Mailing List (http://www.php.n

Re: [PHP] cursor to text field

2005-03-15 Thread William Stokes
Thanks Jesper. That did it! -Will "Jesper Goos" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > Try something like this... > > onload="document.loginForm.username.focus();document.loginForm.username.select();"> > > > > > &

[PHP] Log out button

2005-03-16 Thread William Stokes
Hello, Again this might be more of a HTML quetion. If so sorry about that. Anyway I was just trying to make a log out button to a page. It should end a session or/and close browser window. (Closing browser ends the session as well I think?) All variable values are deleted when browser is closed

[PHP] VERY basic function question

2005-03-17 Thread William Stokes
I'm trying to learn functions (just started). I can't see why this fails: I probably just didn't understand my manual. Any ideas? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] function troubles...

2005-03-17 Thread William Stokes
I don't know whats wrong with this. Can someone help please. This will print: "shaisse" but nothing else. I need to know why the other variables won't print. The sql query worksand echoes work if not used in function. I tested it in an other file and it worked but when I put it in a function

[PHP] passing return value from fucntion

2005-03-17 Thread William Stokes
Hello, Just simple question (I think?) How to pass return value from function to the main program? Here's example: do some code in funtion to set the $res value: } elseif ($rightsid == $oik6) { $res = ok; return $res; } elseif ($rightsid == $oik7) { $res = notok; return $res; } How

Re: [PHP] passing return value from fucntion

2005-03-18 Thread William Stokes
. If you really write your code like that exactly, the two words "ok" and "notok" wont have any effective meaning. wish it helps to you. On Fri, 18 Mar 2005 09:33:13 +0200, William Stokes <[EMAIL PROTECTED]> wrote: > Hello, > Just simple question (I think?) > &g

[PHP] sessioncookies?

2005-03-18 Thread William Stokes
Hello, I have a following line in my code to set a session cookie when user logs in. It works fine. setcookie("sess_id","$sess_id",0,"/"); Can I store more information to the session cookie? I mean other variables. Like I tried it like this with no success. setcookie("sess_id","$sess_id",$anoth

Re: [PHP] sessioncookies?

2005-03-18 Thread William Stokes
Will "Ken" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > No, you'll have to use another cookie name. > Alternatively, you can use arrays > > setcookie('cookiename['arrayname']', $value, time()); > > > On Fri, 18 Mar 200

[PHP] remove space

2005-03-22 Thread William Stokes
Hello, How can I remove a space character from variable value. for example: change $name = "John Doe"; to $name = "JohnDoe"; The blank space needs to be removed from the string. How? Thanks a lot! _will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.

[PHP] file upload

2005-03-24 Thread William Stokes
Hello, I'm (slowly) learning how to make a file upload stuff with php. Now I would like to know how to define the servers upload directory in the code? For example I have the upload script in folder /www in the www.domain.com server and I want upload the files to /www/uploads folder. So how do

Re: [PHP] file upload

2005-03-24 Thread William Stokes
ROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > http://www.hotscripts.com/Detailed/24113.html > take a look at this.. perhaps you can reverse engineer it > > > > > > "William Stokes" <[EMAIL PROTECTED]> > 24/03/2005 09:18 > > To > php-ge

Re: [PHP] file upload

2005-03-24 Thread William Stokes
Never mind. I got that sorted out! Thanks anyway... -Will "William Stokes" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > Okl I can't reverse engineer that... > > I just need to know how to set the path. > now I have it like this and it wont work. $

[PHP] checkbox value

2005-03-24 Thread William Stokes
Hello, I have a checkbox in a form. How can I determine if the user has set the checkbox on or not? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] delete file

2005-03-24 Thread William Stokes
Hello, How can I let user delete a uploaded image file in the server's directory? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] image problem

2005-03-24 Thread William Stokes
Hello, I really can't figure this out. Can someone help please. I've wasted hours already with this one. I'm trying to print image to a web page using fpassthru. Here's the code: $name = path/to/the/image/folder/img1.jpeg; $fp = fopen($name, 'rb'); // send the right headers header("Content-

[PHP] Generate random number

2005-03-30 Thread William Stokes
Hello How can I generate a ramdom number let's say between 1- 1 000 000 and store it in a variable? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Generate random number

2005-03-30 Thread William Stokes
never mind... :-) "William Stokes" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > Hello > > How can I generate a ramdom number let's say between 1- 1 000 000 and > store it in a variable? > > Thanks > -Will -- PHP General Mailing List (

[PHP] asking comment

2005-03-30 Thread William Stokes
Hello, I got a bit frustrated with image upload stuff with different image name problems. So I created a system that gives the uploaded imaged a random numeric name between 1-10 000 000 and saves the file to a server folder and the image name to mysql DB. Is there a so sort of a problem here t

[PHP] image_type

2005-03-30 Thread William Stokes
Hello, I was under impression that php automatically gives values to image_type and image_name if one tries to upload image from a web form if the name of the uploaded image field is image. If I do this I can see that there is a path for the uploaded image in a variable but the echo won't prin

[PHP] file upload

2005-04-04 Thread William Stokes
Hello, I might have asked this already but I am still ignorent ;-) How to check if a same name file already exists in a upload directory when uploading new file? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] if question

2005-04-06 Thread William Stokes
Hello, I need to test if a variable value is 3 or 6 or 9 or 12 or 15 or 18 ... goes on like this. How this can be done? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] setcookie ???

2005-04-06 Thread William Stokes
This doesn't set the cookie? Can you see why? I can't... $showbrowseteam = 'somejargon'; setcookie("showbrowseteam","$showbrowseteam",0,"/"); Thanks -will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] chop string

2005-04-07 Thread William Stokes
What was the string chooping function? I need to chop a date value from DB like (07.04.2005) and time (22:00) to $day ='07' $month='04' etc. etc. Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] switch question

2005-04-07 Thread William Stokes
Hello, Can I jump to html and back to php in the middle on switch example: do some html do some html etc etc. Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] sql question

2005-04-07 Thread William Stokes
Hello, This is not a php but sql question. My apologies but I don't know any good sql forums and I know that someone here might be able to answer. OK so the question is. How to make a SELECT query with WHERE definition that requires 2 conditions to be satisfied so that the row gets selected? M

[PHP] another non php Q

2005-04-07 Thread William Stokes
Is there a way to limit a size with som sort of a maxlength value I know it's not php but thanks anyway -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] sql groups

2005-04-12 Thread William Stokes
Know any good sql discussion groups for mysql? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] delete session cookie?

2005-04-20 Thread William Stokes
Hello, Is it possible to delete a session cookie from browser? If so how? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] delete session cookie?

2005-04-20 Thread William Stokes
Thanks. That's what I was looking for... "Burhan Khalid" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: >> Hello, >> >> Is it possible to delete a session cookie from browser? If so how? > > http://www.php.net/ma

[PHP] reverse MD5 ???

2005-04-21 Thread William Stokes
Hello, I have a system that uses certain id info. This info is stored in a session cookie in MD5 format. At certain parts of the code I need to update or insert to MySQL DB with that id info value in cleartext. Is this possible? If so, how to put this to a sql query? $sqlquery = "insert into

[PHP] From form to db question

2005-04-24 Thread William Stokes
Hello, I writing a script that allows user to update a soccer league table with web form. I made a script that prints the old values to text fields in the form. It's done with a loop so that each text field name is numbered +1 higher than previous. My problem is how to put the changed data bac

[PHP] Opera 8.0 cache ????

2005-04-25 Thread William Stokes
Hello, Is there somethigh special about Opera 8 and it's way to locally store variable values? I have a application which uses 2 variables to determine what information to retrieve and output from DB. At the first page user has to decide what to do and after that his given 2 variables $updatei

[PHP] Cache control

2005-04-26 Thread William Stokes
Hello, I have an web application that checks users rights to specific parts of the apllication at the beginning of each page. However I noticed, with the help of Jason Barnett, that opera caches pages locally and the users rights check fails. The application works fine with Firefox and IE. So I

[PHP] Re: Cache control

2005-04-26 Thread William Stokes
Talkin' to myself... does this solve the issue? header ("Cache-Control: no-cache"); -Will "William Stokes" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > Hello, > I have an web application that checks users rights to specific parts of >

Re: [PHP] Re: Opera 8.0 cache ????

2005-04-26 Thread William Stokes
06:46:58 -0700, Jason Barnett > <[EMAIL PROTECTED]> wrote: > >> William Stokes wrote: >> ... >>> This works fine in IE and Firefox but Opera "remembers" users previous >>> choice and prints wrong info to user. After pressin refresh button it's &

[PHP] User Logout system advice needed...

2005-04-27 Thread William Stokes
Hello, I need to write some sort of a user logout system for my web application. It needs to be a solid system so that if the user presses the Logout button there's no way of returning to the password protected area without logging in again. At the moment my "system" only tries to close browse

Re: [PHP] User Logout system advice needed...

2005-04-28 Thread William Stokes
OK. How about preventing access by hitting the browsers back button after the user has logged out? -Will "Petar Nedyalkov" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] sort by date

2005-05-05 Thread William Stokes
Hello, I made a mistake and stored date information to DB as varchar values (dd.mm.yyy). When I read the DB is it still possible to sort the data by date with SQL query (ORDER BY date ASC)? Or is it nessessary to have the date information to be stored as a date in the DB? Will it work or is the

[PHP] Re: sort by date

2005-05-06 Thread William Stokes
work cause it's a varchar field in the DB. Any idea how to put STR_TO_DATE() in to the following SQL query: SELECT event_id,name,date,time,place,type,info FROM test_table WHERE (group = '$group') AND (type = 'Game' OR type = 'training') ORDER BY date ASC Thanks a

Re: [PHP] sort by date

2005-05-06 Thread William Stokes
OK. I found that out from MySQL manual. I just don't know how to insert the date formatting function to the query: I quessI need to put STR_TO_DATE() in to the following SQL query: SELECT event_id,name,date,time,place,type,info FROM test_table WHERE (group = '$group') AND (type = 'Game' OR type

Re: [PHP] sort by date

2005-05-09 Thread William Stokes
Thanks Richard. That did the trick. Now to the DB fixing business... -Will "Richard Lynch" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > On Thu, May 5, 2005 10:42 pm, William Stokes said: >> I made a mistake and stored date information to DB as varchar va

[PHP] Dropdown menu

2004-05-11 Thread William Stokes
Hello, A question about forms and PHP. I have a dropdown list which gets the lines in the list from DB. Like this(col1 is used only for sorting the data): echo "choose one:"; $sql="SELECT col1, col2 FROM table_04 ORDER BY col1"; $result=mysql_query($sql); $num = mysql_num_rows($result); $counter

Re: [PHP] Dropdown menu

2004-05-11 Thread William Stokes
Thanks! I found the answer from: http://codewalkers.com/tutorials.php?show=12 "Daniel Clark" <[EMAIL PROTECTED]> kirjoitti viestissä news:[EMAIL PROTECTED] > Hi Bill. > > Put something like: > > > ##your form selections here## > > > > Then on your read_form.php page: > > $what_they_selected = $_

[PHP] popup windows & variables

2004-04-30 Thread William Stokes
Hello I need to open a popup window from my php page . The information displayed on this popup depends on a variable value on the first page. How do I paste/move the variable value to the popup window. The popup is opened via javascript. I have no idea how to do this. Hope someone can help. Thaks

[PHP] calendar Q

2006-08-10 Thread William Stokes
Hello, I have a calendar script that displays a simple mini calendar view one month at a time. User can click any date and the calendar opens another page that displays that date's events. I would like to highlight to the mini calendar view dates that have an event in database. So what would be

Re: [PHP] calendar Q

2006-08-10 Thread William Stokes
-Will ""Richard Lynch"" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > On Thu, August 10, 2006 12:14 pm, William Stokes wrote: >> I have a calendar script that displays a simple mini calendar view one >> month >> at a time. User can click

[PHP] file uploads Q?

2006-12-09 Thread William Stokes
Hello, I have somehow managed to write a scipt that is able to upload and resize images to a server :))) Sad part is that now the user can upload only one image at a time.(user has a browse button for browsing images in his local disk and can pick only one at a time). Is it possible to allow

[PHP] $POST Q

2006-12-12 Thread William Stokes
Hello, Can someone tell me what wrong or to how to manage this? //default $limitorig = 10; echo ""; echo "$limitorig"; echo "10"; echo "20"; echo "30"; echo "; When the form is first printed the selected default (10) value is shown OK and if something is selected everything is fine. If I just

[PHP] Cookies & page refresh

2006-12-12 Thread William Stokes
Hello, I have a page that uses session cookies for deciding what content to show to a visitor. User also has 2 form objecks to apply filters to the content SQL queries. So at the beginning of the script I set 2 cookies based on user selections(or defaults) and after that make DB query based on

Re: [PHP] Cookies & page refresh

2006-12-12 Thread William Stokes
Thanks. It seems that I tested the right things but in a wrong order... -Will "Chris" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: >> Hello, >> >> I have a page that uses session cookies for deciding what content to s

[PHP] Paste variable from popup to previous page?

2006-12-12 Thread William Stokes
Hello, How can I pass a variable from popup window back to the page that originally opened the popup? Or can I? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Paste variable from popup to previous page?

2006-12-12 Thread William Stokes
Hello, How can I pass a variable from popup window back to the page that originally opened the popup? Or can I? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] loop Q

2006-02-24 Thread William Stokes
What does this do in a for loop? $counter+=1 Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] loop Q

2006-02-24 Thread William Stokes
Cheers! "Jochem Maas" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: >> What does this do in a for loop? >> >> $counter+=1 >> > > it's shorthand for $counter = $counter + 1; > which in this case (because

[PHP] Date question

2006-02-24 Thread William Stokes
Hello, I have a datetime column in MySQL DB. How can I match to that column from php code if I only have the date information available. 2006-02-24 12:00:00 against2006-02-24 This might be more SQL question sorry about that. Thanks -Will -- PHP General Mailing List (http://www.php.net/)

[PHP] Re: Date question

2006-02-24 Thread William Stokes
Yep. Nevermind... (and back to sleep) ""William Stokes"" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > Hello, > > I have a datetime column in MySQL DB. How can I match to that column from > php code if I only have the date information avail

[PHP] Hiding text?

2006-04-12 Thread William Stokes
Hello, How can I hide error message when user enters to POST action form for first time? I have a form for collecting and saving user data. In the code below you can see that there are text messages for user info stored in $teksti variables. At the end the $teksti is passed to function that di

[PHP] var_dump($POST)

2006-04-12 Thread William Stokes
Hello, var_dump($POST) returns now always NULL. Before it returned the POST variables and their values like it should, right? Is there something that the operator could have done in the server that causes this? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visi

Re: [PHP] var_dump($POST)

2006-04-12 Thread William Stokes
oooppps :) sorry about that one... "Albert Padley" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > > On Apr 13, 2006, at 12:16 AM, William Stokes wrote: > >> Hello, >> var_dump($POST) returns now always NULL. > > Try var_dump($_POST); >

[PHP] preventing duplicate rows?

2006-04-12 Thread William Stokes
Hello, I'm updating a table with following SQL statement $sql = "INSERT INTO x_ikaluokat (ryhma, ikaluokka) VALUES ('$ryhma','$ikaluokka')"; What would be the best way to test that similar rows doesn't get created to the table? I can't make both columns unique. Thanks -Will -- PHP Gener

[PHP] POST arrays?

2006-04-20 Thread William Stokes
Hello, How to post an array with associated values? This works ok But if I post it to another form with this: "> And print there with: print_r($arr_siirt_jouk); prints: Array So how can post the values forward? Thanks -Will -- PHP General Mailing List (http://www.php.net/) To unsubscr

Re: [PHP] POST arrays?

2006-04-20 Thread William Stokes
No other way? "Stut" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: > >>How to post an array with associated values? >> >>This works ok >> >>>$arr_siirto = array(1,2,3); >>print_r($arr_siirto); >&g

Re: [PHP] POST arrays?

2006-04-20 Thread William Stokes
; <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: >> No other way? >> >> > > Over sessions or saving as file and loading it in the following page. > > -- > Smileys rule (cX.x)C --o(^_^o) > Dance for me! ^(^_^)o (o^_

Re: [PHP] POST arrays?

2006-04-20 Thread William Stokes
"Why do you want to post it to itself? Why not use a session instead? " -I dont know. Never tried "session" "It's a lot more efficient." -OK. Is it more complicated to write? -Will "Stut" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECT

Re: [PHP] POST arrays?

2006-04-20 Thread William Stokes
OK. Must try that. BTW theres something odd about my serialize. I got it return something but not quite what was expected :) Here's the result "a:3:{i:0;s:1:" -W "Stut" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: > &g

Re: [PHP] POST arrays?

2006-04-20 Thread William Stokes
Is it bad just to remove the single quotes [ ' ] ? "Stut" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: > >>OK. Must try that. >> >>BTW theres something odd about my serialize. I got it return something but >&

Re: [PHP] POST arrays?

2006-04-20 Thread William Stokes
>From here: $arr_siirto = array((serialize('1','2','3')); after removing the single quotes it started to work. -W "Stut" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: > >>Is it bad just to rem

Re: [PHP] POST arrays?

2006-04-20 Thread William Stokes
You're right. BTW, can sessions and $POST be mixed? If yes is there any reason what so ever to do that? -W "Stut" <[EMAIL PROTECTED]> kirjoitti viestissä:[EMAIL PROTECTED] > William Stokes wrote: > >>From here: >>$arr_siirto = array((serialize('

  1   2   >