Re: [PHP] Re: Handling checkboxes that aren't checked!!!

2003-11-04 Thread Daniel Clark
>> I have a page with a Form and a Checkbox. >> >> I have a second page which wants to do something depending on if the >> checkbox is selected or not. >> If its selected there is no problem. But if I tryand do anything if >> it isn't selected then it says the variable is 'undefined'. How can I >

Re: [PHP] text input truncated

2003-11-04 Thread Daniel Clark
> $xyz = "Hello World"; > > echo ""; > > ?> > > The text box shows up with "Hello" NOT "Hello World". How do I get the > entire variable? I would try single quotes here. $xyz = 'Hello World'; -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] unexpected $ in ... WTF?

2004-04-14 Thread Daniel Clark
What about line 148 the "{" ... supposed to be there? > Brian V Bonini wrote: >> Parse error: parse error, unexpected $ in /foo/bar/foo.php4 on line 150 >> >> 146: >> 147: > 148: } >> 149: include "foobar.inc.php4"; >> 150: ?> -- PHP General Mailing List (http://www.php.net/) To unsubscribe, v

Re: [PHP] transformation to htm file when downloaded

2004-04-15 Thread Daniel Clark
The PHP code is processed on the web server and removed. Only the HTML and images are sent back to the clients browser. > I'm just starting to get PHP, and I'm wondering about the security of the > code I write. It _seems_ that when I try to download the PHP file directly > (like using Save Tar

Re: [PHP] alternating row color--newbie help

2004-04-15 Thread Daniel Clark
Are you sure there is data in "name, phonenumber, age" ?? > Well, I've hit all the forums and tried it a few different ways, but I > still > can't get this code to work. At this point it just shows me an empty > table > with column headings. I am new and still experimenting, but can someone >

Re: [PHP] http header

2004-04-17 Thread Daniel Clark
Yes, that works. >>Is the following code the best way to redirect someone to a different >>page using PHP? >> >>>header("Location: http://www.yahoo.com";); >>?> >> >>I looked for a "redirect" function of some kind and didn't come up with >>anything. Just curious what the consensus is...

Re: [PHP] why doesn't this work ?

2004-04-17 Thread Daniel Clark
The browser doesn't know what to do with PHP code. >>If I put the following script in a .php file it would work but if I put it >>in an .html file doesn't work, why? script tag is only used in .html file. >> >> >>echo "
    "; >>if ($handle = opendir('.')) { >> while (false !== ($file = readdir(

Re: [PHP] why doesn't this work ?

2004-04-17 Thread Daniel Clark
I should have also said: Because it's missing the tags, the web server isn't going to run the code, but pass it back to the client browser. >>If I put the following script in a .php file it would work but if I put it >>in an .html file doesn't work, why? script tag is only used in .html file.

Re: [PHP] Array Problem

2004-04-17 Thread Daniel Clark
How about count() >>That's how you could do it ... >> >>$ar = array(); >> >>$len = strlen($a); >>for ($i = 0; $i < $len; ++$i) { >>$ar[] = $a{$i}; >>} >> >>HTH >> >>Richard -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Rporting tool - CVS?

2004-04-17 Thread Daniel Clark
Beyond Compare is a pretty cool diff program. www.scootersoftware.com They have a demo version. >>Scenario : >>Im working on several large projects, all which have several users. >>Each user has a personal innstallation. >> >>Each of my projects are in constant development, and often the

Re: [PHP] why doesn't this work ?

2004-04-17 Thread Daniel Clark
Can you post the code and error. >>I took out the scrip tags and put in at the >>end, but it returns this: >> >>$file >>"; } } closedir($handle); } echo " >>"; ?> -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Removing line breaks...

2004-04-17 Thread Daniel Clark
str_replace( $line, '\n', '') http://us2.php.net/manual/en/function.str-replace.php >>How do i turn this... >> >>[br] >> [b]My Title [/b] >>[br] >> >>into >> >>[br][b]My Title[/b][br] >> >> >>--- I just need to have line breaks removed basically... >> >>any ideas? -- PHP General Mailing List (

Re: [PHP] why doesn't this work ?

2004-04-18 Thread Daniel Clark
You have this as a xxx.php file right? It has to have a .php extension for it to work. >>I put this in the body of an html file: >> >>>if ($handle = opendir('.')) { >> while (false !== ($file = readdir($handle))) { >> if ($file != "." && $file != ".." && eregi('\.html$', $file)) { >>

Re: [PHP] why doesn't this work ?

2004-04-18 Thread Daniel Clark
The web server is set up to see the .php file extension and pass the entire page to the PHP engine for processing. Then the web server passes the results back to the client's browser ( HTML, text, and images). >>Yes, the server supports php, and I don't want to make it into a php file >>beca

Re: [PHP] session var problems

2004-04-18 Thread Daniel Clark
Do yo have have start_session() on every page to before you can read session variables? >>Dear list, >>I am trying to set a simple session variable on PageA. >> >>$_SESSION['CategoryID'] = intval($Data['ID']); >> >>if I print after setting the value on PageA, I will >>get the expected ID number. >

Re: [PHP] PHP Web Hosting

2004-04-19 Thread Daniel Clark
I'm using www.phpwebhosting.com > On Mon, 2004-04-19 at 15:14, Martin, Stanley G [Contractor for Sprint] > wrote: >> Some time ago I put up a web site on Domehost.com. Everything has been >> working great and I had a couple questions for their Tech Support but >> haven't received any feedback fr

Re: [PHP] session variables

2004-04-20 Thread Daniel Clark
hum. Try $_SESSION['test'] on page 2. > I have two test files running on a server, which is giving me a headache, > due to the fact the session variables are not been maintained across the > two > pages. > > The server is running ... > > PHP Version = 4.0.5 > register_globals = ON > Session Supp

Re: [PHP] session variables

2004-04-20 Thread Daniel Clark
Does page1 call page2? Or do you open another browser window and open page2? My understanding is some browsers to NOT transfer the same session info to another borwser window. > Tried that as well as $HTTP_SERVER_VARS, $_SESSION, etc., still cannot get > the damn thing working. > > Regards, > Cha

Re: [PHP] Re: Form Data Transfer b/w Pages

2004-04-21 Thread Daniel Clark
I agree. $_GET[] would expose the username and password on the URL. > For ease of use, i would create a session and handle it that way or you > could pass it through $_GET[] > Query string. > Would recommend $_SESSION though. > Cheers > > "Sobajo" <[EMAIL PROTECTED]> wrote in message > news:[EMA

Re: [PHP] What's wrong with this IF statement?

2004-04-22 Thread Daniel Clark
What about removing the quotes around the numbers. if ($cat_id != 53 || $cat_id != 54 || $cat_id != 55 etc... > My IF statement should be picking up on the numbers, and if the number > matches not be displaying out the information, however I look at the > outputted page and the information is s

Re: [PHP] calling php function

2004-04-24 Thread Daniel Clark
Because the Javascript onclick event runs in the client browser, you could call a php file that has and runs a particular php function. >> Is it possible to call php function in the onclick event ? >> >>REgards, >>Uma -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: ht

Re: [PHP] OK SQL experts...

2004-04-25 Thread Daniel Clark
I think you want to remove the single quotes around the field names. SELECT * FROM my_table WHERE (field_1 LIKE '%$keyword%' OR field_2 LIKE '%$keyword%' OR field_3 LIKE '%$keyword%') AND status = 'active'; >>I STFW and RTFM and I still can't figure out why this returns a 1064 >>parse error:

Re: [PHP] OK SQL experts...

2004-04-25 Thread Daniel Clark
The parenthesis are OK. The query might take a long time to run with 3 LIKE statements. >>Backticks, single quotes, or nothing at all makes no difference. I >>believe the parsing error is due to my parentheses or AND/OR structure. >>Any thoughts on that? >> >> >> >>On Apr 23, 2004, at 8:32 A

Re: [PHP] PHP Sessions on Windows

2004-05-11 Thread Daniel Clark
Sounds right. Do you have a C:\temp directory? >>How does one get sessions working on Windows? I have modified my php.ini >>file so that session.save_path = C:\Temp, restarted and Apache. Still I get >>this error message: >> >>Warning: session_start(): open(/tmp\sess_26310affee160329c9e50f27663f8

RE: [PHP] PHP Sessions on Windows

2004-05-12 Thread Daniel Clark
I think you need to restart PHP to pickup the new php.ini changes. My php.ini is in the windows directory (I believe). >> -Original Message- >> From: David Mitchell [mailto:[EMAIL PROTECTED] >> Sent: 12 May 2004 13:21 >> >> OK, I managed to get it working. >> >> I first attempted to edit

Re: [PHP] Why would a socket be unavailable?

2004-05-13 Thread Daniel Clark
I just read something about sock warnings this morning. It said sometimes they drop off, and to ignore the warnings, but capture the errors. > I get this output: > > PHP Warning: socket_read() unable to read from socket [35]: Resource > temporarily unavailable in /Users/rene/Sites/gpspolice/tit

Re: [PHP] Why would a socket be unavailable?

2004-05-13 Thread Daniel Clark
http://www.php.net/manual/en/ref.sockets.ph > I just read something about sock warnings this morning. It said > sometimes they drop off, and to ignore the warnings, but capture the > errors. > >> I get this output: >> >> PHP Warning: socket_read() unable to read from socket [35]: Resource >> te

Re: [PHP] Why would a socket be unavailable?

2004-05-13 Thread Daniel Clark
Guess it really is "experiemental" :-) >> http://www.php.net/manual/en/ref.sockets.ph > > Yes, I've read that page... many times. It has not helped me. That is > why I am posting my problem here, in that hopes that someone can help. > > (I don't mean to be completely helpless, but I just don't yet

Re: [PHP] Dropdown menu

2004-05-11 Thread Daniel Clark
Hi Bill. Put something like: ##your form selections here## Then on your read_form.php page: $what_they_selected = $_POST['name1'] >>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): >> >>ech

Re: [PHP] Uploaden files to the server

2004-05-11 Thread Daniel Clark
Does the img directory have writes permission? >>Please, >> >>Can anybody help me with my problem !! I'm getting crazy. >> >>I am trying the upload a file to the server where my website is. >>I get always the same fault when I want the try this code: >>"Warning: Unable to create 'test.jpg'

Re: [PHP] session names

2004-05-11 Thread Daniel Clark
You need to name your session variables, but no name for session_start(). >>It is necessary to always name your sessions?or is session_start() >>sufficient? >> >> >> >>Thanks, >>Eddie -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] php calender

2004-05-11 Thread Daniel Clark
It could be a HTML table with links on the properties to view more details. > I am currently working on a site for a vacation rental company. They > want > the ability to show users the availability of certain properties. The > availability will be held in a mysql db so I assume I will have to

Re: [PHP] include (or require) doesn't seem to work

2004-05-11 Thread Daniel Clark
Think you want something like this. require("/tristan/library.php"); > Hi, > > I'm almost ashamed to ask this question as surely enough the > problem is something very basic but, nonetheless, I can't put my finger on > it. I'm trying to implement the concept of a library (library.php

Re: [PHP] rounding average to one decimal point

2004-05-10 Thread Daniel Clark
How about round() echo round(1.95583, 2); // 1.96 echo round(1241757, -3); // 1242000 http://www.phpbuilder.com/manual/function.round.php > Hi, I have a randon group of numbers I need the average of. When I add > them up and divide by how many there are and print the result, I get a > lot of

Re: [PHP] How to find path for PHP script

2004-05-10 Thread Daniel Clark
What about: $_SERER['PATH_TRANSLATED'] http://www.phpbuilder.com/manual/reserved.variables.php#reserved.variables.server > Does anyone know a quick way to find the full path on a shared hosting > plan > to use in an include file? > Thanks, > Tom > -- PHP General Mailing List (http://www.php.

Re: [PHP] How to find path for PHP script

2004-05-10 Thread Daniel Clark
oops. $_SERVER[] > What about: > > $_SERER['PATH_TRANSLATED'] > > > http://www.phpbuilder.com/manual/reserved.variables.php#reserved.variables.server -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] How to find path for PHP script

2004-05-10 Thread Daniel Clark
Thanks John. > From: "Daniel Clark" <[EMAIL PROTECTED]> > >> > Does anyone know a quick way to find the full path on a shared hosting >> > plan to use in an include file? >> >> What about: >> >> $_SERER['PATH_TRANSLATED']

Re: [PHP] Re: protecting web page

2004-05-09 Thread Daniel Clark
I agree. Once the screen, text, or picture is on the clients machine they have a copy of it. >>Petr U. wrote: >>> On Sat, 08 May 2004 21:00:43 -0500 >>> Anguz <[EMAIL PROTECTED]> wrote: >>> >>> > > Do you know any solution that can help me. I've find an application named >>> > > HTML guar

Re: [PHP] Strange mails...

2004-05-09 Thread Daniel Clark
Yep. I'm getting it too. >>Each time I post a message on p.general, i receive two strange mails >>from ADVANCE CREDIT SUISSE BANK. >> >>What's this spam ? It looks like an auto-responder is subscribed on the >>newsgroup. Spammers really s*x ! >> >>Greg -- PHP General Mailing List (http://www.

Re: [PHP] page_title

2004-05-08 Thread Daniel Clark
Think you want >>I have write following code: >>>$page_title = "Welcome"; >>?> >> >>But I can not see Welcome on top of the page. >>Can someone tell me why I not can see it? >> >>Thanks >>Erik Gjertsen >> >>-- >>PHP General Mailing List (http://www.php.net/) >>To unsubscribe, visit: http://www.

Re: [PHP] Header() and POST data

2004-05-06 Thread Daniel Clark
No I don't think so. > I need to go to another page and I use the > > header("location: " . $the_url_to_the_page); > > Is it possible to use this method with POST so that the info does not > show in the URL? > > Todd -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http:/

Re: [PHP] Header() and POST data

2004-05-06 Thread Daniel Clark
You could create a new with hidden variable. And have an automatic submit onload, going to the next location. > I need to go to another page and I use the > > header("location: " . $the_url_to_the_page); > > Is it possible to use this method with POST so that the info does not > show in the URL?

Re: [PHP] Header() and POST data

2004-05-06 Thread Daniel Clark
Yes I agree, SESSION variables would be a pretty good way to pass info to the next page. > Daniel - > > What is the best way to "go to another page"? > > header("location: . $new_page); > > Todd > > Daniel Clark wrote: > >> No I don'

Re: [PHP] Register globals off, still not secure?

2004-04-30 Thread Daniel Clark
Yes. My understanding turning globals off stops using $PHP_AUTH_PW directly. > Hi, Even with register globals off isn't it possible to have a webpage > like this: > > > > > > Hello, > I know your password is > > > > > > > Is there a way to make sure apache doesn't set the $SERVER['PHP_AUT

Re: [PHP] initializing HTML form using PHP

2004-04-30 Thread Daniel Clark
That is the way I've done it. I hear that with PEAR, you can add elments to the HTML page. > I have a large HTML form (~100 form elements) that I used a year ago to > conduct a survey. Now I would like to use this same form but rather than > starting with an empty form I would like to populate t

Re: [PHP] Re: repeating data from one column until data from another column changes

2004-05-04 Thread Daniel Clark
Are you looping through the record set? >> "SELECT * FROM NewsArchive WHERE YEAR(date) = '" . date('Y') . "' AND >> MONTH(date) ='" . date('m') . "' ORDER BY sort DESC"; > > Well, still not working...but maybe closer? Not getting an error message, > just not returning any data. -- PHP Gen

Re: [PHP] Re: repeating data from one column until data from another column changes

2004-05-04 Thread Daniel Clark
Are you getting any output? > > mysql_select_db($database_jpike, $jpike); > $query_rsENews = 'SELECT * FROM NewsArchive WHERE YEAR(date) = ' . > date('Y') > . ' AND MONTH(date) = ' . date('m') . ' ORDER BY sort DESC'; > $rsENews = mysql_query($query_rsENews, $jpike) or die(mysql_error()); > $ro

Re: [PHP] Re: repeating data from one column until data from another column changes

2004-05-04 Thread Daniel Clark
Netscape browser? In your browser have you checked View Source to see it table data is there? > no. > > - Original Message - > From: "Daniel Clark" <[EMAIL PROTECTED]> > > >> Are you getting any output? -- PHP General Mailing List (http://w

Re: [PHP] Re: repeating data from one column until data from another column changes

2004-05-04 Thread Daniel Clark
Just for right now, go ahead a make the date change, or elimate the date range to get SOMETHING to come out. >> Just change the . date('m') to the actualy month you want if not the >> current month. > > > except if I have to specify the specific month I want, then every month I > have to go in

Re: [PHP] Re: repeating data from one column until data from another column changes

2004-05-04 Thread Daniel Clark
180 titles and articles.... > > "Daniel Clark" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >> Just for right now, go ahead a make the date change, or elimate the date >> range to get SOMETHING to come out. >> >> >> >> Just cha

Re: [PHP] tweeking WHERE clause

2004-05-05 Thread Daniel Clark
Hey Melissa. Will your articles always had a certain number (for each section) each month? If so a ORDER BY and LIMIT would work. Daniel > I am trying to query a table that consists of e-news artilces. in the > table > are the following fields: ID, sortBy, datePublished, title, description.

Re: [PHP] HTTP_REFERER ... ?

2004-05-05 Thread Daniel Clark
I found this in the manual: HTTP_REFERER' The address of the page (if any) which referred the user agent to the current page. This is set by the user agent. Not all user agents will set this, and some provide the ability to modify HTTP_REFERER as a feature. In short, it cannot really be trusted.

Re: [PHP] tweeking WHERE clause

2004-05-05 Thread Daniel Clark
OK how about. Do a count of this monthes articles, if NONE, then run another query to select the previous months articles. Note, this would only "publish" this or last monthes records. > there are a different number of articles each month...:( > > "Daniel Clark"

Re: [PHP] Carrying Variables

2004-05-15 Thread Daniel Clark
I uses variables and method="post" to sent them to the next page. On your 2nd page it's inserting into the database, so past that page, if I want to retain the variables I either read them again from the database OR store those variables as $_SESSION variables. >>How would I carry a variable f

Re: [PHP] Re: Carrying Variables

2004-05-15 Thread Daniel Clark
On the URL, use ? to separate the file name from the variables, and & to separate each additional variable. . &logdate= URL=check.php?Event_Type=&logdate="> >>How would you carry two variables? >> >> -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.p

Re: [PHP] elseif carry

2004-05-15 Thread Daniel Clark
I think you want double quotes around the entire line and \" for the internal double quotes. echo "'; >>I have tried both of these statements and neither one works Trying to get >>the Date and Time to be carried in the URL. Any Help please. >> >> print ''; >> >>or >> >> echo ''; -- PHP Gener

Re: [PHP] elseif carry

2004-05-15 Thread Daniel Clark
Oops. Try this. echo "" ; >>I did a cut asnd paste to your code and this is the error that I receive >> >>Parse error: parse error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting >>T_STRING or T_VARIABLE or T_NUM_STRING in c:\inetpub\wwwroot\check.php on

Re: [PHP] GET and POST variables name

2004-05-15 Thread Daniel Clark
http://www.php.net/manual/en/control-structures.foreach.php Try this. echo "GET:"; foreach($_GET as $key => $value) { echo "$key = $value "; } >>i know it could be a stupid problem, but i need a help and i hope u could be >>generous with me :). >>this is my code, it writes the list of

Re: [PHP] elseif carry

2004-05-15 Thread Daniel Clark
Ah. Must have a POST variable in that page called Date_and_Time. >>Tried it and this is the error that I get >> >> >>Notice: Undefined index: Date_and_Time in c:\inetpub\wwwroot\check.php on >>line 9 >>http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Reposting elseif carry

2004-05-15 Thread Daniel Clark
echo ""; >>I have tried both of these statements and neither one works Trying to get >>the Date_and_Time to be carried in the URL. Any Help please. >> >> print ''; >> >>or >> >> echo ''; -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] $_post and array question

2004-05-17 Thread Daniel Clark
I've done a couple things. One is to use isset() and check first. The other is to add a hidden input field, that way something is always sent. > Best readers, > > //PHP version: 4.3.6 > > I have question concerning the following issue: > > I have a HTML input element of the type check. > >

Re: [PHP] How to make program execution go to another file?

2004-05-20 Thread Daniel Clark
This works providing there has NOT been any header (HTML) info outputed. if (1==a) header("Location: thisotherfile.php"); > Hi, >I want program execution to go to one of several other files > based on a decision. > For Example. > > if (1==a) >go to this .php file > > if (1==b)

Re: [PHP] Sessions still do not persist

2004-05-21 Thread Daniel Clark
Try a session_start() at the top of pages, see if that works. Maybe the auto_start does not work. > > I've posted several times mentioning that I am completely unable > to cause sessions to persist. Over the intervening time, I have > replicated this problem to a different machine, with the same

Re: [PHP] Newbie error with cookies and headers already declared

2004-05-21 Thread Daniel Clark
Try putting your below setting the cookie. > I'm getting this error: > > Warning: Cannot add header information - headers already sent by (output > started at /home/tiempodemaria/main.php:3) in /home/tiempodemaria/main.php > on line 11 > > With this code in "main.php": > > > define

Re: [PHP] Random Record Retrieval

2004-05-22 Thread Daniel Clark
How about rand() on your ID column. http://www.php.net/manual/en/function.rand.php >>How's that for alliteration in a subject line? >> >>Got a simple MySQL table that contains records which are made up of only >>three fields - ID, quote and author. These are "inspirational" quotes that >>I want

Re: [PHP] sessions

2004-05-23 Thread Daniel Clark
Should username have quote around it? Wouldn't it try to make it a constant otherwise? echo $_SESSION['username'] >>Hi, >> >>All my session_start() calls were working fine. >>But since yesterday the vars i use does not keep there value >>i use $_SESSION['varname'] >> >>Nothing has been changed

RE: [PHP] Re: find out ip address [beginner]

2004-05-24 Thread Daniel Clark
LOL :-) >>Jonesy >>on Monday, May 24, 2004 2:21 PM said: >> >>> WFM: >>>|$ ping ibm.com >>>|PING ibm.com (129.42.18.99) 56(84) bytes of data. >>>: >> >>wow. that's the weirdest looking php i've ever seen. is that a beta or >>something? >> >> >> >>chris.

Re: [PHP] Session variables not recognized?

2004-05-25 Thread Daniel Clark
Session handling was added in PHP 4.0. >>The first line of my file is session_start(); but whenever I try to set >>or reference $_SESSION['anything'] I get: >> >> Undefined variable: _SESSION >> >>What's up with that??? >> >>- Brian -- PHP General Mailing List (http://www.php.net/) To unsubsc

Re: [PHP] Re: test

2004-05-25 Thread Daniel Clark
I think it's someone else on the list getting the email lists, and spaming. >>Signed up litterally 1 minute ago and I'm already getting spam. From >>"Advance Credit Suisse Bank" >> >>Great. Thanks php.net. >> >>Guess you can't even trust the well known sites not to slam you with spam. -- PHP Ge

Re: [PHP] interesting

2004-05-25 Thread Daniel Clark
What does the { } around the array mean? >>From: "Bob Lockie" <[EMAIL PROTECTED]> >> >>> echo "\"" . $search_for_list[$i][0] . "\"" works but >>> echo "\"$search_for_list[$i][0]\"" prints "Array[0]. >> >>$search_for_list[$i] is an 'Array' which is followed by the string '[0]' ... >>how is PHP supp

Re: [PHP] interesting

2004-05-25 Thread Daniel Clark
Thank you John, and Michal :-) >>From: Daniel Clark >> >>>>echo "\"{$search_for_list[$i][0]}\""; will work, btw. >>> >>> What does the {}around the array mean? >> >>It delimits your variable so PHP knows what to inter

Re: [PHP] interesting

2004-05-25 Thread Daniel Clark
Good point Justin ! >>John W. Holmes wrote: >> >>> From: Daniel Clark >>> >>> >>>>>echo "\"{$search_for_list[$i][0]}\""; will work, btw. >>>> >>>>What does the {}around the array mean? >>>

Re: [PHP] interesting

2004-05-25 Thread Daniel Clark
Ok, print or echo :-) >>From: "Justin Patrin" <[EMAIL PROTECTED]> >> >>> IMHO it's just better to use concatenation and single quotes for your >>> string. PHP doesn't have to parse your strings for variables that way >>> and it makes it obvious what parts are variables. >> >>To each his own. Shall

Re: [PHP] dynamic table

2004-05-26 Thread Daniel Clark
Very slick Richard. >>$i = 0; >>while ($myrow = mysql_fetch_array($sql)) { >> if (++$i % 5 == 0) echo ''; >> ... >> >> >>Note: if used repeatedly do not increment the $i again in the loop. >> >>HTH >>Richard -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] How to check for a $_GET without throwing a Notice?

2004-05-26 Thread Daniel Clark
if (isset( $_GET['id'])) >>How do I check for the presence of an optional $_GET param without >>throwing a "Notice: Undefined index" when the param is not present? >> >>Tried all three of these, they all produce the Notice when the param is >>not passed: >> >>if ($_GET['id']) >>if ($_GET['id'] !

Re: [PHP] how to redirect with post method

2004-05-28 Thread Daniel Clark
I don't believe you can sent those post variables on the URL. Either as GET variables on the URL. Set Session variables and read on the next page. Or setup a with hidden post variables populated with the $post variables, and JavaScript to auot submit onload. > Hello, > I have a webpage that I'm

Re: [PHP] datetime formatting problem

2004-05-28 Thread Daniel Clark
Isn't "date" a reserved word? > hi all - > > this is probably straight forward, but i'm learning and would appreciate > any insight. > > i'm using the datetime type in mysql and have been able to successsfully > pull the data records's date, but it's failing out and giving me the > current time [a

Re: [PHP] ColdFusion / SQL > PHP / mySQL HELP!

2004-05-28 Thread Daniel Clark
I've used Cold Fusion for years. However one week at 100 hours might not be enough time to covert everything to PHP and mySQL. > Hi everyone, > > Ok, I need serious help. I have been handed a project by my boss to > convert > an existing site that was built using ColdFusion / SQL into a site tha

Re: [PHP] ColdFusion / SQL > PHP / mySQL HELP!

2004-05-28 Thread Daniel Clark
That's funny Travis ! >>Here's what you do. Assume 10-hour work days. Obviously, you want to start >>with the schema. That's pretty darn important, so allow yourself a whole day >>for that. >> >>You have four days left. Oh wait -- you will probably have to work the weekend >>for this one.

Re: [PHP] Preg_match question

2004-05-29 Thread Daniel Clark
Great quote Jeroen. >>Always code as if the guy who ends up maintaining your code will be a violent >>psychopath who knows where you live. >> -- Martin Golding -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] cookies malfunctioning moving from windows to linux

2004-05-29 Thread Daniel Clark
Apache must have read and write privs on the tmp directory. >>Hi, I developed a Poll system that uses cookies. It works fine under Windows >>(Apache and MySQL), but it does not work properly under Linux. - I >>transitioned my site from my windows based server to a linux machine. >> >>Cookies does

Re: [PHP] Text file wont' have newlines?

2004-05-29 Thread Daniel Clark
Needs a new line and return. fwrite($fp, ($credit . "\n\r") ); >>Hi everybody, >> >>I have this script in a file that allows users to upload files, and I want >>to know who submitted what so I write $userfile_name and $credit1(their >>name) to CREDIT.txt in the same directory like so : >> >>$cr

Re: [PHP] Query Query

2004-05-30 Thread Daniel Clark
Can you send more of the code? I looks good so far. >>This may be better suited to the MySQL lists, but I'd appreciate it if >>someone could help. I'm probably just missing something stupid here but >>have been coding non-stop for a week and need another set of eyes. >> >>Here's the line of co

Re: [PHP] hyperlink to the mysql data

2004-05-30 Thread Daniel Clark
Can you post some of the code? --Original Message Text--- From: CurlyBraces Technologies ( Pvt ) Ltd Date: Mon, 31 May 2004 01:49:17 +0600 hi , i have retrived some perticular data from mysql , and them show in the web browser.( It is very few data ) When clicking on one of that that perti

Re: [PHP] installing php4 in windows 2000

2004-05-31 Thread Daniel Clark
Is your php.ini in the windows or winnt directory? >>i have configured apache 2.0.49 in my system and included the following lines of >>code in my http:conf file >> >>LoadModule php4_module "c:/php/sapi/php4apache2.dll" >>AddType application/x-httpd-php .php >> >>i have also configured the php.i

Re: [PHP] multiple checkbox help

2004-05-31 Thread Daniel Clark
Change $_REQUEST to $_POST (a little more secure). foreach( $deleteID as $key => $value) { echo 'deleting ' . $value . '' ; } >>I tried this HTML: >> >> >> >>$_REQUEST['deleteID'] === the last box checked. >>so I did a google search and changed my HTML to: >> >> >> >> >>Now the code: >>for

Re: [PHP] duplicating a row

2004-05-31 Thread Daniel Clark
INSERT INTO new_table (column1, column2, ...) SELECT column1, column2, ... FROM original_table >>I want to duplicate a row (back it up - copy to a table with the same >>schema) regardless of the table schema. >>This in MySQL but I need a solution that can be made easily portable to >>other data

Re: [PHP] Re: Re: drop down menu populated from a directory

2004-05-31 Thread Daniel Clark
With the SELECT drop down, you'd need a submit button, and then the value of $file would be passed to the next page and read. There you could open that file. >>So I made my code: >> >>>if ($handle = opendir('../../../mov')) { >>while (false !== ($file = readdir($handle))) >> >>if ($

Re: [PHP] update mysql using radio button

2004-06-01 Thread Daniel Clark
I think you need Values for the radio buttons. club_member ='N'){echo 'CHECKED';}?>> > > hello all - > > i'm having a problem getting an UPDATE to work with radio buttons and > i'm not sure where it's gone wrong. the initial values are being grabbed > properly, but unfortunately they don't want

Re: [PHP] Strtotime() weirdness

2004-06-01 Thread Daniel Clark
http://us3.php.net/manual/en/function.strtotime.php Note: The valid range of a timestamp is typically from Fri, 13 Dec 1901 20:45:54 GMT to Tue, 19 Jan 2038 03:14:07 GMT. (These are the dates that correspond to the minimum and maximum values for a 32-bit signed integer.) Additionally, not all plat

Re: [PHP] update mysql using radio button

2004-06-01 Thread Daniel Clark
Right. (oops) > From: "Daniel Clark" <[EMAIL PROTECTED]> > >> if($row->club_member >> ='N'){echo 'CHECKED';}?>> > > =='N', you mean. :) > > ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Finding the sizeof a variable....

2004-06-02 Thread Daniel Clark
There is memory_get_usage() but it returns the amount of memory allocated to PHP. http://us3.php.net/manual/en/function.memory-get-usage.php > I'm wondering if there's something similar to the C sizeof operator in > PHP? I would like to find out how much space in memory a variable is > actually

Re: [PHP] php installation verification

2004-06-02 Thread Daniel Clark
Save to your root directory as test.php (or something ending in php). > I am new to php and was tasked with installing php v.4.3.6. I installed > it on redhat with apache v2.0.48. > I read in the doc that you can create a test file called test.php with > some php tags such as . > Could someone

RE: [PHP] php installation verification

2004-06-02 Thread Daniel Clark
Have you stopped and restarted the web server? > OK - I tried that and what came up on the browser was the content of the > test.php file. > > I checked in my httpd.conf file I do have the following: > > AddType application/x-httpd-php .php > AddType application/x-http-php-source .phps > > LoadMod

RE: [PHP] php installation verification

2004-06-02 Thread Daniel Clark
And you test.php file has? (note starting with > Yes. > > Have you stopped and restarted the web server? > >> OK - I tried that and what came up on the browser was the content of the >> test.php file. >> >> I checked in my httpd.conf file I do have the following: >> >> AddType application/x-http

RE: [PHP] php installation verification

2004-06-02 Thread Daniel Clark
Running Apache? Windows? > I get the source display on the browser as: > > phpinfo(); > ?> -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] php installation verification

2004-06-02 Thread Daniel Clark
Seems to me there was a problem with Apache 2 and PHP (some version). > The content of my test.php file has: > > phpinfo(); > ?> -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Best way to sort?

2004-06-03 Thread Daniel Clark
SELECT DISTINCT person_name, count(*) FROM table_name GROUP BY person_name ORDER BY 2 DESC > I'm not sure if this is a complex SQL query or a PHP array sorting > thing, but what's the best way to take this data: > >Tom >Greg >Brian >Tom >Brian >Tom > > And return the follow

Re: [PHP] Asuming query without the ?

2004-06-03 Thread Daniel Clark
I think it's in the Apache config file. > Where and how do I set this? I'm to Unix and PHP. > > "Marek Kilimajer" <[EMAIL PROTECTED]> escribió en el mensaje > news:[EMAIL PROTECTED] >> Robert Winter wrote: >> > Is it possible to configure PHP/.htAccess/etc. for assuming a query >> when > the >> >

RE: [PHP] Best way to sort?

2004-06-04 Thread Daniel Clark
Order by the 2nd column >>what is the 2? in the order by statement mean? >>thanks >> >>-Original Message- >>From: Raúl Castro [mailto:[EMAIL PROTECTED] >>Sent: Thursday, June 03, 2004 6:20 PM >>To: [EMAIL PROTECTED] >>Subject: Re: [PHP] Best way to sort? >> >> >>The best way is: >> >>SELEC

  1   2   >