[PHP] Re: PHP, MySQL problem

2004-01-14 Thread Jan Grafström
Hi Add records with this code. name address Hope this helps. Jan "Nicolai Elmqvist" <[EMAIL PROTECTED]> skrev i meddelandet news:[EMAIL PROTECTED] > Hi > > I have just started working with PHP and MySQL and have gone through 3 > tutorials on how to add and delete records from a databa

[PHP] mysql row num, offset?

2003-11-24 Thread Jan Grafström
Hi, can I get the rownumber (offset) from mysql? After I have made a select I want to generate an update query wich works for any table. Thanks in advance for any help. Jan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Can't pass query string from HTML to PHP

2003-06-19 Thread Jan Grafström
Hi Robby, try to add this line to your php-file: $name=$_GET['name'] ; change to: Good luck! Jan "Robby Ku" <[EMAIL PROTECTED]> skrev i meddelandet news:[EMAIL PROTECTED] > Hi, > > I've got a problem passing a query string from a HTML file to a PHP file. I created a HTML file called "welcome.ht

[PHP] Re: replace string in array

2003-03-16 Thread Jan Grafström
Chris, you can splice an array http://www.php.net/manual/sv/function.array-splice.php Jan Grafstrom "Chris Winters" <[EMAIL PROTECTED]> skrev i meddelandet news:[EMAIL PROTECTED] > I'm having a bit of trouble... > > I have an array that consists of a string like this: > > string1\rstring2\rst

[PHP] Re: Multiple values per variable

2003-03-12 Thread Jan Grafström
user1 abc $user1_array=array(); array_push($user1_array, "a","b","c"); //check user_array $cat=""; for ($i=0;$i skrev i meddelandet news:[EMAIL PROTECTED] > I am working on some logic where users are categorized based on the results > from a few questions. So far everything is working properly,

[PHP] Re: really simple problem with GET

2003-03-12 Thread Jan Grafström
Try ...test.php?test=0 //no $ before test= /Jan "Kelvin Poon" <[EMAIL PROTECTED]> skrev i meddelandet news:[EMAIL PROTECTED] .ca... > Hi, > > I am sorry if the level of this question is too simple but I can't figure > out what's wrong. I want to pass a variable value through the URL using the >

[PHP] backslash t

2003-01-22 Thread Jan Grafström
Hi, I want php to print " \tab" but when I do, I only get "ab" as output. How do I keep the \t? Thanks in advance. Jan Grafström -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] can I mail unlimited in one click?

2002-12-16 Thread Jan Grafström
Hi, I wonder if I can mail 300 customers in one click? part of script: while($listrow = mysql_fetch_array($listresult)) { $recipient = $listrow[epost]; $subject = "$subj"; $message = "$mess"; $headers .= "From: $admail\n"; $headers .= "Reply-To: $admail\n"; $headers .=

[PHP] protect downloadable files

2002-12-12 Thread Jan Grafström
Hi, I have some zipfiles in a directory and wonder how to protect the files? I send the customer to a downloadpage with links after succsessfull login. What is best to do? chmod the files when I upload them and change chmod if I have a verifief user? Any suggestions? -- Regards Jan Grafstrom -

[PHP] Warning: Failed to write session data ?

2002-10-16 Thread Jan Grafström
this frame loaded from another server. I have my mainsite on one server and shopsite on another. Thanks in advance for any help. -- Regards, Jan Grafström Sweden -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] ssl security question

2002-06-08 Thread Jan Grafström
same url? If a hacker sniff the ssl-string can he send that string and start the file anyway? -- Regards, Jan Grafström Sweden -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Can I get back a deleted row from mysql?

2002-06-06 Thread Jan Grafström
Hi, I wonder if you can get back or view the deleted data in a delted row in mysql? "DELETE FROM $table WHERE id=$id" I used the above code to delete. Thanks for any help. -- Regards, Jan Grafström Sweden -- PHP General Mailing List (http://www.php.net/) To unsubscribe, v

[PHP] How do I make tab spaces in a mail?

2002-03-19 Thread Jan Grafström
, $subject, $message, $headers); How do I write to get the tab spaces? -- Regards Jan Grafström sweden -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Somebody knows about SecureLink?

2002-03-15 Thread Jan Grafström
ifiedserver.com", 443, 80 SecureLink.SetContentServer "www.webshop.com", 80,"/webshop/" SecureLink.SetKeyFileName "c:/programs/securelink/secrets/flat_o.kf" SecureLink.SetOfrFileName "c:/programs/securelink/osl40.ofr" SecureLink.SetApplStoreID "000000" SecureL

[PHP] Netscape 6.2 session problem?

2002-03-11 Thread Jan Grafström
Thanks for any help. -- Regards Jan Grafström Minisoft Sweden Bredsäter 2091 87010 Älandsbro 0611-60920 070-6409073 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: just a link in php email

2002-03-08 Thread Jan Grafström
Hi Andrea! I use this. $message="http://www.sever.com\";>link"; $message = stripcslashes($message); $headers .= "Return-Path: <[EMAIL PROTECTED]>\n"; $headers .= "Reply-To:$admail\n"; $headers .= "From: $admail\n"; $headers .= "X-Mailer: PHP\n"; $headers .= "Content-Type: text/html; charset=iso-

[PHP] Re: Finding variable names in strings, and replacing with values?

2002-03-08 Thread Jan Grafström
Hi Nick! http://www.php.net/manual/en/function.str-replace.php Regards, Jan "Nick Richardson" <[EMAIL PROTECTED]> skrev i meddelandet [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Been working on this one for quite awhile, and it's probably a fairly easy > solution, but i can't find it... so th

[PHP] sessions and netscape 6.2

2002-03-08 Thread Jan Grafström
g target=_top in all links. Now I wonder if there is any other way solving this problem? Thanks in advance. -- Regards Jan Grafström 87010 Älandsbro Sweden -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Can mysql add qty directly?

2002-02-27 Thread Jan Grafström
need to first make a separate query on soldqty or is there an easyer way? Thanks in advance. -- Regards, Jan Grafström Härnösand Sweden -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] get out of frameset?

2002-02-25 Thread Jan Grafström
cation? Thanks in advance. -- Regards, Jan Grafström Bredsäter 2091 87010 Älandsbro Sweden -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Store array into mysql?

2002-02-14 Thread Jan Grafström
first make a string commaseparated or like and than insert that string? Thanks in advance. Regards, Jan Grafström -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Protect your code

2002-01-21 Thread Jan Grafström
page, something like: $string = include ("textmaker.php3?text=testword"); I am trying to build blanks for use as a memberservice and want it difficult to reuse my code. Any tips? Thanks in advance Regards, Jan - filename=index.php "; echo $head; ?> --- filename=img

Re: [PHP] Create Image on the fly

2002-01-17 Thread Jan Grafström
Thanks Val! Now I understand. Jan "Val Petruchek" <[EMAIL PROTECTED]> skrev i meddelandet 000801c19f4a$49862950$[EMAIL PROTECTED]">news:000801c19f4a$49862950$[EMAIL PROTECTED]... > > in index.html you write > > > > in aaa.php you write > > $im = @ImageCreate (240, 80) >or die ("Cannot In

[PHP] Create Image on the fly

2002-01-17 Thread Jan Grafström
Hi! How do I change this if I will use the Image direct in my html-code? Do I need to save it first. "; ?> Thanks in advance. -- Regards Jan Grafström Lillemans Hus AB Bredsäter 2091 87010 Älandsbro 0611-60920 070-6409073 -- PHP General Mailing List (http://www.php.net/) To unsubs

[PHP] Change column in mysgl

2002-01-15 Thread Jan Grafström
Hi! Can I change this column "adress VARCHAR(25)" to "adress VARCHAR(40)" afterwards. I use mysql. Thanks for any help Regards, Jan -- Jan Grafström Lillemans Hus AB Bredsäter 2091 87010 Älandsbro 0611-60920 070-6409073 -- PHP General Mailing List (http://www.php.net

[PHP] page3 will not work

2001-12-26 Thread Jan Grafström
ntinue, click here -- page2.php: //this code doesn´t work -- page3.php//I can´t get the session recogniced so I always get "nopermission.htm" Thanks for any help. Regards, Jan -- Jan Grafström Lillemans Hus AB Sweden 46 (0)611-60920 46 (0)70-6409073 -- PHP General Ma

Re: [PHP] Sessions php and flash5, cookies disabled

2001-12-25 Thread Jan Grafström
gards, Jan "Brian Clark" <[EMAIL PROTECTED]> skrev i meddelandet 20011225165631.GF8638@ganymede">news:20011225165631.GF8638@ganymede... * Jan Grafström ([EMAIL PROTECTED]) [Dec 25. 2001 10:41]: > The url string looks like this on php-page (sent from flash5): > mypa

[PHP] Sessions php and flash5, cookies disabled

2001-12-25 Thread Jan Grafström
SID=PHPSESSID%3D193a33f9b7421c17302d1bd58478b20b&var3=1. "=" has changed to "%3D". and php does not recognice the session. part of code on mypage.php3: http://myserver.com/second.php3?\"; method=\"get\"> Thanks for any help. -- Jan Grafström Lillemans Hus AB Sw

[PHP] error with php 4.1

2001-12-11 Thread Jan Grafström
ntrer=\"Admin Basta\""); header("HTTP/1.0 401 Unauthorized"); echo "Access in-autorizado..."; exit; } It worked well under PHP 4.04. Anbody knows why? Thanks in advance for any help. Regards, Jan -- Jan Grafström Lillemans Hus AB Sweden 46 (0)611-60920

[PHP] copy image from database

2001-12-08 Thread Jan Grafström
UERY($query); $image = @MYSQL_RESULT($result,0,"bin_data"); echo $image; $destfile="image.jpg"; copy($image,$destfile) ----- Thanks for any help Regards, Jan -- Jan Grafström Lillemans Hus AB Sweden 46 (0)611-60920 46 (0)70-6409073 -- PHP General Mailing List (http://www.

[PHP] Re: .inc files

2001-11-04 Thread Jan Grafström
Hi Rudi! Check out this example from Hotscripts. http://www.hotscripts.com/cgi-bin/dload.cgi?ID=12367 Regards Jan Grafstrom "Rudi Ahlers" <[EMAIL PROTECTED]> skrev i meddelandet 008401c16534$dcb77580$0c00a8c0@camelot">news:008401c16534$dcb77580$0c00a8c0@camelot... > Hi > > I was wondering, is the

[PHP] Re: User authentication?

2001-11-04 Thread Jan Grafström
Hi Daniel! Phpbuilder have some articles with examples under security. http://www.phpbuilder.com/columns/ Regards Jan Grafstrom Lillemans Hus AB Sweden "Daniel alsén" <[EMAIL PROTECTED]> skrev i meddelandet [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi, > > do aonyone know of any comprehensiv

[PHP] Thanks Jason

2001-10-03 Thread Jan Grafström
Regards Jan Jason Stechschulte wrote: > On Wed, Oct 03, 2001 at 02:13:54PM +0200, Jan Grafström wrote: > >>How does server handle the .inc extension and for what do I use it ? >>Where can I read about it? >> > > This depends on the setup of the web server. On s

[PHP] File extension inc?

2001-10-03 Thread Jan Grafström
Hi! How does server handle the .inc extension and for what do I use it ? Where can I read about it? Thanks in advace Jan Grafström -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list

[PHP] How to list 2-6 in while script?

2001-09-11 Thread Jan Grafström
Hi! I have this script and wonder how to change it to get it list only number 2 to number 6 and not each? while (list ($key,$val) = each ($headers)) { print ""."$val".""; } Thanks in advance. Regards Jan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECT

[PHP] for and emailmessage

2001-09-02 Thread Jan Grafström
Hi! I have this file and it doesen´t write my tablerows: $message .= "" $message .= "Varunamn"; $i = 0; $ii = count($vn); for ($i=0;$i<$ii;$i++) { $message .= "".$vn[i].""; } $message .= "Sum"; $message .= ""; I am trying to build a htmlmail but how do I write the for script for all tablerows? Th

[PHP] Stop if word is found?

2001-05-08 Thread Jan Grafström
Hi! I am searching some files for a word and if word is found I will stop the script. I tried with die, but I have never used it before and it didn´t work perhaps I used it in a wrong way.. $fd = fopen($filename1, "r"); $string = fread($fd, filesize($filename1)); $fruits = explode (" ", $string);

[PHP] Can php give me row number?

2001-05-06 Thread Jan Grafström
Hi! First I wan´t to thank those kind guys who helped me with the search for words in a string. It works fine and here goes my file: --- $fd = fopen($filename1, "r"); $string = fread($fd, filesize($filename1)); fclose($fd); if (eregi("$word", $string)) { print "found the word"; } - Now I a

[PHP] problem search in array

2001-05-03 Thread Jan Grafström
Hi! This file will not work for me. I have tried in several ways and I want it to print "Got word" if it find $word. $filename = "test.xml"; $fp = fopen($filename, "r"); $string = fread($fp, filesize($filename)); $string = strip_tags($string); $refined_string = explode(" ", $string); if (in_a

[PHP] php search xml-file

2001-04-08 Thread Jan Grafström
Hi! I have this xml: car ford 3600 - and this php: $filename = "list.xml"; $fp = fopen($filename, "r"); $string = fread($fp, filesize($filename)); $string = strip_tags($string); $refined_string = explode(" ", $string); if (in_array($needle." ", $refined_string)) { print "found";

[PHP] Array of words in textfile?

2001-04-05 Thread Jan Grafström
Hi! I want to read a textfile (cat, dog, rat,) and get it like this: $namesArray = array("cat,", "dog,", "rat,"); If I can do this than I can go on and make changes in my array. Like the examples in php manual. Thanks in advance for any tips. Regards Jan -- PHP General Mailing List (http://

[PHP] How to don´t write if exist

2001-04-05 Thread Jan Grafström
Hi! I want php to check if a word already exist and then don´t write it to the file. This is my file list.txt: car, cat, dog, ... and my php which need some more function: -- $fp = fopen("list.txt", "a"); $string = "$word".","." "; fwrite ($fp, $string); fclose ($fp); --- I want to add: If

[PHP] problem with php-ftp ftpbuf?

2001-04-04 Thread Jan Grafström
Hi! I tryed the ftp script found in php manual. I got this errormessage: --- Warning: Unable to find ftpbuf 0 in /home/myName/public_html/sess/ftpfile.php3 on line 6 --- What does ftpbuf mean? Thanks for any help. Regards Jan -- PHP General Mailing List (http://www.php.net/) To unsub

Re: [PHP] Can php read and than print file like it is

2001-04-02 Thread Jan Grafström
Thank You Steve! Here is my php -- Regards Jan Steve Werby wrote: > "Jan Grafström" <[EMAIL PROTECTED]> wrote: > > I have a file with text on 17 rows and when I let php read it ,get > > filezise and than print I only get the first row. > > I want a

[PHP] Can php read and than print file like it is

2001-04-02 Thread Jan Grafström
Hi! I have a file with text on 17 rows and when I let php read it ,get filezise and than print I only get the first row. I want all rows exatly like it is in the file, is it possible? My file: some rows here Thanks in advance for all help I can get. Regards Jan -- PHP General Maili

[PHP] session question

2001-04-02 Thread Jan Grafström
Hi! I am trying to learn about sessions and set up this file, This seams not to work on the file fillista.xml, I can still read it afterwords in IE:s cache. How do I pass the session to a xml-file on server? Thanks for any help. Regards jan -- PHP General Mailing List (http://www.php.net/)

[PHP] How to send a mail in html format

2001-04-01 Thread Jan Grafström
Hi! Can I add something in this string to get a htmlpage sent as mail? mail($recipient,$subject,$corps,"From: $admail\nReply-To:$admail\nX-Mailer: PHP/"); Thanks in advance. Regards Jan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

Re: [PHP] login without database

2001-03-30 Thread Jan Grafström
der("WWW-Authenticate: Basic entrer=\"Admin Basta\""); > header("HTTP/1.0 401 Unauthorized"); > echo "Access in-autorizado..."; > exit; > } > > where access.inc.php has the variables $st_LOGIN and st_PASSWORDS for > authenticate you lo

[PHP] login without database

2001-03-30 Thread Jan Grafström
Hi! Can I use php to make a login system for users? I don´t have a databas on my server. I only want to have a few users. When I send variables to php the string is always cached by IE5.5 and it´s very easy to se the username and password if you look i cache. Is there a way to get this done only o

[PHP] Can You get a file unlinked after one month?

2001-03-25 Thread Jan Grafström
Hi! I wonder if it is possible to delete a file using unlink and a time function. I wont the file to be automtically unlinked after a month. I am very thankful for any help. Regards Jan Grafstrom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For a

[PHP] How to completly remove a file?

2001-03-07 Thread Jan Grafström
Hi! When I run this PHP my file idb.xml returns empty but how do I do if I then whant to remove the file idb.xml. I just doesn´t want it empty, I want it to disappeare.? Thanks for help. Jan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additi

[PHP] Adding new data at beginning.

2001-02-22 Thread Jan Grafström
Hi! I am trying to put in a new data at the beginning of a file. I have started like this; $yourfile = "test.xml"; ( this is the file.) $fp = fopen ($yourfile, r); $message = array(1 => '', '', '', '', '', '', ''); Here I need some code to get the output look like this"" print_r($mes

[PHP] help change filename.

2001-02-21 Thread Jan Grafström
Hi! I am trying to change a filename this is my php: It doesn´t work do I need some more code to get it working, something like fopen? Thanks for any help. Regards Jan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mai

[PHP] Can you check if someone is online on your homepage?

2001-02-21 Thread Jan Grafström
Hi! Can you use a php-script to see if there is someone on your homepage? Im going to make a demo with flash, php,xml and xsl and if more than one at the moment are testing the demo, it won´t work beacause of the work-file is cleaned up every time someone enters.If you can see a digit on the page

[PHP] Can you make a file empty?

2001-02-20 Thread Jan Grafström
Hi! I am trying to delete all text in a file. $yourfile = "file.txt"; $fp = fopen($yourfile,w) "is there any good code to put in here?" fclose($fp); Thanks for any help. Regards Jan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional com

[PHP] unlik by sending variabel?

2001-02-20 Thread Jan Grafström
Hi! I am trying to get a file deleted when I send a variabel with the value "delete". I have this file: - $message = ereg_replace("\r","", $message); $message = "$message$name; $fp = fopen (basename($PHP_SELF) . ".xml", "a"); fwrite ($fp, $string); fclose ($fp); - and the file I want unl

Re: [PHP] HTTP POST Question

2001-02-20 Thread Jan Grafström
Thankyou Julian but I am posting my variable from flash5. The posting is not my problem. I just can`t write the unlink code. Julian Wood wrote: > Check out http://px.sklar.com/code-pretty.html?code_id=313 > > It is a post class written by Alan van den Bosch which will do what you want > (post to

[PHP] trying to get xml-file

2001-02-19 Thread Jan Grafström
Hi! I have this PHP: - $message = ereg_replace("\r","", $message); $message = "$message$name$email$adress$telefon"; $fp = fopen (basename($PHP_SELF) . ".xml", "a"); fwrite ($fp, $message); fclose ($fp); -- I want to getat the beginning and at the end, inside the bok I want several . is i

[PHP] php flash and textfile in chatapp.

2001-02-17 Thread Jan Grafström
Hi! I am trying to build a flashchat and got problems with browser cache. Every 2 sec flash send these variables to server loadVariablesNum ("http://www.myserver.com/eget9.php3?name=" add name add "...) and gets the answer from server. All files are cached by IE5.5 and looks like this: http://www.

Re: [PHP] How to get new row on top?

2001-02-17 Thread Jan Grafström
ame -- $date $message > "; > $fp = fopen (basename($PHP_SELF) . ".comment", > "a"); > fseek($fp, 0); // works both with php4.0.1pl1 <, > > fwrite ($fp, $message); > fclose ($fp); > } > @readfile(basename(($PHP_SELF . ".comm

[PHP] How to get new row on top?

2001-02-17 Thread Jan Grafström
Hi! I have this code: $message = ereg_replace("\r\n\r\n", "\n", $message); And the new rows are placed under the old ones. I want to change so the old messages get placed under is that possible? Thanks for help. Jan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAI

[PHP] cache problem

2001-02-16 Thread Jan Grafström
Hi! I have this php answer on the request sent from flash5 to serverside php-file: records=8&score0=14&name0=janna&med0=hej4&date0=16:11:32&score1=13&name1=janna&med1=hej3&date1=16:06:52&score2=12&name2=janna&med2=hej2&date2=16:06:42&score3=11&name3=janna&med3=hej&date3=16:06:31&score4=10&name4=J

[PHP] php and xml

2001-02-13 Thread Jan Grafström
Hi! I have this php: $message = ereg_replace("\r","", $message); $message = "$message$name$adress$tele"; $fp = fopen (basename($PHP_SELF) . ".comment", "a"); fwrite ($fp, $message); fclose ($fp); There must be something wrong in first line beacause the value of message is not writed. I also want t