| Author |
php and xhtml validation
|
|
| Harris Kosmidhs 2007-05-09, 9:58 pm |
| I converting my html/php pages to xhtml.
Basically I do this at my home/work in linux/windows. So I ran an apache
and edit the pages with crimson editor(win) and bluefish(linux). They
are simple text editors with syntax highlighting.
Now I want to have a validation tool. On line W3C html validation cannot
work because I'm viewing my pages through localhost.
I cannot either upload the page since it cannot parse <?php tags.
So is there a solution to validate php pages which aren't on-line?
thanks
PS I now it's not quite a php question but since people here do write
php somebody must know.
| |
| Roy Kaldung 2007-05-09, 9:58 pm |
| Harris Kosmidhs wrote:
> I converting my html/php pages to xhtml.
> Basically I do this at my home/work in linux/windows. So I ran an apache
> and edit the pages with crimson editor(win) and bluefish(linux). They
> are simple text editors with syntax highlighting.
>
> Now I want to have a validation tool. On line W3C html validation cannot
> work because I'm viewing my pages through localhost.
> I cannot either upload the page since it cannot parse <?php tags.
> So is there a solution to validate php pages which aren't on-line?
>
> thanks
>
> PS I now it's not quite a php question but since people here do write
> php somebody must know.
If you're running Linux, e.g. Debian there is a package called
w3c-markup-validator. It is identical with the validator from W3C. While
running on your host it has still access to localhost.
For Firefox exists an extension which validates pages each time they are
displayed. This extension uses tidy and is only available for windows,
as far as I can remember.
hth,
Roy
| |
| Michael Fesser 2007-05-09, 9:58 pm |
| ..oO(Harris Kosmidhs)
>I converting my html/php pages to xhtml.
Any reason for using XHTML instead of HTML?
>Now I want to have a validation tool. On line W3C html validation cannot
>work because I'm viewing my pages through localhost.
>I cannot either upload the page since it cannot parse <?php tags.
>So is there a solution to validate php pages which aren't on-line?
Use Opera, open a page and press ctrl-alt-v. That's it.
Micha
| |
| Geoff Berrow 2007-05-09, 9:58 pm |
| Message-ID: <3p734313guu089nhc3j6hh81vedi0jm8dd@4ax.com> from Michael
Fesser contained the following:
>.oO(Harris Kosmidhs)
>
>
>Any reason for using XHTML instead of HTML?
Good question.
--
Geoff Berrow 0110001001101100010000000110
0011011010110110010001101111011001110010
11
1001100011011011110010111001110101011010
11
| |
|
|
| Michael Fesser 2007-05-09, 9:58 pm |
| ..oO(Harris Kosmidhs)
>Michael Fesser wrote:
>
>http://www.nypl.org/styleguide/xhtml/benefits.html
All these things can also be done with valid, strict(!) HTML 4.
>Ok my site wasn't html valid also. So I decided to move to xHTML.
Of course it's your decision, but except for some very rare cases
there's not really a reason to use XHTML these days, especially since
the most used browser doesn't support it (IE only accepts HTML-
compatible XHTML, delivered as HTML).
When starting a new project it might be OK to use XHTML, but changing an
existing project is rather pointless. In a few years you would have to
change it all again when XHTML 2.0 will see the light of day ... maybe.
Just my 2 cents.
Micha
| |
| ZeldorBlat 2007-05-09, 9:58 pm |
| On May 9, 5:10 am, Harris Kosmidhs <hkosm...@remove.me.softnet.tuc.gr>
wrote:
> I converting my html/php pages to xhtml.
> Basically I do this at my home/work in linux/windows. So I ran an apache
> and edit the pages with crimson editor(win) and bluefish(linux). They
> are simple text editors with syntax highlighting.
>
> Now I want to have a validation tool. On line W3C html validation cannot
> work because I'm viewing my pages through localhost.
> I cannot either upload the page since it cannot parse <?php tags.
> So is there a solution to validate php pages which aren't on-line?
>
> thanks
>
> PS I now it's not quite a php question but since people here do write
> php somebody must know.
You can view the source of the page and send that to the W3C validator.
| |
| Zvonko Biškup 2007-05-10, 3:58 am |
|
"Harris Kosmidhs" <hkosmidi@remove.me.softnet.tuc.gr> wrote in message
news:f1s35l$ll6$1@volcano1.grnet.gr...
> Now I want to have a validation tool. On line W3C html validation cannot
> work because I'm viewing my pages through localhost.
> I cannot either upload the page since it cannot parse <?php tags.
> So is there a solution to validate php pages which aren't on-line?
You can view source of the page and copy / paste it in validator.
www.velepromet.hr
| |
| Harris Kosmidhs 2007-05-10, 9:58 pm |
| Zvonko Biškup wrote:
> "Harris Kosmidhs" <hkosmidi@remove.me.softnet.tuc.gr> wrote in message
> news:f1s35l$ll6$1@volcano1.grnet.gr...
>
> You can view source of the page and copy / paste it in validator.
>
> www.velepromet.hr
>
>
As someone suggested I used a firefox extension (HTML validator) which
uses tidy. Very nice extension.
The other solutions are a bit frustrating..Since I got the extension I
did that. Reload->view source->copy ->validate. The other is much simpler.
thanks
|
|
|
|