Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-10 Thread Sashikanth Gurram
haliphax wrote: On Mon, Mar 9, 2009 at 8:43 PM, Sashikanth Gurram wrote: Is there any way in which I can assign a variable to a query string? Like for example, Let us say that there are two php files a.php and b.php. I am currently using a image tag like in a.php and am passing the value to

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-10 Thread haliphax
On Mon, Mar 9, 2009 at 8:43 PM, Sashikanth Gurram wrote: >>> Is there any way in which I can assign a variable to a query string? >>> Like for example, Let us say that there are two php files a.php and >>> b.php. I am currently using a image tag like >> src="imgtest.php?id=Williams Hall" /> in a.p

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Sashikanth Gurram
Thanks Shawn and Dollah -Sashi Shawn McKenzie wrote: Sashikanth Gurram wrote: haliphax wrote: On Mon, Mar 9, 2009 at 10:52 AM, Sashikanth Gurram wrote: haliphax wrote: On Mon, Mar 9, 2009 at 10:24 AM, Sashikanth Gurram wrote: Nathan Nobbe wr

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Sashikanth Gurram
Hi, Worked perfectly. Thank you very much. -Sashi Dollah Ihsan wrote: Hi, you are using single quotes like this? echo ' '; single quotes will ignore that "$building" variable. Just concatenate it: echo '"; It should work I think, sorry if it does not. On Tue, Mar 10, 2009 at 8:14 AM, Sas

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Shawn McKenzie
Sashikanth Gurram wrote: > haliphax wrote: >> On Mon, Mar 9, 2009 at 10:52 AM, Sashikanth Gurram >> wrote: >> >>> haliphax wrote: >>> On Mon, Mar 9, 2009 at 10:24 AM, Sashikanth Gurram wrote: > Nathan Nobbe wrote: > > >> On Mon, Mar 9, 2009

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Sashikanth Gurram
haliphax wrote: On Mon, Mar 9, 2009 at 10:52 AM, Sashikanth Gurram wrote: haliphax wrote: On Mon, Mar 9, 2009 at 10:24 AM, Sashikanth Gurram wrote: Nathan Nobbe wrote: On Mon, Mar 9, 2009 at 7:32 AM, Sashikanth Gurram mailto:sashi...@vt.edu>> wrote: Hi, Yes,

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread haliphax
On Mon, Mar 9, 2009 at 10:52 AM, Sashikanth Gurram wrote: > haliphax wrote: >> >> On Mon, Mar 9, 2009 at 10:24 AM, Sashikanth Gurram >> wrote: >> >>> >>> Nathan Nobbe wrote: >>> On Mon, Mar 9, 2009 at 7:32 AM, Sashikanth Gurram >>> > wrote:   Hi, >

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Sashikanth Gurram
Thanks a lot everyone, particularly Haliphax, Nathan, Virgilio and Bob. I will try it and will come back to you. Thanks, Sashi haliphax wrote: On Mon, Mar 9, 2009 at 10:24 AM, Sashikanth Gurram wrote: Nathan Nobbe wrote: On Mon, Mar 9, 2009 at 7:32 AM, Sashikanth Gurram mailto:sashi

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread haliphax
On Mon, Mar 9, 2009 at 10:24 AM, Sashikanth Gurram wrote: > Nathan Nobbe wrote: >> >> >> On Mon, Mar 9, 2009 at 7:32 AM, Sashikanth Gurram > > wrote: >> >>    Hi, >> >>    Yes, the problem was solved, but It did not work fine when I used >>    the same code in my larger fil

RE: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Bob McConnell
From: Sashikanth Gurram > > Hi, > Thanks a lot for all the patient replies. All the suggestions led me in > a positive direction. Finally, instead of using the header() in my main > PHP file (with HTML tags), I have used it in a secondary file and called > it using a tag. It is working fine. B

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Sashikanth Gurram
Hi, Thanks a lot for all the patient replies. All the suggestions led me in a positive direction. Finally, instead of using the header() in my main PHP file (with HTML tags), I have used it in a secondary file and called it using a tag. It is working fine. But, the image I need to display is

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Nathan Nobbe
On Mon, Mar 9, 2009 at 7:32 AM, Sashikanth Gurram wrote: > Hi, > > Yes, the problem was solved, but It did not work fine when I used the same > code in my larger file. Now it makes sense. right, just track down where you started sending the output, and remember if youre going to use header() ca

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread haliphax
On Mon, Mar 9, 2009 at 9:32 AM, Sashikanth Gurram wrote: >> On Mon, Mar 9, 2009 at 1:29 AM, Sashikanth Gurram wrote: >> >>> >>> Hi Nathan, >>> >>> Thanks a lot for the suggestion. It is working fine for an example code I >>> have used to test it. The code I have written after your suggestion is a

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Virgilio Quilario
> I am using a WAMP server for my coding purposes. My MySQL Version is > 5.0.51b, PHP version is 5.2.6 and Apache version is 2.2.8 > > I have created a database with one of the tables containing a location of > the image. Using PHP I am trying to retrieve the location of the image (from > the mysql

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Sashikanth Gurram
Hi, Yes, the problem was solved, but It did not work fine when I used the same code in my larger file. Now it makes sense. Let me just repeat what you have said just to make sure that I did not misread you. So you say that the solution to this problem is to create another php file with the ima

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Nathan Nobbe
On Sun, Mar 8, 2009 at 11:29 PM, Sashikanth Gurram wrote: > Hi Nathan, > > Thanks a lot for the suggestion. It is working fine for an example code I > have used to test it. The code I have written after your suggestion is as > follows. > $location="C:\wamp\bin\apache\apache2.2.8\htdocs\Bldgs_lot

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread haliphax
On Mon, Mar 9, 2009 at 1:29 AM, Sashikanth Gurram wrote: > Hi Nathan, > > Thanks a lot for the suggestion. It is working fine for an example code I > have used to test it. The code I have written after your suggestion is as > follows. > $location="C:\wamp\bin\apache\apache2.2.8\htdocs\Bldgs_lots\

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Sashikanth Gurram
Hi Nathan, Thanks a lot for the suggestion. It is working fine for an example code I have used to test it. The code I have written after your suggestion is as follows. The above code is yielding me a picture. Now, When I tried to use it in my original code it is not giving me the image. Inst

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-09 Thread Sashikanth Gurram
Hi Nathan, Thanks a lot for the suggestion. It is working fine for an example code I have used to test it. The code I have written after your suggestion is as follows. The above code is yielding me a picture. Now, When I tried to use it in my original code it is not giving me the image. Inst

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-07 Thread Nathan Nobbe
On Sat, Mar 7, 2009 at 9:36 PM, Sashikanth Gurram wrote: > The thing is, I do not have a website or a place where I am storing my > images. I am storing the images on my local PC in folder as mentioned in my > earlier post. I have tried using only the > > else { > header('Content-Type: image/jpeg

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-07 Thread Sashikanth Gurram
The thing is, I do not have a website or a place where I am storing my images. I am storing the images on my local PC in folder as mentioned in my earlier post. I have tried using only the else { header('Content-Type: image/jpeg'); imagejpeg($img); imagedestroy($img); } Which you have suggeste

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-07 Thread Nathan Nobbe
On Sat, Mar 7, 2009 at 8:12 PM, Sashikanth Gurram wrote: > I am just storing the location of the image(as a varchar type), not the > image itself. For example for a particular image, the location is stored as > C:\wamp\bin\apache\apache2.2.8\htdocs\Bldgs_lots\Burruss.jpg > echo "\n"; $err=1; if

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-07 Thread Sashikanth Gurram
I am just storing the location of the image(as a varchar type), not the image itself. For example for a particular image, the location is stored as C:\wamp\bin\apache\apache2.2.8\htdocs\Bldgs_lots\Burruss.jpg -sashi Nathan Nobbe wrote: On Sat, Mar 7, 2009 at 7:10 PM, Sashikanth Gurram

Re: [PHP] Retrieving Image Location in PHP from MySQL

2009-03-07 Thread Nathan Nobbe
On Sat, Mar 7, 2009 at 7:10 PM, Sashikanth Gurram wrote: > Hello everyone, > > I am using a WAMP server for my coding purposes. My MySQL Version is > 5.0.51b, PHP version is 5.2.6 and Apache version is 2.2.8 > > I have created a database with one of the tables containing a location of > the image