[PHP] php forgetting variables very easily

2003-03-04 Thread Ian A. Gray
Hi everyone.I am probably doing something obviously
wrong but I can't seem to sort it!  It's regarding
variables.In one script, lets call it main.php I make
a variable- say $colour.  It inludes a file which
prints the variable:

main.php


new.php


Ok, this works fine for me.  However it doesn't seem
to work when main.php and new.php have html in them. 
The variable seems to be lost and new.php prints
nothing.  Has anyone got any words of wisdom on this? 
It may help if I actually showed the two pages here,
but they are long and I thought it would be a waste of
space.

Best wishes,
Ian

=

-------------
Ian A. Gray
Manchester, UK
Telephone: +44 (0) 161 224 1635 - Fax: +44 (0) 870 135 0061 - Mobile: +44 (0) 7900 996 
328
US Fax no.:  707-885-3582
E-mail: [EMAIL PROTECTED] - Websites: www.baritone.uk.com (performance) & 
www.vocalstudio.co.uk (Tuition)
-


__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

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



[PHP] Re: php forgetting variables very easily

2003-03-05 Thread Ian A. Gray
I am still having problems with variables not being
remembered by included files.  I've tried using the
global command and it still doesn't work.  I've cut
down my two pages to contain the main stuff so you can
see what's happening.  Basically main.php includes the
file new.php and I want the variable '$name' to be
remembered in it.  The other included files aren't
important to the problem I'm having.

main.php
===



Tite



 http://www.vocalwebsites.com/neilhowlett/new.php";)
  ?>

http://www.vocalwebsites.com/footer.php";);
?>




new.php
=


http://www.vocalwebsites.com/date.php";);
?>




| home | 
biography | 
performance |
teaching | 
articles | 
audio | 
contact |




=
At the moment $name is not printing out in the
included file which seems to me like php has forgotten
the variable.  Any ideas?

If I actually get this to work I want to be able to
use the variable '$name' to be able to change the
'navigation bar' in new.php so that the correspoding
link won't be linked.  For example in the above
example if $name = home then 'home; won't have the 
link tag or if $name = contact then contact won't be
linked.  I know I am not explaining this very well,
but I hope this is clear.

Ian Gray

=

-
Ian A. Gray
Manchester, UK
Telephone: +44 (0) 161 224 1635 - Fax: +44 (0) 870 135 0061 - Mobile: +44 (0) 7900 996 
328
US Fax no.:  707-885-3582
E-mail: [EMAIL PROTECTED] - Websites: www.baritone.uk.com (performance) & 
www.vocalstudio.co.uk (Tuition)
-


__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

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



[PHP] Re: php forgetting variables very easily

2003-03-05 Thread Ian A. Gray
Thanks, John- that works brilliantly.
Just wandering how I can include a file in a different
directory so that it still remembers variables.

for example what if I want to include the file
www.example.com/two/example.php in the file:
www.example.com/one/example.php
?
would include('/two/example.php') work?

Would it not work from a different domain?

Many thanks,
Ian Gray

=

---------
Ian A. Gray
Manchester, UK
Telephone: +44 (0) 161 224 1635 - Fax: +44 (0) 870 135 0061 - Mobile: +44 (0) 7900 996 
328
US Fax no.:  707-885-3582
E-mail: [EMAIL PROTECTED] - Websites: www.baritone.uk.com (performance) & 
www.vocalstudio.co.uk (Tuition)
-


__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

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



[PHP] html mail

2003-03-10 Thread Ian A. Gray
Hi,
I am quite new to php and I am trying to find a way of
sending details of a web form over e-mail in both text
and html format.  There are numerous sites on the web
that try and explain how to do this but they are
worded very complicated and to be honest I haven't
found one that is particularly good.

I want to send an e-mail that contains html code, with
the option of attatching images and other files as
well as a text version of the email so that the viewer
can read the same e-mail whether or not he can view
html email or not.

Any ideas?

Ian Gray.

=

-----
Ian A. Gray
Manchester, UK
Telephone: +44 (0) 161 224 1635 - Fax: +44 (0) 870 135 0061 - Mobile: +44 (0) 7900 996 
328
US Fax no.:  707-885-3582
E-mail: [EMAIL PROTECTED] - Websites: www.baritone.uk.com (performance) & 
www.vocalstudio.co.uk (Tuition)
-


__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

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



[PHP] html mail

2003-03-10 Thread Ian A. Gray
The pear class looks great, unfortunately my server
doesn't have pear yet. :-(
I didn't realise it was an either/or situation for
sending html or text only e-mails.  I thought you
could send one e-mail which has the content in
text-only and html-format so that the person's e-mail
programme can decide how to read it.

Ian Gray

=

-------------
Ian A. Gray
Manchester, UK
Telephone: +44 (0) 161 224 1635 - Fax: +44 (0) 870 135 0061 - Mobile: +44 (0) 7900 996 
328
US Fax no.:  707-885-3582
E-mail: [EMAIL PROTECTED] - Websites: www.baritone.uk.com (performance) & 
www.vocalstudio.co.uk (Tuition)
-


__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

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



[PHP] variables with ""

2003-03-17 Thread Ian A. Gray
Hi,
just a quick question.  How do I include double quotes
in a variable?  I am trying to put html code in a
variable in a mailing program:



$mail->Body = "Heading
Please e-mail me at mailto:[EMAIL PROTECTED]">[EMAIL PROTECTED]"



I know that you don't have to inclose everything in
html tags with quotes, but sometimes you do.  The
above qon't work obviously as it has nested quotes. 
How do I get the above to work?

Many thanks,

Ian Gray


__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

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



[PHP] re: variables with ""

2003-03-17 Thread Ian A. Gray
Using the \ or using single quotes instead of double
is great.  However I am now finding a problem if
someone inputs either single or double quotes on a
form which uses php.

The user inputs for example:
I\ve performed many roles including "Figaro",
"Dandini" and 'Wotan'  

becomes:
I\'ve performed many roles including \"Figaro\",
\"Dandini\" and \'Wotan\'

Is there a simple way of getting rid of the annoying
backslash(\) from a the contents of a variable?

Many thanks,

Ian Gray

=

-
Ian A. Gray
Manchester, UK
Telephone: +44 (0) 161 224 1635 - Fax: +44 (0) 870 135 0061 - Mobile: +44 (0) 7900 996 
328
US Fax no.:  707-885-3582
E-mail: [EMAIL PROTECTED] - Websites: www.baritone.uk.com (performance) & 
www.vocalstudio.co.uk (Tuition)
-


__
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com

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