[PHP-DB] Re: Passing multiple form variable in PHP
Cheers - query Answered "Stephen Rhodes" <[EMAIL PROTECTED]> wrote in message news:20021112162930.65021.qmail@;pb1.pair.com... > HELLO - this is probably a simple problem !! > > Wanting to use in a html form and pass multiple value > into a php variable but does > not work. I only get a single value. Can you tell me what I am doing wrong > ? > > Does the multiple value get passed correctly in php > > if ($task=="check") > { > printf("$icon"); > } > else > { > print ' > Multiple Check: > > False > True > >'; > } > > Thanks > Steve R > > -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Passing multiple form variable in PHP
HELLO - this is probably a simple problem !! Wanting to use in a html form and pass multiple value into a php variable but does not work. I only get a single value. Can you tell me what I am doing wrong ? Does the multiple value get passed correctly in php if ($task=="check") { printf("$icon"); } else { print ' Multiple Check: False True '; } Thanks Steve R -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Using a variable as a variable name
Hi I am wanting to use the value in a variable as a variable name. I know it is possible but do not remember how to do it - what function to call. Example $section1 = "SECTION 1"; $section2 = "SECTION 2"; // I want to have a for loop that will call these variables. eg for ($i=1;$i<3;$i++) //Now I want to call $section1, and $section2 by using $i which will first equal 1 and then 2. Cheers Steve -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Re: intercative selection menu
You could have if statements for every option. May be better if you have a for loop for some of the options -- SEE BELOW. e.g : %s",$i); } printf(" 1916"); printf(" volta"); printf(" scatt11"); ?> Cheers Steve "Walid Dib" <[EMAIL PROTECTED]> wrote in message 6EDD9DC298BF9C48AC3EF66EA92596BC0463AF25@frbucmsx03medge">news:6EDD9DC298BF9C48AC3EF66EA92596BC0463AF25@frbucmsx03medge... > Hello, I need to get back the present value in the data base and to > post(show) it in the menu of selection. somebody has an idea?? > > Thank you in advance. > : > >1904 >1905 >1906 >1907 >1908 >1909 >1910 >1911 >1916 >volta >scatt11 > > -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Re: how can i get field-informationof a table?
use the function mysql_list_fields in url http://www.php.net/manual/en/function.mysql-list-fields.php Cheers Steve "Hermann Otteneder" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > hi, > i'm using a mssql-database. now i want update a record with the information > given in a form. i want use the following sql statement: > $SQL = "update set '' = > 'HTTP_POST_VARS[$index]' WHERE PKID = 'HTTP_POST_VARS[0]'"; > mssql_query($SQL); > > my problem is i cannot find a function which gives me an array of the fields > of a table -> > > I guess this is for sure very simple - haves anyone the solution? i would be > very thankfuly for this! > > lg hermann > > -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Re: Working with dates
Forget my last email. Similar but before I told you how to do it from todays date. You need to parse the $effdate. Below would only work for 1 number months. (i.e not Oct,Nov,Dec) Find where / occurs in the string and you will be laughing. Once you have those numbers in $day,$month,$year you will be able to use the bottom two lines of below to add three months on. $effdate= "1/15/2002"; $day = substr($effdate,2,2); $month = substr($effdate,0,1); $year = substr($effdate,5,4); $threeMonthsAhead = mktime(0,0,0,$month+3,$day,$year); $dateInYourForm = date("m/d/Y",$threeMonthsAhead); Cheers Steve "Manuel" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > Can anybody help me with this? > > How do you take a known date and add three month to it? > > Example: > > $effdate= "1/15/2002" > > > > - > Do You Yahoo!? > LAUNCH - Your Yahoo! Music Experience -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Re: output problem
When you write the SQL statement write it as: select count(user) AS count from log_request where date='$date' and status = 'open' (note i have added 'AS count' in there so it stores the value in 'count') Now when you output the result write it as $line->count Cheers Steve "Chris Grigor" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Howdi Alll some of you might laugh at this but I cant get this to work Im doing a count on a field and want to diplay the result here is an example... "); print (" $line->user\n"); print (""); } ?> what am I missing as it returns no value at all from $line->user, should I be doing this differently?? Thankyou Chris -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Re: Working with dates
Use this: ($dateInYourForm gives the date in three months time in the form you gave below. $threeMonths = mktime(0,0,0,date("m")+3,date("d"),date("Y")); $dateInYourForm = date("d/m/Y",$threeMonths); Cheers Steve "Manuel" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > Can anybody help me with this? > > How do you take a known date and add three month to it? > > Example: > > $effdate= "1/15/2002" > > > > - > Do You Yahoo!? > LAUNCH - Your Yahoo! Music Experience -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Using the ALTER statement
When i use the alter statement in the PHP function mysql_db_query( ) I get a permission error. I can CREATE tables, DROP them etc so there are no permission problems as far as I know. Can anyone help ? Steve -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php