Re: [PHP] Encoding for W3C Validation

2010-08-04 Thread Carlton Whitehead
That is definitely calling out for a loop. When I scan down the lines of code, the only part I see changing is the x after $pic_x. You could make an array with all of the picture details and then replace all of that repeated code with a loop like so: $pics = array('my_first_picture.jpg',

Re: [PHP] Encoding for W3C Validation

2010-08-04 Thread Richard Quadling
On 4 August 2010 13:33, Carlton Whitehead carlton.whiteh...@gmail.com wrote: That is definitely calling out for a loop. When I scan down the lines of code, the only part I see changing is the x after $pic_x. You could make an array with all of the picture details and then replace all of that

[PHP] Encoding for W3C Validation

2010-08-03 Thread Rick Dwyer
Hello List. In the Alt section of the IMG tag below, the variable $myitem has a value of Who's There. echo div class='myclass'a href='#' class='color_thumb' img src='/itemimages/$mypic' alt='$myitem' width='60' When running through W3C validator, the line errors out because of the ' in

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Sebastian Ewert
Rick Dwyer wrote: Hello List. In the Alt section of the IMG tag below, the variable $myitem has a value of Who's There. echo div class='myclass'a href='#' class='color_thumb' img src='/itemimages/$mypic' alt='$myitem' width='60' When running through W3C validator, the line

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Ashley Sheridan
On Tue, 2010-08-03 at 14:41 -0400, Rick Dwyer wrote: Hello List. In the Alt section of the IMG tag below, the variable $myitem has a value of Who's There. echo div class='myclass'a href='#' class='color_thumb' img src='/itemimages/$mypic' alt='$myitem' width='60' When running

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Shreyas Agasthya
Rick, Probably Sebastian's fix might work but *htmlspecialchars* can help you, too. Regards, Shreyas On Wed, Aug 4, 2010 at 12:17 AM, Sebastian Ewert seb2...@yahoo.de wrote: Rick Dwyer wrote: Hello List. In the Alt section of the IMG tag below, the variable $myitem has a value of

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Rick Dwyer
On Aug 3, 2010, at 2:47 PM, Sebastian Ewert wrote: Rick Dwyer wrote: Hello List. In the Alt section of the IMG tag below, the variable $myitem has a value of Who's There. echo div class='myclass'a href='#' class='color_thumb' img src='/itemimages/$mypic' alt='$myitem' width='60'

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Ashley Sheridan
On Tue, 2010-08-03 at 15:00 -0400, Rick Dwyer wrote: On Aug 3, 2010, at 2:47 PM, Sebastian Ewert wrote: Rick Dwyer wrote: Hello List. In the Alt section of the IMG tag below, the variable $myitem has a value of Who's There. echo div class='myclass'a href='#'

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Rick Dwyer
Thanks Ash... this worked. --Rick On Aug 3, 2010, at 3:01 PM, Ashley Sheridan wrote: On Tue, 2010-08-03 at 15:00 -0400, Rick Dwyer wrote: On Aug 3, 2010, at 2:47 PM, Sebastian Ewert wrote: Rick Dwyer wrote: Hello List. In the Alt section of the IMG tag below, the variable $myitem has

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Sebastian Ewert
Ashley Sheridan wrote: On Tue, 2010-08-03 at 15:00 -0400, Rick Dwyer wrote: On Aug 3, 2010, at 2:47 PM, Sebastian Ewert wrote: Rick Dwyer wrote: Hello List. In the Alt section of the IMG tag below, the variable $myitem has a value of Who's There. echo div class='myclass'a href='#'

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Rick Dwyer
On Aug 3, 2010, at 3:15 PM, Sebastian Ewert wrote: Ashley Sheridan wrote: On Tue, 2010-08-03 at 15:00 -0400, Rick Dwyer wrote: On Aug 3, 2010, at 2:47 PM, Sebastian Ewert wrote: Rick Dwyer wrote: Hello List. In the Alt section of the IMG tag below, the variable $myitem has a value

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Ashley Sheridan
On Tue, 2010-08-03 at 15:32 -0400, Rick Dwyer wrote: On Aug 3, 2010, at 3:15 PM, Sebastian Ewert wrote: Ashley Sheridan wrote: On Tue, 2010-08-03 at 15:00 -0400, Rick Dwyer wrote: On Aug 3, 2010, at 2:47 PM, Sebastian Ewert wrote: Rick Dwyer wrote: Hello List. In the Alt

Re: [PHP] Encoding for W3C Validation

2010-08-03 Thread Rick Dwyer
On Aug 3, 2010, at 3:36 PM, Ashley Sheridan wrote: On Tue, 2010-08-03 at 15:32 -0400, Rick Dwyer wrote: On Aug 3, 2010, at 3:15 PM, Sebastian Ewert wrote: Ashley Sheridan wrote: On Tue, 2010-08-03 at 15:00 -0400, Rick Dwyer wrote: On Aug 3, 2010, at 2:47 PM, Sebastian Ewert wrote: