|
|
|
|
||||||
![]() |
|
|
LinkBack | Outils de la discussion |
|
|
#1 |
|
Messages: n/a
Hébergeur: |
Hello
i have a constant define like this define('PHOTOGRAPHY', 'images/photography/'); The outpout (html) should look like this: <img src"images/photography/123.jpg"> How do i insert a constant in an HTML <img> tag. I've try dozens of combinations with no results. Here' part of the code .... <div id="main_image"> <img src="<?php echo $photo_filename; ?>" /> </div> .... thanks |
|
|
|
#2 |
|
Messages: n/a
Hébergeur: |
SM <servandomontero@gmail.com> wrote in news:1194297487.340586.115990
@v23g2000prn.googlegroups.com: > Hello > i have a constant define like this > define('PHOTOGRAPHY', 'images/photography/'); > > The outpout (html) should look like this: > <img src"images/photography/123.jpg"> > > How do i insert a constant in an HTML <img> tag. I've try dozens of > combinations with no results. > Here' part of the code > ... > <div id="main_image"> > <img src="<?php echo $photo_filename; ?>" /> > </div> If you define a constant, you'll certainly need to use it later on, it will not magically appear. <img src="<?php echo PHOTOGRAPHY.$photofilename; ?>" /> |
|
|
|
#3 |
|
Messages: n/a
Hébergeur: |
On Nov 5, 1:18 pm, SM <servandomont...@gmail.com> wrote:
> > i have a constant define like this > define('PHOTOGRAPHY', 'images/photography/'); > > The outpout (html) should look like this: > <img src"images/photography/123.jpg"> You mean, <img src="images/photography/123.jpg">? > How do i insert a constant in an HTML <img> tag. <div id="main_image"> <img src="<?php echo PHOTOGRAPHY, $photo_filename; ?>" /> </div> Cheers, NC |
|
![]() |
| Outils de la discussion | |
|
|