Re: [PHP] Fw: help please

2002-11-14 Thread Timothy Hitchens (HiTCHO)
Why not put them into an array then look at array functions such
as unique checking etc...


Timothy Hitchens (HiTCHO)
[EMAIL PROTECTED]


If you need PHP hosting with an experienced
support team 24/7 then email me today.

On Fri, 15 Nov 2002, John Fishworld wrote:

  Hi,

  I've got some variable variables which i need to check that they are not
 the
  same !
  There can be up to 9 of them !

  for ($i = 1; $i = $city_only_one; $i++) {
  $citydb = stellen_city_.$i ;
  $new_city_db.$i = $$citydb;

  and what i need to do is check that
  $new_city_db1 does not equal $new_city_db2 or 3 etc
  and then
  $new_city_db2 does not equal 3 + 4 etc...
   }

  Whats the best way of doing this !??


  Any help 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] FW: Help please!

2002-07-03 Thread joakim . andersson

Hi,

Maybe you can do something like this (if you have access to GD on the
server):
?
$str_image = my_function_to_read_image_from_db($_GET['id']);
$im_old = imagecreatefromstring($str_image);
$im_new = imagecreatetruecolor($_GET['width'], $_GET['height']);
imagecopyresampled($im_new, $im_old, 0, 0, 0, 0, $_GET['width'],
$_GET['height'], imagesx($im_old), imagesy($im_old));
header(Content-type: image/jpeg);
imagejpeg($im_new, '', 90);
?

/Joakim


 -Original Message-
 From: Steve Vernon [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, July 02, 2002 9:43 PM
 To: [EMAIL PROTECTED]
 Subject: [PHP] FW: Help please!
 
 
 Hello,
   I have a PHP script which gets data from a MySQL database and
 returns an image. So img src=getdata.php?id=3 returns the image of
 id 3 from the database. What I really want is to state width 
 is 100 and
 height is 100 for example so I do not have to downlaod the entire
 picture and specify the width and height as part of the image:
   
   Do not want 
   img src=getdata.php?id=3 width=100 height=100
 
   WHat I want
   img src=getdata.php?id=3width=100height=100
 
   WHich will be a lot quicker on the client side.
 
   I cannot make a permanent file to use when I get the information
 from the PHP database due to server security, only a tmpfile which the
 data can then be placed. But to use the image functions you need to
 specify a filename. THere does not seem to be a way to get 
 the filename
 of a file pointer so how do I do it please?
 
   I have asked the ISP to give me permissions to create files int
 he server directory but they will not let me. 
 
   Thanks you!
 
   Steve
 
 
 -- 
 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] FW: Help please!

2002-07-02 Thread Lazor, Ed

Why would it be quicker on the client-side?  I would think you'd go with the
first option.  That way the layout of your web page is maintained while the
image downloads.

-Original Message-
Do not want 
img src=getdata.php?id=3 width=100 height=100

WHat I want
img src=getdata.php?id=3width=100height=100

WHich will be a lot quicker on the client side.

I cannot make a permanent file to use when I get the information
from the PHP database due to server security, only a tmpfile which the
data can then be placed. But to use the image functions you need to
specify a filename. THere does not seem to be a way to get the filename
of a file pointer so how do I do it please?

I have asked the ISP to give me permissions to create files int
he server directory but they will not let me. 

Thanks you!

Steve


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

This message is intended for the sole use of the individual and entity to
whom it is addressed, and may contain information that is privileged,
confidential and exempt from disclosure under applicable law.  If you are
not the intended addressee, nor authorized to receive for the intended
addressee, you are hereby notified that you may not use, copy, disclose or
distribute to anyone the message or any information contained in the
message.  If you have received this message in error, please immediately
advise the sender by reply email and delete the message.  Thank you very
much.   

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




RE: [PHP] FW: Help please!

2002-07-02 Thread Steve Vernon

No, 
I did think of it, but the page may end up with quite a few
pics, and I download of a modem...

Prefer if server has the load...

Steve

|-Original Message-
|From: Lazor, Ed [mailto:[EMAIL PROTECTED]] 
|Sent: 02 July 2002 21:34
|To: '[EMAIL PROTECTED]'; [EMAIL PROTECTED]
|Subject: RE: [PHP] FW: Help please!
|
|
|Why would it be quicker on the client-side?  I would think 
|you'd go with the first option.  That way the layout of your 
|web page is maintained while the image downloads.
|
|-Original Message-
|Do not want
|img src=getdata.php?id=3 width=100 height=100
|
|WHat I want
|img src=getdata.php?id=3width=100height=100
|
|WHich will be a lot quicker on the client side.
|
|   I cannot make a permanent file to use when I get the 
|information from the PHP database due to server security, only 
|a tmpfile which the data can then be placed. But to use the 
|image functions you need to specify a filename. THere does not 
|seem to be a way to get the filename of a file pointer so how 
|do I do it please?
|
|   I have asked the ISP to give me permissions to create 
|files int he server directory but they will not let me. 
|
|   Thanks you!
|
|   Steve
|
|
|-- 
|PHP General Mailing List (http://www.php.net/)
|To unsubscribe, visit: http://www.php.net/unsub.php
| 
|***
|*
|This message is intended for the sole use of the individual 
|and entity to whom it is addressed, and may contain 
|information that is privileged, confidential and exempt from 
|disclosure under applicable law.  If you are not the intended 
|addressee, nor authorized to receive for the intended 
|addressee, you are hereby notified that you may not use, copy, 
|disclose or distribute to anyone the message or any 
|information contained in the message.  If you have received 
|this message in error, please immediately advise the sender by 
|reply email and delete the message.  Thank you very
|much.  
| 
|
|-- 
|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] FW: Help please!

2002-07-02 Thread Lazor, Ed

What load are you talking about?  This is just an issue of telling the web
browser the image's dimensions.  It's not like the image is being processed
to convert it to that image size.

-Original Message-
No, 
I did think of it, but the page may end up with quite a few
pics, and I download of a modem...

Prefer if server has the load...

Steve

|-Original Message-
|From: Lazor, Ed [mailto:[EMAIL PROTECTED]] 
|Sent: 02 July 2002 21:34
|To: '[EMAIL PROTECTED]'; [EMAIL PROTECTED]
|Subject: RE: [PHP] FW: Help please!
|
|
|Why would it be quicker on the client-side?  I would think 
|you'd go with the first option.  That way the layout of your 
|web page is maintained while the image downloads.
|
|-Original Message-
|Do not want
|img src=getdata.php?id=3 width=100 height=100
|
|WHat I want
|img src=getdata.php?id=3width=100height=100
|
|WHich will be a lot quicker on the client side.
|
|   I cannot make a permanent file to use when I get the 
|information from the PHP database due to server security, only 
|a tmpfile which the data can then be placed. But to use the 
|image functions you need to specify a filename. THere does not 
|seem to be a way to get the filename of a file pointer so how 
|do I do it please?
|
|   I have asked the ISP to give me permissions to create 
|files int he server directory but they will not let me. 
|
|   Thanks you!
|
|   Steve
|
|
|-- 
|PHP General Mailing List (http://www.php.net/)
|To unsubscribe, visit: http://www.php.net/unsub.php
| 
|***
|*
|This message is intended for the sole use of the individual 
|and entity to whom it is addressed, and may contain 
|information that is privileged, confidential and exempt from 
|disclosure under applicable law.  If you are not the intended 
|addressee, nor authorized to receive for the intended 
|addressee, you are hereby notified that you may not use, copy, 
|disclose or distribute to anyone the message or any 
|information contained in the message.  If you have received 
|this message in error, please immediately advise the sender by 
|reply email and delete the message.  Thank you very
|much.  
| 
|
|-- 
|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
 

This message is intended for the sole use of the individual and entity to
whom it is addressed, and may contain information that is privileged,
confidential and exempt from disclosure under applicable law.  If you are
not the intended addressee, nor authorized to receive for the intended
addressee, you are hereby notified that you may not use, copy, disclose or
distribute to anyone the message or any information contained in the
message.  If you have received this message in error, please immediately
advise the sender by reply email and delete the message.  Thank you very
much.   

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




RE: [PHP] FW: Help please!

2002-07-02 Thread David Freeman


  id 3 from the database. What I really want is to state width 
  is 100 and height is 100 for example so I do not have to downlaod the
entire
  picture and specify the width and height as part of the image:
   
   Do not want 
   img src=getdata.php?id=3 width=100 height=100
  
   WHat I want
   img src=getdata.php?id=3width=100height=100
  
   WHich will be a lot quicker on the client side.

This won't really change speed on the client side at all - the image is
the size that the image is.  Changing it's display size won't change the
file size.

Having said that, if you're looking to set a standard width and height
for an image loading in a particular location then you could probably
just do this:

  img src=getdata.php?id=3 width=100 height=100

...which should do what you want.  If you actually want the real width
and height of the image then you're probably going to have to do some
pre-processing to work out the width and height first and then include
them in the image tag.

CYA, Dave



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




Re: [PHP] FW: Help please!

2002-07-02 Thread Richard Lynch

What load are you talking about?  This is just an issue of telling the web
browser the image's dimensions.  It's not like the image is being processed
to convert it to that image size.

Au contraire.

If you have an image named 'huge.jpg' at 1 x 1, and you ask a 386
computer to:

IMG SRC=huge.jpg WIDTH=100 HEIGHT=100

Then two horrible things happen.

1. The client has to download that stupidly large image.
2. The client has to *SCALE* that stupdily large image to 100x100

There is no magic here.

That's maybe a lotta work for that client.

-- 
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