[PHP] Newbie Help - No .php file extension

2009-02-09 Thread Hibbert Miller
Hello,I have been asked to install an existing PHP/MySQL application on a
system using Windows Vista.

I have installed PHP 5.2.8, MySQL 5.1.31 and IIS 7.0. PHP is working as
expected (I created a test page which displays the output from phpinfo()).

The application in question posts to a login page from an index page called
index.php. However, the form's action is simply set to login, and not
login.php as expected. Further checking revealed that all links in the
application appear to exclude the file extensions.

I have combed through the php.ini file and have not been able to find any
configuration setting that deal with this. I have also tried configuring IIS
to send all requests to PHP by setting the Handler Mapping to * instead of
just *.php.

Thank you in advance for any information you may be able to provide.

HM


Re: [PHP] Newbie Help - No .php file extension

2009-02-09 Thread Thijs Lensselink
Hibbert Miller wrote:
 Hello,I have been asked to install an existing PHP/MySQL application on a
 system using Windows Vista.
   
What application are we talking about here?
Is it a known Open/Closed source application? Is it supposed to run on
windows?
 I have installed PHP 5.2.8, MySQL 5.1.31 and IIS 7.0. PHP is working as
 expected (I created a test page which displays the output from phpinfo()).

 The application in question posts to a login page from an index page called
 index.php. However, the form's action is simply set to login, and not
 login.php as expected. Further checking revealed that all links in the
 application appear to exclude the file extensions.
   
Sounds like this applications is making use of some sort of controller
to handle requests.
A lot of frameworks and applications make use of the MVC* pattern. That
could be a reason
why there's no .php extension. The call to login will probably result
into something like
http://host.tld/login, Which will be rewritten by the help of either
htaccess or php itself.
 I have combed through the php.ini file and have not been able to find any
 configuration setting that deal with this. I have also tried configuring IIS
 to send all requests to PHP by setting the Handler Mapping to * instead of
 just *.php.
   
Did there come a .htaccess file with the application? I'm not sure how
IIS handles these things.
Last time i touched IIS. It was still in 5.x version range...
 Thank you in advance for any information you may be able to provide.

 HM

   


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



Re: [PHP] Newbie - help with a foreach

2007-01-22 Thread Németh Zoltán
On v, 2007-01-21 at 01:28 -0800, pub wrote:
 On Jan 18, 2007, at 2:43 AM, Németh Zoltán wrote:
 
  first, do you want to allow several jobs for the same company to be
  
  stored in the DB and appear on the page, right? (if not, then why
  are
  
  you storing them in separate tables?)
  
  
 Yes, I have the name of the company with address etc in the client
 table
 and all the jobs in the job table, so that I can display several
 jobs per client 
  second, you should do it with one query I think
  
  
  something like SELECT t1.*, t2.* FROM client t1, job t2 WHERE
  
  t1.companyId=t2.companyId ORDER BY t1.companyId
  
  
  and then you can do all stuff in one loop
  
  
   while ($aaa = mysql_fetch_array($result))
  
  
  and you don't need that foreach stuff at all (which also seems to be
  
  screwed up...)
  
 
 I am working on my query as you suggested. I have a joint query that
 seems to work except that I get the name of the company twice. Could
 you please help me figure out how to make it echo the company once and
 list all the jobs next to it on the same line and start a new line
 with the next company?
 
 

ehh, I thought you want the jobs on separate lines, sorry.

this can be achieved for example like this:

$prev_cname = ;
while ($aaa = mysql_fetch_array($result,MYSQL_ASSOC))
 {  
  if ($aaa['companyName'] != $prev_cname) {
   echo span class='navCompany'{$aaa['companyName']}/span;
  }
  echo span class='navArrow'   /spanspan class='navText'a
href='single_page_t10.php?art=.$aaa['pix'].'{$aaa['jobType']}/a/span;
  if ($aaa['companyName'] != $prev_cname) {
   echo br/\n;
   $prev_cname = $aaa['companyName'];
  }
} 

hope that helps
Zoltán Németh


   Here is the code I have now:
 
 
 $query = SELECT client.companyName, job.jobType, job.pix, job.info,
 job.url
  FROM client, job
  WHERE client.companyId=job.companyId
  AND client.view='yes'
  order by client.companyName;
 
 
 
 $result = mysql_query($query)  
 or die (Couldn't execute query);
 
while  ($aaa = mysql_fetch_array($result,MYSQL_ASSOC))
{  
echo span class='navCompany'{$aaa['companyName']}/spanspan
 class='navArrow'   /spanspan class='navText'a
 href='single_page_t10.php?art=.$aaa['pix'].'{$aaa['jobType']}/a/spanbr\n;
 } 
 

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



Re: [PHP] Newbie - help with a foreach

2007-01-19 Thread Németh Zoltán
On cs, 2007-01-18 at 20:46 +0100, Jochem Maas wrote:
 Németh Zoltán wrote:
  On cs, 2007-01-18 at 02:04 -0800, pub wrote:
  On Jan 18, 2007, at 2:00 AM, Németh Zoltán wrote:
 
 
 
 ...
 
  maybe you should use a parameter for it, place it into the link in the
  first query loop, get it here and query based on it
  
  like SELECT * FROM job WHERE id={$_GET['job_id']} or whatever
 
 SQL INJECTION WAITING TO HAPPEN.

true, sorry
so check the value first

greets
Zoltán Németh

 
 
 ...
 
 foreach($row as $url)
 {
 $row = mysql_fetch_array($result2,MYSQL_ASSOC);
 if (url={$row['url']})
 
 what is this IF statement supposed to be doing???
 because it will always evaluate to true

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



[PHP] Newbie - help with a foreach

2007-01-18 Thread pub
Could someone please help me figure out how to hide the info in the  
right bottom part of my page unless the corresponding link is  
selected in the top left.


The company names and job types at the top left need to show at all  
time. But the corresponding picture at the bottom left and the web  
address/info at the bottom right should appear only when selected.


I have the same query repeating twice once for the top left part and  
once for the bottom right part because I can't figure out how else to  
do it!


Thank you.

http://www.squareinch.net/single_page_t2.php?art=btw_logo.jpg

Re: [PHP] Newbie - help with a foreach

2007-01-18 Thread Németh Zoltán
I can't really understand what your problem is, because it seems to me
that the site is working like you want it to work. Or not?

And if there is a problem with the code then please show us the code
somehow, not the resulting webpage

greets
Zoltán Németh

On cs, 2007-01-18 at 01:31 -0800, pub wrote:
 Could someone please help me figure out how to hide the info in the  
 right bottom part of my page unless the corresponding link is  
 selected in the top left.
 
 The company names and job types at the top left need to show at all  
 time. But the corresponding picture at the bottom left and the web  
 address/info at the bottom right should appear only when selected.
 
 I have the same query repeating twice once for the top left part and  
 once for the bottom right part because I can't figure out how else to  
 do it!
 
 Thank you.
 
 http://www.squareinch.net/single_page_t2.php?art=btw_logo.jpg

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



Re: [PHP] Newbie - help with a foreach

2007-01-18 Thread pub

Thank you for your reply.

My problem is that the web addresses on the bottom right show at all  
times as is instead of appearing only when active or selected on the  
left top navigation!


Does that make sense?

On Jan 18, 2007, at 1:43 AM, Németh Zoltán wrote:


I can't really understand what your problem is, because it seems to me
that the site is working like you want it to work. Or not?

And if there is a problem with the code then please show us the code
somehow, not the resulting webpage

greets
Zoltán Németh

On cs, 2007-01-18 at 01:31 -0800, pub wrote:

Could someone please help me figure out how to hide the info in the
right bottom part of my page unless the corresponding link is
selected in the top left.

The company names and job types at the top left need to show at all
time. But the corresponding picture at the bottom left and the web
address/info at the bottom right should appear only when selected.

I have the same query repeating twice once for the top left part and
once for the bottom right part because I can't figure out how else to
do it!

Thank you.

http://www.squareinch.net/single_page_t2.php?art=btw_logo.jpg


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



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



Re: [PHP] Newbie - help with a foreach

2007-01-18 Thread Németh Zoltán
ok, but how could anyone help without seeing your code?

greets
Zoltán Németh

On cs, 2007-01-18 at 01:54 -0800, pub wrote:
 Thank you for your reply.
 
 My problem is that the web addresses on the bottom right show at all  
 times as is instead of appearing only when active or selected on the  
 left top navigation!
 
 Does that make sense?
 
 On Jan 18, 2007, at 1:43 AM, Németh Zoltán wrote:
 
  I can't really understand what your problem is, because it seems to me
  that the site is working like you want it to work. Or not?
 
  And if there is a problem with the code then please show us the code
  somehow, not the resulting webpage
 
  greets
  Zoltán Németh
 
  On cs, 2007-01-18 at 01:31 -0800, pub wrote:
  Could someone please help me figure out how to hide the info in the
  right bottom part of my page unless the corresponding link is
  selected in the top left.
 
  The company names and job types at the top left need to show at all
  time. But the corresponding picture at the bottom left and the web
  address/info at the bottom right should appear only when selected.
 
  I have the same query repeating twice once for the top left part and
  once for the bottom right part because I can't figure out how else to
  do it!
 
  Thank you.
 
  http://www.squareinch.net/single_page_t2.php?art=btw_logo.jpg
 
  -- 
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit: http://www.php.net/unsub.php
 
 

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



Re: [PHP] Newbie - help with a foreach

2007-01-18 Thread pub


On Jan 18, 2007, at 2:00 AM, Németh Zoltán wrote:


ok, but how could anyone help without seeing your code?

greets
Zoltán Németh


Here is the code:

Here is the entire page:

!-- nav/box 1 starts here --



?php
  include(../include/etc_inc.php);

  $connection = mysql_connect($host,$user,$password)
or die (couldn't connect to server);

// connect to database  
  $db = mysql_select_db($database,$connection)
or die (Couldn't select database);

// query a from client  
  $query = SELECT * FROM client
where status='active' or status='old'
order by companyName;

$result = mysql_query($query)
or die (Couldn't execute query);

  while ($aaa = mysql_fetch_array($result,MYSQL_ASSOC))
  { 
  echo span class='navCompany'{$aaa['companyName']}/spanspan  
class='navArrow'   /span\n;


// query b from job
$query = SELECT * FROM job
WHERE companyId='{$aaa['companyId']}';
$result2 = mysql_query($query)
or die (Couldn't execute query b);

foreach($aaa as $jobType)
{
$bbb = mysql_fetch_array($result2,MYSQL_ASSOC);
			echo span class='navText'a href='single_page_t2.php?art=.$bbb 
['pix'].'{$bbb['jobType']}/a/span\n;


}   

echo br;
}   
?



!-- nav/box 1 ends here --



/div
div class=navbox2img src=images/sq_logo_137.gif alt=Square  
Inch logo width=137 height=137/div


div class=navbox3?php $image = $_GET['art']; ?
			img src=images/?php print ($image) ?  alt=Portfolio Item  
border=0 width=285 height=285/div




div class=navbox4




!-- info/box 4 starts here --
?php
/* query 1 from client */
$query = SELECT * FROM client
where status='active' or status='old'
order by companyName;

$result = mysql_query($query)
or die (Couldn't execute query);

while   ($row = mysql_fetch_array($result,MYSQL_ASSOC))
{   

/* query 2 from job */
$query = SELECT * FROM job
WHERE companyId='{$row['companyId']}';
$result2 = mysql_query($query)
or die (Couldn't execute query2);
$url = mysql_query($result2);

foreach($row as $url)
{
$row = mysql_fetch_array($result2,MYSQL_ASSOC);
if (url={$row['url']})  
		echo span class='navText'a href='{$row['url']}'{$row['web']}/ 
a/span;			

}

echo br;
}
?


!-- info/box 4 ends here --






On cs, 2007-01-18 at 01:54 -0800, pub wrote:

Thank you for your reply.

My problem is that the web addresses on the bottom right show at all
times as is instead of appearing only when active or selected on the
left top navigation!

Does that make sense?

On Jan 18, 2007, at 1:43 AM, Németh Zoltán wrote:

I can't really understand what your problem is, because it seems  
to me

that the site is working like you want it to work. Or not?

And if there is a problem with the code then please show us the code
somehow, not the resulting webpage

greets
Zoltán Németh

On cs, 2007-01-18 at 01:31 -0800, pub wrote:

Could someone please help me figure out how to hide the info in the
right bottom part of my page unless the corresponding link is
selected in the top left.

The company names and job types at the top left need to show at all
time. But the corresponding picture at the bottom left and the web
address/info at the bottom right should appear only when selected.

I have the same query repeating twice once for the top left part  
and
once for the bottom right part because I can't figure out how  
else to

do it!

Thank you.

http://www.squareinch.net/single_page_t2.php?art=btw_logo.jpg


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







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



Re: [PHP] Newbie - help with a foreach

2007-01-18 Thread Németh Zoltán
On cs, 2007-01-18 at 02:04 -0800, pub wrote:
 On Jan 18, 2007, at 2:00 AM, Németh Zoltán wrote:
 
  ok, but how could anyone help without seeing your code?
 
  greets
  Zoltán Németh
 
 Here is the code:
 
 Here is the entire page:
 
 !-- nav/box 1 starts here --
 
 
 
 ?php
include(../include/etc_inc.php);
 
$connection = mysql_connect($host,$user,$password)
   or die (couldn't connect to server);
   
 // connect to database
$db = mysql_select_db($database,$connection)
   or die (Couldn't select database);
 
 // query a from client
$query = SELECT * FROM client
   where status='active' or status='old'
   order by companyName;
   
   $result = mysql_query($query)
   or die (Couldn't execute query);
   
while  ($aaa = mysql_fetch_array($result,MYSQL_ASSOC))
{  
echo span class='navCompany'{$aaa['companyName']}/spanspan  
 class='navArrow'   /span\n;
 
 // query b from job
   $query = SELECT * FROM job
   WHERE companyId='{$aaa['companyId']}';
   $result2 = mysql_query($query)
   or die (Couldn't execute query b);
 
   foreach($aaa as $jobType)
   {
   $bbb = mysql_fetch_array($result2,MYSQL_ASSOC);
   echo span class='navText'a 
 href='single_page_t2.php?art=.$bbb 
 ['pix'].'{$bbb['jobType']}/a/span\n;
 
   }   

first, do you want to allow several jobs for the same company to be
stored in the DB and appear on the page, right? (if not, then why are
you storing them in separate tables?)

second, you should do it with one query I think

something like SELECT t1.*, t2.* FROM client t1, job t2 WHERE
t1.companyId=t2.companyId ORDER BY t1.companyId

and then you can do all stuff in one loop

 while ($aaa = mysql_fetch_array($result))

and you don't need that foreach stuff at all (which also seems to be
screwed up...)


   
 
   echo br;
   }   
   ?
   
 
 
 !-- nav/box 1 ends here --
 
 
 
 /div
 div class=navbox2img src=images/sq_logo_137.gif alt=Square  
 Inch logo width=137 height=137/div
 
 div class=navbox3?php $image = $_GET['art']; ?
   img src=images/?php print ($image) ?  
 alt=Portfolio Item  
 border=0 width=285 height=285/div
 
 
 
 div class=navbox4
 
 
 
 
 !-- info/box 4 starts here --
 ?php
 /* query 1 from client */

and here you should not run the whole query again

you should specifically query the one which should appear

maybe you should use a parameter for it, place it into the link in the
first query loop, get it here and query based on it

like SELECT * FROM job WHERE id={$_GET['job_id']} or whatever

and just echo the data from that record

hope that helps
Zoltán Németh

 

 $query = SELECT * FROM client
   where status='active' or status='old'
   order by companyName;
   
   $result = mysql_query($query)
   or die (Couldn't execute query);
 
 while ($row = mysql_fetch_array($result,MYSQL_ASSOC))
 { 
   
 /* query 2 from job */
 $query = SELECT * FROM job
   WHERE companyId='{$row['companyId']}';
   $result2 = mysql_query($query)
   or die (Couldn't execute query2);
   $url = mysql_query($result2);
   
   foreach($row as $url)
   {
   $row = mysql_fetch_array($result2,MYSQL_ASSOC);
   if (url={$row['url']})
   
   echo span class='navText'a 
 href='{$row['url']}'{$row['web']}/ 
 a/span;   
   }
 
   echo br;
   }
   ?
 
 
 !-- info/box 4 ends here --
 
 
 
 
 
  On cs, 2007-01-18 at 01:54 -0800, pub wrote:
  Thank you for your reply.
 
  My problem is that the web addresses on the bottom right show at all
  times as is instead of appearing only when active or selected on the
  left top navigation!
 
  Does that make sense?
 
  On Jan 18, 2007, at 1:43 AM, Németh Zoltán wrote:
 
  I can't really understand what your problem is, because it seems  
  to me
  that the site is working like you want it to work. Or not?
 
  And if there is a problem with the code then please show us the code
  somehow, not the resulting webpage
 
  greets
  Zoltán Németh
 
  On cs, 2007-01-18 at 01:31 -0800, pub wrote:
  Could someone please help me figure out how to hide the info in the
  right bottom part of my page unless the corresponding link is
  selected in the top left.
 
  The company names and job types at the top left need to show at all
  time. But the corresponding picture at the bottom left and the web
  

Re: [PHP] Newbie - help with a foreach

2007-01-18 Thread Jochem Maas
Németh Zoltán wrote:
 On cs, 2007-01-18 at 02:04 -0800, pub wrote:
 On Jan 18, 2007, at 2:00 AM, Németh Zoltán wrote:



...

 maybe you should use a parameter for it, place it into the link in the
 first query loop, get it here and query based on it
 
 like SELECT * FROM job WHERE id={$_GET['job_id']} or whatever

SQL INJECTION WAITING TO HAPPEN.


...

  foreach($row as $url)
  {
  $row = mysql_fetch_array($result2,MYSQL_ASSOC);
  if (url={$row['url']})

what is this IF statement supposed to be doing???
because it will always evaluate to true

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



Re: [PHP] Newbie Help

2005-05-04 Thread Richard Lynch
On Sun, May 1, 2005 7:43 pm, Thomas Bonham said:
 ?php
   if(isset($_GET ['page']))
   {include($_GET ['page']..php);}

So, what happens when I decide to use:
http://bonhamlinux.org?page=secret

If you have a file named secret.php, I just loaded it.

More importantly, I loaded it, but you've never really PLANNED on my
loading it, at least not as a link target

So all kinds of PHP code is being executed all out of context, and out of
order, from what you expected.

This is a good way for somebody to poke and peek and trash your site --
Just by executing your code in unexpected order/pre-conditions.

You probably have a limited number of pages you are serving up this way.

Do something like this:

$valid_pages = array_flip(array('main', 'links', 'contact'));
$page = isset($_GET['page']) ? $_GET['page'] : 'home';
if (isset($valid_pages[$page])){
  require $page.php;
}
else{
  //maybe log hack attempt here
  require home.php;
}

Now people can *ONLY* load the pages you expect them to load, not just any
old chunk of PHP you happen to have laying around on your server, whether
you expected them to load it or not.

-- 
Like Music?
http://l-i-e.com/artists.htm

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



Re: [PHP] Newbie Help

2005-05-02 Thread Richard Collyer
Hello,
?php
  if(isset($_GET['page']))
  {include($_GET['page'] . .php);}
else
  {echo(Page Not Set.);}
?
Should work if you use ?page=index
Might I suggest that what you are doing is a bad idea. Not only will it 
look bad becuase of people seeing stuff like ?page=/review/review23.php 
in the URL. Also its a security risk allowing people to call php scripts 
from the URL.

Cheers
Richard
Thomas Bonham wrote:
Hello All,
First of I'm new to this a hop I'm doing this right.
If some one can help me with my web site page. I'm trying to make it
call a page and I get a error line 42. Error:
http://bonhamlinux.org/idex.php?page=links/index.php
The code that I'm trying to do this is the following:
?php
 if(isset($_GET ['page']))
 {include($_GET ['page']..php);}
 else
 {echo(Page Not Set.);}
?
My site is: http://bonhamlinux.org
My email is: [EMAIL PROTECTED]
Thanks for all the help.
Thomas
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Newbie Help

2005-05-02 Thread Thomas Bonham
Hello,
Thank for the information.

If that is not a good idea then how would you do it.

Thomas
--- Richard Collyer [EMAIL PROTECTED] wrote:
 Hello,
 
 ?php
if(isset($_GET['page']))
{include($_GET['page'] .
 .php);}
   else
{echo(Page Not Set.);}
 ?
 
 Should work if you use ?page=index
 
 Might I suggest that what you are doing is a bad
 idea. Not only will it 
 look bad becuase of people seeing stuff like
 ?page=/review/review23.php 
 in the URL. Also its a security risk allowing people
 to call php scripts 
 from the URL.
 
 Cheers
 Richard
 
 Thomas Bonham wrote:
  Hello All,
  
  First of I'm new to this a hop I'm doing this
 right.
  
  If some one can help me with my web site page. I'm
 trying to make it
  call a page and I get a error line 42. Error:
 
 http://bonhamlinux.org/idex.php?page=links/index.php
  
  The code that I'm trying to do this is the
 following:
  ?php
   if(isset($_GET ['page']))
   {include($_GET ['page']..php);}
   else
   {echo(Page Not Set.);}
  ?
  
  My site is: http://bonhamlinux.org
  My email is: [EMAIL PROTECTED]
  
  Thanks for all the help.
  Thomas
  
 
 

Thomas Bonham
Linux Rocks
http://www.bonhamlinux.org
Cell 602 402 9786
E-mail [EMAIL PROTECTED]
YIM freeswimfreak

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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



Re: [PHP] Newbie Help

2005-05-02 Thread Thomas Bonham
Thanks for the help.

It works, for the most part.

Now I'm going to write the links page.

Thanks agin for all the great help.

Thomas
--- Mark Cain [EMAIL PROTECTED] wrote:
 Also, after I looked at more of your code you will
 need to specify the php
 extension in only one of two places.  Currently you
 are specifying it in 1)
 the code below and in 2) nav.php and in nav.php you
 don't have it specified
 for the main but you do for the other links.  That
 means that the code
 supplies the .php extension for main (which it needs
 to because it is simply
 main and not main.php) but the other pages are
 specified as name.ext
 with the .php.  Then when that page name gets to the
 script, the script is
 adding .php onto the variable -- resulting in
 main.php, links/index.php.php,
 email/email.php.php and so forth.
 
 Do it one place or the other -- but do it
 consistently.
 
 Looks like you're close to getting it to work and
 I'm close to going to bed.
 
 Mark Cain
 
 
 
  The code that I'm trying to do this is the
 following:
  ?php
if(isset($_GET ['page']))
{include($_GET ['page']..php);}
else
{echo(Page Not Set.);}
  ?
  
  My site is: http://bonhamlinux.org
  My email is: [EMAIL PROTECTED]
  
  Thanks for all the help.
  Thomas
  
  --
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit:
 http://www.php.net/unsub.php
  
  
 
  --
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit:
 http://www.php.net/unsub.php
 
 
 
 

Thomas Bonham
Linux Rocks
http://www.bonhamlinux.org
Cell 602 402 9786
E-mail [EMAIL PROTECTED]
YIM freeswimfreak

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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



[PHP] Newbie Help

2005-05-01 Thread Thomas Bonham
Hello All,
First of I'm new to this a hop I'm doing this right.
If some one can help me with my web site page. I'm trying to make it 
call a page and I get a error line 42. Error: 
http://bonhamlinux.org/idex.php?page=links/index.php

The code that I'm trying to do this is the following:
?php
 if(isset($_GET ['page']))
{include($_GET ['page']..php);}
 else
{echo(Page Not Set.);}
?
My site is: http://bonhamlinux.org
My email is: [EMAIL PROTECTED]
Thanks for all the help.
Thomas
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Newbie Help

2005-05-01 Thread Thomas Bonham
Hello All,
First of I'm new to this a hop I'm doing this right.
If some one can help me with my web site page. I'm trying to make it
call a page and I get a error line 42. Error:
http://bonhamlinux.org/idex.php?page=links/index.php
The code that I'm trying to do this is the following:
?php
 if(isset($_GET ['page']))
 {include($_GET ['page']..php);}
 else
 {echo(Page Not Set.);}
?
My site is: http://bonhamlinux.org
My email is: [EMAIL PROTECTED]
Thanks for all the help.
Thomas
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Newbie Help

2005-05-01 Thread Andre Dubuc
On Sunday 01 May 2005 10:39 pm, Thomas Bonham wrote:
 Hello All,

 First of I'm new to this a hop I'm doing this right.

 If some one can help me with my web site page. I'm trying to make it
 call a page and I get a error line 42. Error:
 http://bonhamlinux.org/idex.php?page=links/index.php

 The code that I'm trying to do this is the following:
 ?php
   if(isset($_GET ['page']))
   {include($_GET ['page']..php);}
   else
   {echo(Page Not Set.);}
 ?

 My site is: http://bonhamlinux.org
 My email is: [EMAIL PROTECTED]

 Thanks for all the help.
 Thomas


I spot perhaps a typo in http://bonhamlinux.org/idex.php?page=links/index.php

Might that be 'index' instead?

Hth,
Andre
   ^^   

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



Re: [PHP] Newbie Help

2005-05-01 Thread Thomas Bonham
Andre Dubuc wrote:
On Sunday 01 May 2005 10:39 pm, Thomas Bonham wrote:
Hello All,
First of I'm new to this a hop I'm doing this right.
If some one can help me with my web site page. I'm trying to make it
call a page and I get a error line 42. Error:
http://bonhamlinux.org/idex.php?page=links/index.php
The code that I'm trying to do this is the following:
?php
 if(isset($_GET ['page']))
{include($_GET ['page']..php);}
 else
{echo(Page Not Set.);}
?
My site is: http://bonhamlinux.org
My email is: [EMAIL PROTECTED]
Thanks for all the help.
Thomas

I spot perhaps a typo in 
http://bonhamlinux.org/idex.php?page=links/index.php
Might that be 'index' instead?
Hth,
Andre
   ^^   
Thanks for replying so fast.
That is not a typo because the index.php pages is the following:
?php
header(Location: idex.php?page=main);
?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Newbie Help

2005-05-01 Thread Mark Cain
Perhaps the path to the included files is incomplete:

according to your error message you are trying to open
links/index.php.php

Does it need both of the dot php's ??

Would it help to include the full path to the includes such as:
/home/bonhamli/public_html/links/index.php.php

so something like that.

Mark Cain


- Original Message - 
From: Thomas Bonham [EMAIL PROTECTED]
To: php-general@lists.php.net
Sent: Sunday, May 01, 2005 10:39 PM
Subject: [PHP] Newbie Help 


 Hello All,
 
 First of I'm new to this a hop I'm doing this right.
 
 If some one can help me with my web site page. I'm trying to make it 
 call a page and I get a error line 42. Error: 
 http://bonhamlinux.org/idex.php?page=links/index.php
 
 The code that I'm trying to do this is the following:
 ?php
   if(isset($_GET ['page']))
   {include($_GET ['page']..php);}
   else
   {echo(Page Not Set.);}
 ?
 
 My site is: http://bonhamlinux.org
 My email is: [EMAIL PROTECTED]
 
 Thanks for all the help.
 Thomas
 
 -- 
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 
 

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



Re: [PHP] Newbie Help

2005-05-01 Thread Thomas Bonham
I Think the .php.php is the problem but I don't know have to fix it.
Let me know if you won't to see the full src page.
Thomas
Mark Cain wrote:
Perhaps the path to the included files is incomplete:
according to your error message you are trying to open
links/index.php.php
Does it need both of the dot php's ??
Would it help to include the full path to the includes such as:
/home/bonhamli/public_html/links/index.php.php
so something like that.
Mark Cain
- Original Message - 
From: Thomas Bonham [EMAIL PROTECTED]
To: php-general@lists.php.net
Sent: Sunday, May 01, 2005 10:39 PM
Subject: [PHP] Newbie Help 


Hello All,
First of I'm new to this a hop I'm doing this right.
If some one can help me with my web site page. I'm trying to make it 
call a page and I get a error line 42. Error: 
http://bonhamlinux.org/idex.php?page=links/index.php

The code that I'm trying to do this is the following:
?php
 if(isset($_GET ['page']))
 {include($_GET ['page']..php);}
 else
 {echo(Page Not Set.);}
?
My site is: http://bonhamlinux.org
My email is: [EMAIL PROTECTED]
Thanks for all the help.
Thomas
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

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


Re: [PHP] Newbie Help

2005-05-01 Thread Thomas Bonham
Here is all of the page, except one or two and the
images.

Thomas
--- Mark Cain [EMAIL PROTECTED] wrote:
 YES let see the src
 
 - Original Message - 
 From: Thomas Bonham [EMAIL PROTECTED]
 To: php-general@lists.php.net
 Sent: Sunday, May 01, 2005 11:31 PM
 Subject: Re: [PHP] Newbie Help 
 
 
  I Think the .php.php is the problem but I don't
 know have to fix it.
  
  Let me know if you won't to see the full src page.
  
  Thomas
  
  Mark Cain wrote:
   Perhaps the path to the included files is
 incomplete:
   
   according to your error message you are trying
 to open
   links/index.php.php
   
   Does it need both of the dot php's ??
   
   Would it help to include the full path to the
 includes such as:
   /home/bonhamli/public_html/links/index.php.php
   
   so something like that.
   
   Mark Cain
   
   
   - Original Message - 
   From: Thomas Bonham [EMAIL PROTECTED]
   To: php-general@lists.php.net
   Sent: Sunday, May 01, 2005 10:39 PM
   Subject: [PHP] Newbie Help 
   
   
   
  Hello All,
  
  First of I'm new to this a hop I'm doing this
 right.
  
  If some one can help me with my web site page.
 I'm trying to make it 
  call a page and I get a error line 42. Error: 
 

http://bonhamlinux.org/idex.php?page=links/index.php
  
  The code that I'm trying to do this is the
 following:
  ?php
if(isset($_GET ['page']))
{include($_GET ['page']..php);}
else
{echo(Page Not Set.);}
  ?
  
  My site is: http://bonhamlinux.org
  My email is: [EMAIL PROTECTED]
  
  Thanks for all the help.
  Thomas
  
  -- 
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit:
 http://www.php.net/unsub.php
  
  
  
  -- 
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit:
 http://www.php.net/unsub.php
  
  
 

Thomas Bonham
Linux Rocks
http://www.bonhamlinux.org
Cell 602 402 9786
E-mail [EMAIL PROTECTED]
YIM freeswimfreak

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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



Re: [PHP] Newbie Help

2005-05-01 Thread Mark Cain
first remove the space between GET and [
I think this keeps your script from find the variable page

secondly the variable page already has the php extension being passed to
it via the GET statement
make the include like:

{include($_GET['page']);}

try it and let us know.

Mark Cain

 The code that I'm trying to do this is the following:
 ?php
   if(isset($_GET ['page']))
   {include($_GET ['page']..php);}
   else
   {echo(Page Not Set.);}
 ?
 

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



Re: [PHP] Newbie Help

2005-05-01 Thread Mark Cain
Also, after I looked at more of your code you will need to specify the php
extension in only one of two places.  Currently you are specifying it in 1)
the code below and in 2) nav.php and in nav.php you don't have it specified
for the main but you do for the other links.  That means that the code
supplies the .php extension for main (which it needs to because it is simply
main and not main.php) but the other pages are specified as name.ext
with the .php.  Then when that page name gets to the script, the script is
adding .php onto the variable -- resulting in main.php, links/index.php.php,
email/email.php.php and so forth.

Do it one place or the other -- but do it consistently.

Looks like you're close to getting it to work and I'm close to going to bed.

Mark Cain



 The code that I'm trying to do this is the following:
 ?php
   if(isset($_GET ['page']))
   {include($_GET ['page']..php);}
   else
   {echo(Page Not Set.);}
 ?
 
 My site is: http://bonhamlinux.org
 My email is: [EMAIL PROTECTED]
 
 Thanks for all the help.
 Thomas
 
 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 
 

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



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



[PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread David McGlone
Hi all, I have a real quick question. I'm trying to learn PHP and right now im 
working with variables, anyway, I cannot get the code below to work 
correctly, could anyone help me out here the problem is, when you submit the 
name, the name will not appear at all.

 code below

HTML
FORM METHOD=post
Name:br
INPUT NAME=UserName TYPE=textbr
INPUT TYPE=SUBMIT VALUE=Enter
/FORM
br
Your name is:
?php

echo ($UserName);
?

/html
-- 
David M.
Edification Web Solutions
http://www.edificationweb.com

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



Re: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread Petre Agenbag
Your problem is not with PHP but with basic HTML.
Your FORM tag needs an action=www.somepage.com in order to do
something. With PHP, you can call the same page back onto itself.
 
On Fri, 2003-04-04 at 14:37, David McGlone wrote:
 Hi all, I have a real quick question. I'm trying to learn PHP and right now im 
 working with variables, anyway, I cannot get the code below to work 
 correctly, could anyone help me out here the problem is, when you submit the 
 name, the name will not appear at all.
 
  code below
 
 HTML
 FORM METHOD=post
 Name:br
 INPUT NAME=UserName TYPE=textbr
 INPUT TYPE=SUBMIT VALUE=Enter
 /FORM
 br
 Your name is:
 ?php
 
 echo ($UserName);
 ?
 
 /html
 -- 
 David M.
 Edification Web Solutions
 http://www.edificationweb.com
 
 -- 
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 


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



RE: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread John W. Holmes
 Hi all, I have a real quick question. I'm trying to learn PHP and
right
 now im
 working with variables, anyway, I cannot get the code below to work
 correctly, could anyone help me out here the problem is, when you
submit
 the
 name, the name will not appear at all.
 
  code below
 
 HTML
 FORM METHOD=post
 Name:br
 INPUT NAME=UserName TYPE=textbr
 INPUT TYPE=SUBMIT VALUE=Enter
 /FORM
 br
 Your name is:
 ?php
 
 echo ($UserName);
 ?

Use $_POST['UserName'] instead of just $UserName and do a search on
register_globals to find out why.

---John W. Holmes...

PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/



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



Re: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread Burhan Khalid
Petre Agenbag wrote:
Your problem is not with PHP but with basic HTML.
Your FORM tag needs an action=www.somepage.com in order to do
something. With PHP, you can call the same page back onto itself.
 
On Fri, 2003-04-04 at 14:37, David McGlone wrote:

Hi all, I have a real quick question. I'm trying to learn PHP and right now im 
working with variables, anyway, I cannot get the code below to work 
correctly, could anyone help me out here the problem is, when you submit the 
name, the name will not appear at all.

code below

HTML
FORM METHOD=post
Name:br
INPUT NAME=UserName TYPE=textbr
INPUT TYPE=SUBMIT VALUE=Enter
/FORM
br
Your name is:
?php
echo ($UserName);
?
The action attribute is an excellent suggestion ( I do believe that if 
no action is given, the form defaults to the same file its being 
submitted from ).

Anyhow,

My guess is register_globals is off in your PHP setup.

Depending on your PHP version, replace your $UserName with :

PHP version  4.1 = $HTTP_POST_VARS['UserName']
PHP version  4.1 = $_POST['UserName']
--
Burhan Khalid
phplist[at]meidomus[dot]com


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


RE: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread John W. Holmes
If no action tag is specified, it'll default to the current page. Just
FYI. It's up to the browser, though, so some may decide not to do
anything... 

---John W. Holmes...

PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/

 -Original Message-
 From: Petre Agenbag [mailto:[EMAIL PROTECTED]
 Sent: Friday, April 04, 2003 7:43 AM
 To: David McGlone
 Cc: [EMAIL PROTECTED]
 Subject: Re: [PHP] newbie help, pressing the submit button returns
nothing
 
 Your problem is not with PHP but with basic HTML.
 Your FORM tag needs an action=www.somepage.com in order to do
 something. With PHP, you can call the same page back onto itself.
 
 On Fri, 2003-04-04 at 14:37, David McGlone wrote:
  Hi all, I have a real quick question. I'm trying to learn PHP and
right
 now im
  working with variables, anyway, I cannot get the code below to work
  correctly, could anyone help me out here the problem is, when you
submit
 the
  name, the name will not appear at all.
 
   code below
 
  HTML
  FORM METHOD=post
  Name:br
  INPUT NAME=UserName TYPE=textbr
  INPUT TYPE=SUBMIT VALUE=Enter
  /FORM
  br
  Your name is:
  ?php
 
  echo ($UserName);
  ?
 
  /html
  --
  David M.
  Edification Web Solutions
  http://www.edificationweb.com
 
  --
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit: http://www.php.net/unsub.php
 
 
 
 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php




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



Re: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread David McGlone
On Friday 04 April 2003 07:43 am, Petre Agenbag wrote:
 Your problem is not with PHP but with basic HTML.
 Your FORM tag needs an action=www.somepage.com in order to do
 something. With PHP, you can call the same page back onto itself.

Hi Petre, Thanks for the reply, I have actually tried this too and all the 
output I get is Welcome ! but the username that was entered into the form 
box should appear between the Welcome and !, Please take a look at the code 
below:

First page named: jobapp.html

-HTML
!-- Jobapp.html--
BODY
H1Practice app/H1
pFill in the name and echo it back to the user./p
FORM NAME='frmJobApp' METHOD=post action=jobapp_action.php
Please enter your name:
INPUT NAME=applicant TYPE=textbr
INPUT NAME=enter TYPE=submit VALUE=Enter
/FORM
/BODY
/HTML
---
Second page: named jobapp_action.php

HTML
!-- jobapp_action.php--
BODY
pWelcome ?php echo $applicant; ?!/p
/BODY
/HTML


-- 
David M.
Edification Web Solutions
http://www.edificationweb.com

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



Re: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread Eugene Mah
At 08:24 04-04-03 -0500, you wrote:
On Friday 04 April 2003 07:43 am, Petre Agenbag wrote:
 Your problem is not with PHP but with basic HTML.
 Your FORM tag needs an action=www.somepage.com in order to do
 something. With PHP, you can call the same page back onto itself.
Hi Petre, Thanks for the reply, I have actually tried this too and all the
output I get is Welcome ! but the username that was entered into the form
box should appear between the Welcome and !, Please take a look at the code
below:
First page named: jobapp.html

-HTML
!-- Jobapp.html--
BODY
H1Practice app/H1
pFill in the name and echo it back to the user./p
FORM NAME='frmJobApp' METHOD=post action=jobapp_action.php
Please enter your name:
INPUT NAME=applicant TYPE=textbr
INPUT NAME=enter TYPE=submit VALUE=Enter
/FORM
/BODY
/HTML
---
Second page: named jobapp_action.php
Welcome ?php echo $applicant; ?!
Unless your register_globals is set to on,
you should be using
?PHP echo $_POST['applicant']; ?

instead

Eugene

-
Eugene Mah, M.Sc., DABR   [EMAIL PROTECTED]
Medical Physicist/Misplaced Canuck[EMAIL PROTECTED]
Department of Radiology   For I am a Bear of Very Little
Medical University of South Carolina   Brain, and long words Bother
Charleston, South Carolina me.   Winnie the Pooh
http://www.netcom.com/~eugenem/
PGP KeyID = 0x1F9779FD, 0x319393F4
PGP keys available on request ICQ 3113529 O-
-
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


RE: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread John Coggeshall

Chances are register_globals is off...

Try using $_POST['UserName'] instead of $UserName

John


-~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~-
John Coggeshall
john at coggeshall dot org  http://www.coggeshall.org/
-~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~--~=~-


-Original Message-
From: David McGlone [mailto:[EMAIL PROTECTED] 
Sent: Friday, April 04, 2003 7:38 AM
To: [EMAIL PROTECTED]
Subject: [PHP] newbie help, pressing the submit button returns nothing


Hi all, I have a real quick question. I'm trying to learn PHP 
and right now im 
working with variables, anyway, I cannot get the code below to work 
correctly, could anyone help me out here the problem is, when 
you submit the 
name, the name will not appear at all.

 code below

HTML
FORM METHOD=post
Name:br
INPUT NAME=UserName TYPE=textbr
INPUT TYPE=SUBMIT VALUE=Enter
/FORM
br
Your name is:
?php

echo ($UserName);
?

/html
-- 
David M.
Edification Web Solutions
http://www.edificationweb.com

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




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



Re: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread David McGlone
On Friday 04 April 2003 08:54 am, Eugene Mah wrote:
 At 08:24 04-04-03 -0500, you wrote:
 On Friday 04 April 2003 07:43 am, Petre Agenbag wrote:
   Your problem is not with PHP but with basic HTML.
   Your FORM tag needs an action=www.somepage.com in order to do
   something. With PHP, you can call the same page back onto itself.
 
 Hi Petre, Thanks for the reply, I have actually tried this too and all the
 output I get is Welcome ! but the username that was entered into the
  form box should appear between the Welcome and !, Please take a look at
  the code
 
 below:
  First page named: jobapp.html
 
 -HTML
 !-- Jobapp.html--
 BODY
 H1Practice app/H1
 pFill in the name and echo it back to the user./p
 FORM NAME='frmJobApp' METHOD=post action=jobapp_action.php
 Please enter your name:
 INPUT NAME=applicant TYPE=textbr
 INPUT NAME=enter TYPE=submit VALUE=Enter
 /FORM
 /BODY
 /HTML
 ---
 
  Second page: named jobapp_action.php
 
 Welcome ?php echo $applicant; ?!

 Unless your register_globals is set to on,
 you should be using

 ?PHP echo $_POST['applicant']; ?

This isn't working either : - (

What in the world could be wrong?
-- 
David M.
Edification Web Solutions
http://www.edificationweb.com

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



Re[2]: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread Centras
Friday, April 4, 2003, 6:47:38 PM, you wrote:

DM On Friday 04 April 2003 08:54 am, Eugene Mah wrote:
 At 08:24 04-04-03 -0500, you wrote:
 On Friday 04 April 2003 07:43 am, Petre Agenbag wrote:
   Your problem is not with PHP but with basic HTML.
   Your FORM tag needs an action=www.somepage.com in order to do
   something. With PHP, you can call the same page back onto itself.
 
 Hi Petre, Thanks for the reply, I have actually tried this too and all the
 output I get is Welcome ! but the username that was entered into the
  form box should appear between the Welcome and !, Please take a look at
  the code
 
 below:
  First page named: jobapp.html
 
 -HTML
 !-- Jobapp.html--
 BODY
 H1Practice app/H1
 pFill in the name and echo it back to the user./p
 FORM NAME='frmJobApp' METHOD=post action=jobapp_action.php
 Please enter your name:
 INPUT NAME=applicant TYPE=textbr
 INPUT NAME=enter TYPE=submit VALUE=Enter
 /FORM
 /BODY
 /HTML
 ---
 
  Second page: named jobapp_action.php
 
 Welcome ?php echo $applicant; ?!

 Unless your register_globals is set to on,
 you should be using

 ?PHP echo $_POST['applicant']; ?

DM This isn't working either : - (

DM What in the world could be wrong?
DM -- 
DM David M.
DM Edification Web Solutions
DM http://www.edificationweb.com


Hello, Try to insert into jobapp_action.php:

? If (isset($submit) {
 echo $_POST['applicant'];
}
?



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



RE: Re[2]: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread Ford, Mike [LSS]
 -Original Message-
 From: Centras [mailto:[EMAIL PROTECTED]
 Sent: 04 April 2003 18:58
 
 Friday, April 4, 2003, 6:47:38 PM, you wrote:
 
 DM On Friday 04 April 2003 08:54 am, Eugene Mah wrote:
  At 08:24 04-04-03 -0500, you wrote:
  On Friday 04 April 2003 07:43 am, Petre Agenbag wrote:
Your problem is not with PHP but with basic HTML.
Your FORM tag needs an action=www.somepage.com in 
 order to do
something. With PHP, you can call the same page back 
 onto itself.
  
  Hi Petre, Thanks for the reply, I have actually tried 
 this too and all the
  output I get is Welcome ! but the username that was 
 entered into the
   form box should appear between the Welcome and !, Please 
 take a look at
   the code
  
  below:
   First page named: jobapp.html
  
  -HTML
  !-- Jobapp.html--
  BODY
  H1Practice app/H1
  pFill in the name and echo it back to the user./p
  FORM NAME='frmJobApp' METHOD=post action=jobapp_action.php
  Please enter your name:
  INPUT NAME=applicant TYPE=textbr
  INPUT NAME=enter TYPE=submit VALUE=Enter
  /FORM
  /BODY
  /HTML
  ---
  
   Second page: named jobapp_action.php
  
  Welcome ?php echo $applicant; ?!
 
  Unless your register_globals is set to on,
  you should be using
 
  ?PHP echo $_POST['applicant']; ?
 
 DM This isn't working either : - (
 
 DM What in the world could be wrong?
 
 
 Hello, Try to insert into jobapp_action.php:
 
 ? If (isset($submit) {
  echo $_POST['applicant'];
 }
 ?

Well, that's a fairly braindead suggestion for two reasons:

(1) If he needs $_POST['applicant'], then he'll need $_POST['submit'] too.
(2) If $_POST['submit'] isn't set, how (or maybe why) in the world did he
get into this script anyway?

My final shot would be -- which version of PHP are you running? If it's
earlier than 4.1 (unlikely, I know, but...), then you'll need to do
$HTTP_POST_VARS['applicant'] instead of $_POST['applicant'].

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning  Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 

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



Re: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread David McGlone
On Friday 04 April 2003 12:23 pm, Ford, Mike [LSS] wrote:
  -Original Message-
  From: Centras [mailto:[EMAIL PROTECTED]
  Sent: 04 April 2003 18:58
 Well, that's a fairly braindead suggestion for two reasons:

 (1) If he needs $_POST['applicant'], then he'll need $_POST['submit'] too.
 (2) If $_POST['submit'] isn't set, how (or maybe why) in the world did he
 get into this script anyway?

 My final shot would be -- which version of PHP are you running? If it's
 earlier than 4.1 (unlikely, I know, but...), then you'll need to do
 $HTTP_POST_VARS['applicant'] instead of $_POST['applicant'].

Hi Mike, Well I got into this script from the book professional php 
programming 

To answer your other question, according to phpinfo() im running php version 
4.3.1. Plus, I already tried the HTTP_POST_VARS and got the same results.

Im beginning to think it has something to do with my PHP setup on my box. I've 
also took into consideration my browser returning the result in white, which 
would blend in with the broswers background, but thats not the case either.

I guess it wouldn't hurt to try what centras suggested. I'll report back on 
whether that worked or not.
-- 
David M.
Edification Web Solutions
http://www.edificationweb.com

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



RE: [PHP] newbie help, pressing the submit button returns nothing

2003-04-04 Thread John W. Holmes
I'm posting at the top because we need to start all over with this. If
you're using PHP 4.3.1, then the following WILL work. If it doesn't then
you are doing something wrong in your coding and it's not PHP. Check
your spelling and the case of your variables (PHP is case sensitive). 

HTML
!-- Jobapp.html--
BODY
H1Practice app/H1
pFill in the name and echo it back to the user./p
FORM NAME='frmJobApp' METHOD=post action=jobapp_action.php
Please enter your name:
INPUT NAME=applicant TYPE=textbr
INPUT NAME=enter TYPE=submit VALUE=Enter
/FORM
/BODY
/HTML


HTML
!-- Jobapp_action.php--
BODY
Hello ?php echo $_POST['applicant']; ?!
/BODY
/HTML


---John W. Holmes...

PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/

 -Original Message-
 From: David McGlone [mailto:[EMAIL PROTECTED]
 Sent: Friday, April 04, 2003 11:48 AM
 To: [EMAIL PROTECTED]
 Subject: Re: [PHP] newbie help, pressing the submit button returns
nothing
 
 On Friday 04 April 2003 08:54 am, Eugene Mah wrote:
  At 08:24 04-04-03 -0500, you wrote:
  On Friday 04 April 2003 07:43 am, Petre Agenbag wrote:
Your problem is not with PHP but with basic HTML.
Your FORM tag needs an action=www.somepage.com in order to
do
something. With PHP, you can call the same page back onto
itself.
  
  Hi Petre, Thanks for the reply, I have actually tried this too and
all
 the
  output I get is Welcome ! but the username that was entered into
the
   form box should appear between the Welcome and !, Please take a
look
 at
   the code
  
  below:
   First page named: jobapp.html
  
  -HTML
  !-- Jobapp.html--
  BODY
  H1Practice app/H1
  pFill in the name and echo it back to the user./p
  FORM NAME='frmJobApp' METHOD=post action=jobapp_action.php
  Please enter your name:
  INPUT NAME=applicant TYPE=textbr
  INPUT NAME=enter TYPE=submit VALUE=Enter
  /FORM
  /BODY
  /HTML
  ---
  
   Second page: named jobapp_action.php
  
  Welcome ?php echo $applicant; ?!
 
  Unless your register_globals is set to on,
  you should be using
 
  ?PHP echo $_POST['applicant']; ?
 
 This isn't working either : - (
 
 What in the world could be wrong?
 --
 David M.
 Edification Web Solutions
 http://www.edificationweb.com
 
 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php




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



Re: [PHP] newbie help, pressing the submit button returns nothing(solved)

2003-04-04 Thread David McGlone
On Friday 04 April 2003 12:57 pm, Centras wrote:
 Friday, April 4, 2003, 6:47:38 PM, you wrote:

 DM On Friday 04 April 2003 08:54 am, Eugene Mah wrote:
  At 08:24 04-04-03 -0500, you wrote:
  On Friday 04 April 2003 07:43 am, Petre Agenbag wrote:
Your problem is not with PHP but with basic HTML.
Your FORM tag needs an action=www.somepage.com in order to do
something. With PHP, you can call the same page back onto itself.

   Second page: named jobapp_action.php
  
  Welcome ?php echo $applicant; ?!

Thank you all for helping me, I have finally figured out why the name wasn't 
displaying.

from the line above, $applicant should have been applicant.

-- 
David M.
Edification Web Solutions
http://www.edificationweb.com

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



RE: [PHP] newbie help, pressing the submit button returns nothing(solved)

2003-04-04 Thread John W. Holmes
   Welcome ?php echo $applicant; ?!
 
 Thank you all for helping me, I have finally figured out why the name
 wasn't displaying. from the line above, $applicant should have been 
 applicant.

Are you sure you're using PHP?

---John W. Holmes...

PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/



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



Re: [PHP] newbie help, pressing the submit button returns nothing(solved)

2003-04-04 Thread David McGlone
On Friday 04 April 2003 01:15 pm, you wrote:
Welcome ?php echo $applicant; ?!
 
  Thank you all for helping me, I have finally figured out why the name
  wasn't displaying. from the line above, $applicant should have been
  applicant.

 Are you sure you're using PHP?
I guess so, here's what worked:

everybody was telling me this, but I failed to notice that what everyone said 
was to use $_POST['applicant']

but I was using $_POST['$applicant'] I wasn't paying attention to the $ 

HTML
!-- jobapp_action.php--
BODY
Welcome
?php echo $_POST['applicant']; ?!
/BODY
/HTML

What I would like to use is: echo (Welcome  . applicant . !);
But it doesn't work, so I guess I'll worry about learning what works first.

-- 
David M.
Edification Web Solutions
http://www.edificationweb.com

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



[PHP] Newbie Help

2003-01-03 Thread Erich Kolb
Does anyone have an example of how to download newsgroup headers from a NNTP
server and insert them into a MySQL DB?



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




Re: [PHP] Newbie Help

2003-01-03 Thread Jason Wong
On Saturday 04 January 2003 06:07, Erich Kolb wrote:

Please use a descriptive subject related to your problem. Imagine the 
confusion if everybody used Newbie help or just Help as the subject.

 Does anyone have an example of how to download newsgroup headers from a
 NNTP server and insert them into a MySQL DB?

Try searching:

  www.phpclasses.org
  www.hotscripts.com
  www.phpbuilder.net

-- 
Jason Wong - Gremlins Associates - www.gremlins.biz
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *

/*
One man's magic is another man's engineering.  Supernatural is a null 
word.
-- Robert Heinlein
*/


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




[PHP] newbie: help with date arithmetic

2002-11-12 Thread ROBERT MCPEAK
I'm trying to add/subract two dates.  I think I need to use mktime() but I can't quite 
figure out how.

I'd like to do something like this:

(2002-11-15)-(2002-11-10)=5

or

(2002-12-10)-(2002-11-10)=20

Obviously taking into account number of days in a given month.


Does somebody have some code handy that does this?  Any help would be greatly 
appreciated!

Thanks.


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




Re: [PHP] newbie: help with date arithmetic

2002-11-12 Thread Ernest E Vogelsinger
At 16:30 12.11.2002, ROBERT MCPEAK spoke out and said:
[snip]
I'm trying to add/subract two dates.  I think I need to use mktime() but I 
can't quite figure out how.

I'd like to do something like this:

(2002-11-15)-(2002-11-10)=5

or

(2002-12-10)-(2002-11-10)=20

Obviously taking into account number of days in a given month.
[snip] 

:)) rtfm, again :))

1) http://www.php.net/manual/en/function.strtotime.php
2) http://www.gnu.org/manual/tar-1.12/html_chapter/tar_7.html

3) your second equation would return 30, not 20 ;-
4) try this:

/* untested */
function days($str_from, $str_to) {
$from = strtotime(isset($str_from) ? $str_from : 'now');
$to   = strtotime(isset($str_to) ? $str_to : 'now');
if ($from  $to) {
   $x = $from; $from = $to; $to = $x;
}
$rslt = $to - $from; // number in seconds
return (int)($rslt / 86400); // return days (1d = 86400 secs)
}

Hope this helps,

-- 
   O Ernest E. Vogelsinger 
   (\) ICQ #13394035 
^ http://www.vogelsinger.at/



RE: [PHP] newbie: help with date arithmetic[Scanned]

2002-11-12 Thread Michael Egan
Robert,

I've been looking at this myself over the past couple of days.

I gather the best approach is to convert your dates into UNIX timestamps. 

For example:

$first_unix_time = mktime($hour1, $minutes1, $seconds1, $month1, $day1, $year1);

$second_unix_time = mktime($hour2, $minutes2, $seconds2, $month2, $day2, $year2);

Subtract the one from the other to give the difference:

$difference = $first_unix_time - $second_unix_time;

The result will be in seconds so you'll need to convert this depending on the format 
you require. 

For example, to convert the difference to years you might do:

$years = floor($difference / (365 * 24 * 60 * 60));

Hope this helps,

Michael Egan

-Original Message-
From: ROBERT MCPEAK [mailto:RMCPEAK;jhuccp.org]
Sent: 12 November 2002 15:31
To: [EMAIL PROTECTED]
Subject: [PHP] newbie: help with date arithmetic[Scanned]


I'm trying to add/subract two dates.  I think I need to use mktime() but I can't quite 
figure out how.

I'd like to do something like this:

(2002-11-15)-(2002-11-10)=5

or

(2002-12-10)-(2002-11-10)=20

Obviously taking into account number of days in a given month.


Does somebody have some code handy that does this?  Any help would be greatly 
appreciated!

Thanks.


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


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




RE: [PHP] newbie: help with date arithmetic[Scanned]

2002-11-12 Thread ROBERT MCPEAK

This is a great help.  Thanks ya'll.  And I will continue to, and do regulary RTFM 
8-)  I find that it generally sucks for a newbie.


 Michael Egan [EMAIL PROTECTED] 11/12/02 10:42AM 
Robert,

I've been looking at this myself over the past couple of days.

I gather the best approach is to convert your dates into UNIX timestamps. 

For example:

$first_unix_time = mktime($hour1, $minutes1, $seconds1, $month1, $day1, $year1);

$second_unix_time = mktime($hour2, $minutes2, $seconds2, $month2, $day2, $year2);

Subtract the one from the other to give the difference:

$difference = $first_unix_time - $second_unix_time;

The result will be in seconds so you'll need to convert this depending on the format 
you require. 

For example, to convert the difference to years you might do:

$years = floor($difference / (365 * 24 * 60 * 60));

Hope this helps,

Michael Egan

-Original Message-
From: ROBERT MCPEAK [mailto:RMCPEAK;jhuccp.org] 
Sent: 12 November 2002 15:31
To: [EMAIL PROTECTED] 
Subject: [PHP] newbie: help with date arithmetic[Scanned]


I'm trying to add/subract two dates.  I think I need to use mktime() but I can't quite 
figure out how.

I'd like to do something like this:

(2002-11-15)-(2002-11-10)=5

or

(2002-12-10)-(2002-11-10)=20

Obviously taking into account number of days in a given month.


Does somebody have some code handy that does this?  Any help would be greatly 
appreciated!

Thanks.


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



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




[PHP] newbie help please

2002-06-02 Thread Christopher J. Crane

$Tags['issue-name']. So I could print it out. Something like, print
$Tags['issue-name']br\n;

I was able to get a numerical representation of the array like, $Tags[5] and
the value of that tag was RED HAT, but then I would have to know what the
position of the data I am looking for in the array. I would prefer to know
the tag name and the array and get to the data that way. I know there is a
way to do this, but I just can't figure it out. There is a lot of
information on Parsing the XML file but not getting into a useful array, or
at least that I have found easily to understand.


if(!isset($Sym)) { $Sym = 'IKN'; }
$URI = 'http://quotes.nasdaq.com/quote.dll?page=xmlmode=stocksymbol=';
$simple = implode( '', file($URI$Sym));

$p = xml_parser_create();
xml_parse_into_struct($p,$simple,$vals,$index);
xml_parser_free($p);




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




[PHP] Newbie help please!

2002-05-15 Thread John

Hello,

I am about 3 hrs old with php and have a very simple question. I
have a test.html page that is just an href and I want to put the variables
into php variables on the next page but I get an error. Could someone please
correct my code or tell me what is wrong. We use IIS NT 4.0 MySQL. We have
installed PHPBB and it works great!  Thanks in advance for your time.

test.html code
html
head
 titleUntitled/title
/head
body
/body
a href=test.php?user=adminpass=123456Click here/a
/html


test.php code
?php
$username = user;
$password = pass;
echo $username;
echo $password;
?

error messages---
Notice: Use of undefined constant user - assumed 'user' in
\\SERVER\web\phpBB2\test.php on line 3

Notice: Use of undefined constant pass - assumed 'pass' in
\\SERVER\web\phpBB2\test.php on line 4
userpass



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




RE: [PHP] Newbie help please!

2002-05-15 Thread Tommy Claasens - Q Data KZN

Hi, 


Try this 
?php
$username = $_GET['user'];
$password = $_GET['pass'];
echo $username;
echo $password;
?

-Original Message-
From: John [mailto:[EMAIL PROTECTED]]
Sent: Wed, 15 May 2002 16:46
To: [EMAIL PROTECTED]
Subject: [PHP] Newbie help please!


Hello,

I am about 3 hrs old with php and have a very simple question. I
have a test.html page that is just an href and I want to put the variables
into php variables on the next page but I get an error. Could someone please
correct my code or tell me what is wrong. We use IIS NT 4.0 MySQL. We have
installed PHPBB and it works great!  Thanks in advance for your time.

test.html code
html
head
 titleUntitled/title
/head
body
/body
a href=test.php?user=adminpass=123456Click here/a
/html


test.php code
?php
$username = user;
$password = pass;
echo $username;
echo $password;
?

error messages---
Notice: Use of undefined constant user - assumed 'user' in
\\SERVER\web\phpBB2\test.php on line 3

Notice: Use of undefined constant pass - assumed 'pass' in
\\SERVER\web\phpBB2\test.php on line 4
userpass



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

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




RE: [PHP] Newbie help please!

2002-05-15 Thread Jay Blanchard

[snip]
test.html code
html
head
 titleUntitled/title
/head
body
/body
a href=test.php?user=adminpass=123456Click here/a
/html

test.php code
?php
$username = user;
$password = pass;
echo $username;
echo $password;
?
[/snip]

$user will be 'admin'
$pass will be '123456'

You made an attempt to change the variable names, so you should have done
this;

?php
$username = $user; //note the variable designation
$password = $pass; //note the variable designation
echo $username;
echo $password;
?

HTH!

Jay



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




RE: [PHP] Newbie help please!

2002-05-15 Thread Collins, Robert

this will do it:
?php
$username = $_GET['user'];
$password = $_GET['pass'];
echo $username;
echo $password;
?

Robert W. Collins II 
Webmaster 
New Orleans Regional Transit Authority 
Phone : (504) 248-3826 
Email : [EMAIL PROTECTED] 



-Original Message-
From: John [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, May 15, 2002 9:46 AM
To: [EMAIL PROTECTED]
Subject: [PHP] Newbie help please!


Hello,

I am about 3 hrs old with php and have a very simple question. I
have a test.html page that is just an href and I want to put the variables
into php variables on the next page but I get an error. Could someone please
correct my code or tell me what is wrong. We use IIS NT 4.0 MySQL. We have
installed PHPBB and it works great!  Thanks in advance for your time.

test.html code
html
head
 titleUntitled/title
/head
body
/body
a href=test.php?user=adminpass=123456Click here/a
/html


test.php code
?php
$username = user;
$password = pass;
echo $username;
echo $password;
?

error messages---
Notice: Use of undefined constant user - assumed 'user' in
\\SERVER\web\phpBB2\test.php on line 3

Notice: Use of undefined constant pass - assumed 'pass' in
\\SERVER\web\phpBB2\test.php on line 4
userpass



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

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




RE: [PHP] Newbie help please!

2002-05-15 Thread Brian McGarvie

or this 
?php
echo $user;
echo $pass;
?

-Original Message-
From: Tommy Claasens - Q Data KZN [mailto:[EMAIL PROTECTED]]
Sent: 15 May 2002 15:57
To: John; [EMAIL PROTECTED]
Subject: RE: [PHP] Newbie help please!


Hi, 


Try this 
?php
$username = $_GET['user'];
$password = $_GET['pass'];
echo $username;
echo $password;
?

-Original Message-
From: John [mailto:[EMAIL PROTECTED]]
Sent: Wed, 15 May 2002 16:46
To: [EMAIL PROTECTED]
Subject: [PHP] Newbie help please!


Hello,

I am about 3 hrs old with php and have a very simple question. I
have a test.html page that is just an href and I want to put the
variables
into php variables on the next page but I get an error. Could someone
please
correct my code or tell me what is wrong. We use IIS NT 4.0 MySQL. We
have
installed PHPBB and it works great!  Thanks in advance for your time.

test.html code
html
head
 titleUntitled/title
/head
body
/body
a href=test.php?user=adminpass=123456Click here/a
/html


test.php code
?php
$username = user;
$password = pass;
echo $username;
echo $password;
?

error messages---
Notice: Use of undefined constant user - assumed 'user' in
\\SERVER\web\phpBB2\test.php on line 3

Notice: Use of undefined constant pass - assumed 'pass' in
\\SERVER\web\phpBB2\test.php on line 4
userpass



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

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


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




Re: [PHP] Newbie help please!

2002-05-15 Thread John

Tommy,
Thanks that was it.
Tommy Claasens - Q Data Kzn [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 Hi,


 Try this
 ?php
 $username = $_GET['user'];
 $password = $_GET['pass'];
 echo $username;
 echo $password;
 ?

 -Original Message-
 From: John [mailto:[EMAIL PROTECTED]]
 Sent: Wed, 15 May 2002 16:46
 To: [EMAIL PROTECTED]
 Subject: [PHP] Newbie help please!


 Hello,

 I am about 3 hrs old with php and have a very simple question. I
 have a test.html page that is just an href and I want to put the variables
 into php variables on the next page but I get an error. Could someone
please
 correct my code or tell me what is wrong. We use IIS NT 4.0 MySQL. We have
 installed PHPBB and it works great!  Thanks in advance for your time.

 test.html code
 html
 head
  titleUntitled/title
 /head
 body
 /body
 a href=test.php?user=adminpass=123456Click here/a
 /html


 test.php code
 ?php
 $username = user;
 $password = pass;
 echo $username;
 echo $password;
 ?

 error messages---
 Notice: Use of undefined constant user - assumed 'user' in
 \\SERVER\web\phpBB2\test.php on line 3

 Notice: Use of undefined constant pass - assumed 'pass' in
 \\SERVER\web\phpBB2\test.php on line 4
 userpass



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



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




[PHP] Newbie help

2002-03-21 Thread Tony Alanis

Hello all,

I'm looking for resources for PHP/FoxPro.  I have a limited
understanding of php and mysql, however, the company I work for uses a
FoxPro backend database.  I want to be able to pull information from
this database to be used on our intranet site I am currently developing.
If anyone can point me to some resources for this, I'd really appreciate
it.

Thanks,

Tony Alanis


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




Re: [PHP] Newbie help

2002-03-21 Thread cal

Tony,

I'm doing a lot of PHP-VFP-MySql work right now.  I'm developing
processes that move data out of SBT accounting and into a MySQL database for
use on the web.  I'm also working on processes that update the FoxPro data
directly.  The best I can tell you is that the EASIEST thing to do is create
VFP COM objects to do the dirty work and call them from your PHP pages.
There are other ways but not as reliable.

HTH,
=C=
*
* Cal Evans
* Techno-Mage
* http://www.calevans.com
*

- Original Message -
From: Tony Alanis [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 21, 2002 2:05 PM
Subject: [PHP] Newbie help


 Hello all,

 I'm looking for resources for PHP/FoxPro.  I have a limited
 understanding of php and mysql, however, the company I work for uses a
 FoxPro backend database.  I want to be able to pull information from
 this database to be used on our intranet site I am currently developing.
 If anyone can point me to some resources for this, I'd really appreciate
 it.

 Thanks,

 Tony Alanis


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






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




[PHP] newbie - help with field variables in forms

2002-01-08 Thread Andrea Caldwell

Hi there,

I'm really, really new at this (like 2 days into it) and never programmed
before (besides HTML)... so please bear with me.

I established an email feedback form, everything works fine, and now I'd
like to add code to make a couple of fields required.  What function would I
use for this and how would it be structured?

Any help would be appreciated... thanks!

Andrea



-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] newbie - help with field variables in forms

2002-01-08 Thread Ivan Balazs

Hi!

A very simple way to do this is by checking the variables of the form (the
names of fields) if they are isset() or not. To be more specific you can
even check, if any of them is empty().
In special cases like the email address, i suggest using regexp to check
if it is a valid email address.

The structure i use for this:
if (isset($name_of_submit_button) {
here comes the checking part
if (error_occures) $error = true;
}
if (isset($name_of_submit_button)  !$error) {
send the email
} else {
show the form itself
}

this is my way, but there are other good solutions out there as well.


 I established an email feedback form, everything works fine, and now I'd
 like to add code to make a couple of fields required.  What function would I
 use for this and how would it be structured?

 Any help would be appreciated... thanks!
you're welcome
Balazs


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help (CLASS WAR!)

2001-07-27 Thread George Pitcher

Have a look at:

http://www.phpbuilder.com/columns/luis2420.php3

HTH

George, still a newbie after a week on php
- Original Message -
From: CC Zona [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, July 27, 2001 11:25 AM
Subject: Re: [PHP] Newbie Help (CLASS WAR!)


 In article [EMAIL PROTECTED],
  [EMAIL PROTECTED] (Brian White) wrote:

  There are times when I would really like to be able to do:
 
  class A
  {
   function DoStuff()
   {
  .
   }
  }
 
  class B extends A
  {
   function DoStuff()
   {
  .
  $super-DoStuff(); // Calls the function in A
   }
  }

 Maybe I'm misunderstanding you, but isn't that what the A::DoStuff()
syntax
 does?

 --
 CC

 --
 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 administrators, e-mail: [EMAIL PROTECTED]


_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help (CLASS WAR!)

2001-07-26 Thread Brian White


I use classes a lot and don't have this problem. This is because
the names of the class ( and thus the constructor name ) tends to be a noun
and otherfunctions tend to be verbs, so I am don't have this kind of clash.

I am VERY glad that PHP has classes and I use them alot.

However 

rant_mode

My biggest bug-bear with classes in PHP is the lack of a super operator
There are times when I would really like to be able to do:

class A
{
 function DoStuff()
 {
.
 }
}

class B extends A
{
 function DoStuff()
 {
.
$super-DoStuff(); // Calls the function in A
 }
}

A super operator could allow a fixed name constructor ( like the 
__new__ in Python )
and the parent constructor could be called using super, which would 
eliminate
Matthew's problem.

/rant_mode


At 08:47 26/07/2001 +0800, Matthew Schubert wrote:
I was reading through the PHP manual and got to the section on constructors.

snip

class A {
   function A() {
 echo I am the constructor of A.br\n;
   }

   function B() {
 echo I am a regular function named B in class A.br\n;
 echo I am not a constructor in A.br\n;
   }
}

class B extends A {
   function C() {
 echo I am a regular function.br\n;
   }
}

// This will call B() as a constructor.
$b = new B;




In PHP 3, the function B() in class A will suddenly become a constructor in
class B, although it was never intended to be. The rule in PHP 3 is: 'A
constructor is a function of the same name as the class.'. PHP 3 does not
care if the function is being defined in class B, or if it has been
inherited.

This is fixed in PHP 4 by modifying the rule to: 'A constructor is a
function of the same name as the class it is being defined in.'. Thus in PHP
4, the class B would have no constructor function of its own and the
constructor of the base class would have been called, printing 'I am the
constructor of A.br'.
/snip

It says that when a new class B was made, that the class B would have no
constructor, because the function B() was in the base class. Instead the
class B was supposed to derive it's constructor from class A and output 'I
am the constructor of A.br'

When I tried this script, this did not happen and the Function B() was
called as the constructor of class B, even though the function was in the
base class...can anyone help to clear up this matter?
thanx




--
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 administrators, e-mail: [EMAIL PROTECTED]

-
Brian White
Step Two Designs Pty Ltd - SGML, XML  HTML Consultancy
Phone: +612-93197901
Web:   http://www.steptwo.com.au/
Email: [EMAIL PROTECTED]


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




[PHP] Newbie Help

2001-07-25 Thread Matthew Schubert

I was reading through the PHP manual and got to the section on constructors.

snip

class A {
  function A() {
echo I am the constructor of A.br\n;
  }

  function B() {
echo I am a regular function named B in class A.br\n;
echo I am not a constructor in A.br\n;
  }
}

class B extends A {
  function C() {
echo I am a regular function.br\n;
  }
}

// This will call B() as a constructor.
$b = new B;




In PHP 3, the function B() in class A will suddenly become a constructor in
class B, although it was never intended to be. The rule in PHP 3 is: 'A
constructor is a function of the same name as the class.'. PHP 3 does not
care if the function is being defined in class B, or if it has been
inherited.

This is fixed in PHP 4 by modifying the rule to: 'A constructor is a
function of the same name as the class it is being defined in.'. Thus in PHP
4, the class B would have no constructor function of its own and the
constructor of the base class would have been called, printing 'I am the
constructor of A.br'.
/snip

It says that when a new class B was made, that the class B would have no
constructor, because the function B() was in the base class. Instead the
class B was supposed to derive it's constructor from class A and output 'I
am the constructor of A.br'

When I tried this script, this did not happen and the Function B() was
called as the constructor of class B, even though the function was in the
base class...can anyone help to clear up this matter?
thanx




-- 
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 administrators, e-mail: [EMAIL PROTECTED]




[PHP] Newbie. Help on installation on a Win2K

2001-07-10 Thread jemer

Newbie. Help on installation on a Win2K

im a newbie on this and i want a complete detail on PHP Installation on a
Win2K

thnx


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




[PHP] newbie help!

2001-06-30 Thread McShen

hi

I wrote a script to display all file in a directory. Here is my script
---
?php

$dir_name = e:\celebs\christina_aguilera;
$dir = opendir($dir_name);

while ($file_name=readdir($dir)) {

 if (($file_name!=.  $file_name!=..)) {
  echo $file_name.\nnbsp;nbsp;;
 }
}
closedir($dir);
?


This is working fine. But it displays all files in 1 single page. Here is
what i wanna do, but i don't know how to do it.
I wanna display 15 files names at once, and have prev. and next buttons and
the end, when i click on next, it will display the next 15 files.

Please help me.
Thanks in advance.



-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] newbie help!

2001-06-30 Thread Hugh Bothwell

 I wrote a script to display all file in a directory. Here is my script
(snip)
 This is working fine. But it displays all files in 1 single page. Here is
 what i wanna do, but i don't know how to do it.
 I wanna display 15 files names at once, and have prev. and next buttons
and
 the end, when i click on next, it will display the next 15 files.

If you have to do it all in PHP, I would pass a start-file index to the
page; something like this:

?php
$ind = ( isset($ind) ? $ind : 0 );

$dir_name = e:\celebs\christina_aguilera;
$dir = opendir($dir_name);

$prev = ( $ind  0 );// should 'prev' be active?
$next = false;// should 'next' be
active?
$ignore = array(., ..);// files to skip
$i = 0;
while ($fname = readdir($dir)) {
if (in_array($fname, $ignore))
continue;

if ($i = $ind) {
if ($i  $ind + 15) {
echo \nbrnbsp;nbsp;$fname;
}
else {
$next = true;// more files; make 'next'
active
break;
}
}
$i++;
}
closedir($dir);

$prev_pre = ( $prev ? 'a href=#?ind='.max($ind-15,0).'' : '' );
$prev_post = ( $prev ? '/a' : '' );
$next_pre = ( $next ? 'a href=#?ind='.$ind+15.'' : '' );
$next_post = ( $next ? '/a' : '' );
echo \nbr$prev_pre lt;lt;prev $prev_post | $next_pre nextgt;gt;
$next_post;
?

This will skip '.' and '..' without counting them, will enable/disable the
'prev' and 'next' links as needed, will ignore all files past $ind+16 (it
has to read one past the end to know if 'next' should be enabled), and will
automatically stop when it runs out of files.  It will work for all
browsers, at a cost of increased server load.

Personally, I would consider writing all the filenames into a JavaScript
array, and do the paging on the client.



-- 
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 administrators, e-mail: [EMAIL PROTECTED]




[PHP] newbie help with wildcard question

2001-04-24 Thread Publications

Thank you in advance for your response. I have an order form that I would
like to drop directly into my shopping cart. The following form and php
works great for the first input - part_number - is there a wildcard that I
can place at the end of the array so that the cart will pickup all part
numbers entered into the form?

FORM ACTION=?php print MTA_URL('/cart/dropin.php',array('part_number'=
$part_number)); ? method=post
  INPUT TYPE=HIDDEN NAME=Orderform VALUE=No
  table width=22% border=0 cellspacing=0 cellpadding=0
tr
  tdbModel or Part Number: /b/td
/tr
tr
  td
input type=Text name=part_number
  /td
/tr
tr
  td
input type=Text name=part_number2
  /td
/tr
   etc...

Duffy Betterton
Director of Publications
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
www.mtadistributors.com http://www.mtadistributors.com
1-615-277-3265





-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help!! Please Look!

2001-04-19 Thread chris herring

right up my alley... I use cuteftp, and it usually does all this stuff for
you. all you have to do is right click on the file you want to edit, and it
opens it up in notepad, or the editor you choose. just make sure you save
the file before you close it. after that cuteftp will have a window that
says "upload" or "cancel".. choose upload. if you wish to change the editor,
just go to editsettings in cuteftp, and find the text that says "helper
applications" in the window that pops up. click that, and you can choose
your program.
- Original Message -
From: "Tony Daniels" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, April 18, 2001 10:18 PM
Subject: [PHP] Newbie Help!! Please Look!


 Hello,

 I need to know if there is a program out there that I can use to edit
 the PHP files.  I use CuteFTP to download the files from my server as I
 need to change some wording around from time to time.  Does anyone know
 the correct procedure for downloading a php file with CuteFTP and then a
 program that I can use to edit the text I need to edit.  Then also, the
 correct way to upload it back to the server using CuteFTP.  Do I use
 Binary or ACII.

 Or, if I am way off and there is a program that makes CuteFTP look
 silly, please let me know this also.  I am open for any suggestions, as
 long as they are detailed.  Please email responses to [EMAIL PROTECTED]
 .

 Thank you!


 --
 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 administrators, e-mail: [EMAIL PROTECTED]


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help!! Please Look!

2001-04-19 Thread chris herring

forgot to mention that ascii/binary is auto in cuteftp
- Original Message -
From: "chris herring" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, April 19, 2001 1:51 AM
Subject: Re: [PHP] Newbie Help!! Please Look!


 right up my alley... I use cuteftp, and it usually does all this stuff for
 you. all you have to do is right click on the file you want to edit, and
it
 opens it up in notepad, or the editor you choose. just make sure you save
 the file before you close it. after that cuteftp will have a window that
 says "upload" or "cancel".. choose upload. if you wish to change the
editor,
 just go to editsettings in cuteftp, and find the text that says "helper
 applications" in the window that pops up. click that, and you can choose
 your program.
 - Original Message -
 From: "Tony Daniels" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Wednesday, April 18, 2001 10:18 PM
 Subject: [PHP] Newbie Help!! Please Look!


  Hello,
 
  I need to know if there is a program out there that I can use to edit
  the PHP files.  I use CuteFTP to download the files from my server as I
  need to change some wording around from time to time.  Does anyone know
  the correct procedure for downloading a php file with CuteFTP and then a
  program that I can use to edit the text I need to edit.  Then also, the
  correct way to upload it back to the server using CuteFTP.  Do I use
  Binary or ACII.
 
  Or, if I am way off and there is a program that makes CuteFTP look
  silly, please let me know this also.  I am open for any suggestions, as
  long as they are detailed.  Please email responses to [EMAIL PROTECTED]
  .
 
  Thank you!
 
 
  --
  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 administrators, e-mail: [EMAIL PROTECTED]


 --
 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 administrators, e-mail: [EMAIL PROTECTED]


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help!! Please Look!

2001-04-19 Thread Adrian D'Costa

use wordpad.  

Adrian

On Wed, 18 Apr 2001, Tony Daniels wrote:

 I used notepad and it shows some weird symbols like darkened in squares.  That
 is why I was wondering if there was a specific program.  Is there any way to
 get rid of the squares?
 
 Thank for your help.
 
 Jason Murray wrote:
 
   I need to know if there is a program out there that I can use to edit
   the PHP files.  I use CuteFTP to download the files from my server as I
   need to change some wording around from time to time.  Does anyone know
   the correct procedure for downloading a php file with CuteFTP and then a
   program that I can use to edit the text I need to edit.  Then also, the
   correct way to upload it back to the server using CuteFTP.  Do I use
   Binary or ACII.
 
  PHP files (unless optimised by Zend or something) are just plain text
  files. You can use either Binary or ASCII mode to up/download them, and
  your text editor of choice (Notepad, PFM, HomeSite, or for the masochists,
  MS Word :)) to edit them and save them.
 
  Jason
 
  --
  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 administrators, e-mail: [EMAIL PROTECTED]
 
 


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help!! Please Look!

2001-04-19 Thread Geir Eivind Mork

On Thursday 19 April 2001 05:18, Tony Daniels wrote:
  I need to know if there is a program out there that I can use to edit
  the PHP files.  I use CuteFTP to download the files from my server as I

www.homesite.com
www.ultraedit.com
www.slickedit.com

I assume this have uploadfeatures, atleast the two last ones have. they are 
ranged from the cheapest / useable to the $300 slickedit which just rocks :) 
(and the one I use ofcourse) 

-- 
 php developer / CoreTrek AS| "Jesus may love you, but I think you're 
 Sandnes / Rogaland / Norway| garbage wrapped in skin." -- Michael
 web: http://www.moijk.net/ | O'Donohugh 

-- 
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 administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Newbie Help!! Please Look!

2001-04-19 Thread Si

i can honestly recommend phped, infact im amazed no one else has mentioned
it.  Great win32 php programming ide.

hint: ignore the project stuff in it tho as it kinda sucks ;-)

you can grab it from here

http://www.soysal.com/PHPEd/

Si.


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




[PHP] Newbie Help!! Please Look!

2001-04-18 Thread Tony Daniels

Hello,

I need to know if there is a program out there that I can use to edit
the PHP files.  I use CuteFTP to download the files from my server as I
need to change some wording around from time to time.  Does anyone know
the correct procedure for downloading a php file with CuteFTP and then a
program that I can use to edit the text I need to edit.  Then also, the
correct way to upload it back to the server using CuteFTP.  Do I use
Binary or ACII.

Or, if I am way off and there is a program that makes CuteFTP look
silly, please let me know this also.  I am open for any suggestions, as
long as they are detailed.  Please email responses to [EMAIL PROTECTED]
.

Thank you!


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Newbie Help!! Please Look!

2001-04-18 Thread Jason Murray

 I need to know if there is a program out there that I can use to edit
 the PHP files.  I use CuteFTP to download the files from my server as I
 need to change some wording around from time to time.  Does anyone know
 the correct procedure for downloading a php file with CuteFTP and then a
 program that I can use to edit the text I need to edit.  Then also, the
 correct way to upload it back to the server using CuteFTP.  Do I use
 Binary or ACII.

PHP files (unless optimised by Zend or something) are just plain text
files. You can use either Binary or ASCII mode to up/download them, and
your text editor of choice (Notepad, PFM, HomeSite, or for the masochists,
MS Word :)) to edit them and save them.

Jason

-- 
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 administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Newbie Help!! Please Look!

2001-04-18 Thread Jack Dempsey

PHP files are text files, thus you can use any text editor to make your
changes. On Windows, the simplest way would be to use notepad or wordpad to
edit and save your changes. On other platforms like unix/linux you could use
pico, vi, or emacs to name a few.
If you have telnet access to the server, it'd be easier to just code your
changes on the server, bypassing the need for ftp'ing.
To download a file, do the same as you would with any other file. In CuteFTP
you can drag the file from the server window to your desktop (or wherver
your default save location is) and save it there. Then, when you upload,
since its text, you don't need to set it to binary.
I use CuteFTP for uploading and downloading files, but when coding anything,
I find it easier to just telnet in and use pico (now I submit to flames from
BOTH the vi and emacs lovers =P )

best of luck,
jack

-Original Message-
From: Tony Daniels [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 18, 2001 11:18 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Newbie Help!! Please Look!


Hello,

I need to know if there is a program out there that I can use to edit
the PHP files.  I use CuteFTP to download the files from my server as I
need to change some wording around from time to time.  Does anyone know
the correct procedure for downloading a php file with CuteFTP and then a
program that I can use to edit the text I need to edit.  Then also, the
correct way to upload it back to the server using CuteFTP.  Do I use
Binary or ACII.

Or, if I am way off and there is a program that makes CuteFTP look
silly, please let me know this also.  I am open for any suggestions, as
long as they are detailed.  Please email responses to [EMAIL PROTECTED]
.

Thank you!


--
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 administrators, e-mail: [EMAIL PROTECTED]



-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help!! Please Look!

2001-04-18 Thread Tony Daniels

I used notepad and it shows some weird symbols like darkened in squares.  That
is why I was wondering if there was a specific program.  Is there any way to
get rid of the squares?

Thank for your help.

Jason Murray wrote:

  I need to know if there is a program out there that I can use to edit
  the PHP files.  I use CuteFTP to download the files from my server as I
  need to change some wording around from time to time.  Does anyone know
  the correct procedure for downloading a php file with CuteFTP and then a
  program that I can use to edit the text I need to edit.  Then also, the
  correct way to upload it back to the server using CuteFTP.  Do I use
  Binary or ACII.

 PHP files (unless optimised by Zend or something) are just plain text
 files. You can use either Binary or ASCII mode to up/download them, and
 your text editor of choice (Notepad, PFM, HomeSite, or for the masochists,
 MS Word :)) to edit them and save them.

 Jason

 --
 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 administrators, e-mail: [EMAIL PROTECTED]


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help!! Please Look!

2001-04-18 Thread Tony Daniels

I wish I knew how to use Telnet.  Maybe I'll search and learn.

Thank you for your help!

Jack Dempsey wrote:

 PHP files are text files, thus you can use any text editor to make your
 changes. On Windows, the simplest way would be to use notepad or wordpad to
 edit and save your changes. On other platforms like unix/linux you could use
 pico, vi, or emacs to name a few.
 If you have telnet access to the server, it'd be easier to just code your
 changes on the server, bypassing the need for ftp'ing.
 To download a file, do the same as you would with any other file. In CuteFTP
 you can drag the file from the server window to your desktop (or wherver
 your default save location is) and save it there. Then, when you upload,
 since its text, you don't need to set it to binary.
 I use CuteFTP for uploading and downloading files, but when coding anything,
 I find it easier to just telnet in and use pico (now I submit to flames from
 BOTH the vi and emacs lovers =P )

 best of luck,
 jack

 -Original Message-
 From: Tony Daniels [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 18, 2001 11:18 PM
 To: [EMAIL PROTECTED]
 Subject: [PHP] Newbie Help!! Please Look!

 Hello,

 I need to know if there is a program out there that I can use to edit
 the PHP files.  I use CuteFTP to download the files from my server as I
 need to change some wording around from time to time.  Does anyone know
 the correct procedure for downloading a php file with CuteFTP and then a
 program that I can use to edit the text I need to edit.  Then also, the
 correct way to upload it back to the server using CuteFTP.  Do I use
 Binary or ACII.

 Or, if I am way off and there is a program that makes CuteFTP look
 silly, please let me know this also.  I am open for any suggestions, as
 long as they are detailed.  Please email responses to [EMAIL PROTECTED]
 .

 Thank you!

 --
 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 administrators, e-mail: [EMAIL PROTECTED]

 --
 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 administrators, e-mail: [EMAIL PROTECTED]


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Newbie Help!! Please Look!

2001-04-18 Thread Jason Lotito

 -Original Message-
 From: Tony Daniels [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 18, 2001 8:18 PM
 To: [EMAIL PROTECTED]
 Subject: [PHP] Newbie Help!! Please Look!
 
 
 Hello,
 
 I need to know if there is a program out there that I can use to edit
 the PHP files.

Any text editor.  Example: Notepad.

  I use CuteFTP to download the files from my server as I
 need to change some wording around from time to time.  Does anyone know
 the correct procedure for downloading a php file with CuteFTP and then a
 program that I can use to edit the text I need to edit.

1) Download the php file just like you would a html file.
2) Edit the file using a text editor.

  Then also, the
 correct way to upload it back to the server using CuteFTP.  Do I use
 Binary or ACII.

Neither.  You use ASCII.

 
 Or, if I am way off and there is a program that makes CuteFTP look
 silly, please let me know this also.

I don't think so, though funny is a relative word.  I use WS_FTP.

  I am open for any suggestions, as
 long as they are detailed.  Please email responses to [EMAIL PROTECTED]

You mean to reply to the PHP Mailing list, right?

 .
 
 Thank you!

Your welcome.

-- 
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 administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Newbie Help!! Please Look!

2001-04-18 Thread Jason Murray

 I used notepad and it shows some weird symbols like darkened 
 in squares.  That is why I was wondering if there was a specific 
 program.  Is there any way to get rid of the squares?

The squares are characters Notepad doesn't recognise.

If you see them in anything, not just PHP files, open it in WordPad.

Me, I use HomeSite.

Jason

-- 
Jason Murray
[EMAIL PROTECTED]
Web Design Team, Melbourne IT
Fetch the comfy chair!

-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help!! Please Look!

2001-04-18 Thread Tony Daniels

Ah, that helps tons.

Thank you!!

Jason Murray wrote:

  I used notepad and it shows some weird symbols like darkened
  in squares.  That is why I was wondering if there was a specific
  program.  Is there any way to get rid of the squares?

 The squares are characters Notepad doesn't recognise.

 If you see them in anything, not just PHP files, open it in WordPad.

 Me, I use HomeSite.

 Jason

 --
 Jason Murray
 [EMAIL PROTECTED]
 Web Design Team, Melbourne IT
 Fetch the comfy chair!

 --
 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 administrators, e-mail: [EMAIL PROTECTED]


-- 
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 administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] Newbie Help!! Please Look!

2001-04-18 Thread Jack Dempsey

its not so much learning "telnet" as learning unix or linux...but as far as
editing text files, its easy...here're some basic commands to get you
started:

telnet www.yourhost.com
login: enter it
password: enter it
prompt$ pico yourfile.php

i find pico to be the quickest and easiest (and probably the "weakest") of
the text editors on *nix systems...start with it and progress if you want...
you can use the arrow keys as you'd expect...edit your file then hit
control-x, y, return to save and quit from your file and pico...at any time
you can also use ctrl-o to save your progress without quitting...

the squares in notepad were a result of you taking a file from a *nix
systemtry opening it with wordpad, and you should be fine...

-jack

-Original Message-
From: Tony Daniels [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 18, 2001 11:26 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] Newbie Help!! Please Look!


I wish I knew how to use Telnet.  Maybe I'll search and learn.

Thank you for your help!

Jack Dempsey wrote:

 PHP files are text files, thus you can use any text editor to make your
 changes. On Windows, the simplest way would be to use notepad or wordpad
to
 edit and save your changes. On other platforms like unix/linux you could
use
 pico, vi, or emacs to name a few.
 If you have telnet access to the server, it'd be easier to just code your
 changes on the server, bypassing the need for ftp'ing.
 To download a file, do the same as you would with any other file. In
CuteFTP
 you can drag the file from the server window to your desktop (or wherver
 your default save location is) and save it there. Then, when you upload,
 since its text, you don't need to set it to binary.
 I use CuteFTP for uploading and downloading files, but when coding
anything,
 I find it easier to just telnet in and use pico (now I submit to flames
from
 BOTH the vi and emacs lovers =P )

 best of luck,
 jack

 -Original Message-
 From: Tony Daniels [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 18, 2001 11:18 PM
 To: [EMAIL PROTECTED]
 Subject: [PHP] Newbie Help!! Please Look!

 Hello,

 I need to know if there is a program out there that I can use to edit
 the PHP files.  I use CuteFTP to download the files from my server as I
 need to change some wording around from time to time.  Does anyone know
 the correct procedure for downloading a php file with CuteFTP and then a
 program that I can use to edit the text I need to edit.  Then also, the
 correct way to upload it back to the server using CuteFTP.  Do I use
 Binary or ACII.

 Or, if I am way off and there is a program that makes CuteFTP look
 silly, please let me know this also.  I am open for any suggestions, as
 long as they are detailed.  Please email responses to [EMAIL PROTECTED]
 .

 Thank you!

 --
 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 administrators, e-mail: [EMAIL PROTECTED]

 --
 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 administrators, e-mail: [EMAIL PROTECTED]


--
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 administrators, e-mail: [EMAIL PROTECTED]



-- 
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 administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Newbie Help!! Please Look!

2001-04-18 Thread Brian Clark

Hi Tony,

@ 11:24:30 PM on 4/18/2001, Tony Daniels wrote:

 I used notepad and it shows some weird symbols like darkened in
 squares. That is why I was wondering if there was a specific
 program. Is there any way to get rid of the squares?

Those are 'end of line characters' that your Operating System doesn't
understand. You'll probably see that if you're editing files that were
created on Linux or Unix. Likewise, if you edit the files on a PC then
upload them in your native format, to Unix or Linux they're going to
end up having ^M's at the end of each line.

Your best bet is to grab a fairly decent Programmer's Editor that can
tell the difference and (re)act accordingly.

Some good ones that come to mind are EditPlus (I've used it) or TextPad
(I prefer it). You can find others in quite a long list here:

http://www.itworks.demon.co.uk/phpeditors.htm

-Brian
--
 PGP is spoken here: 0xE4D0C7C8
 Please, DO NOT carbon copy me on list replies.



-- 
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 administrators, e-mail: [EMAIL PROTECTED]