Reply to Re: Echo filename in <title>

Your name:

Reply:


Posted by Steve on 09/25/07 03:33

"macca" <ptmcnally@googlemail.com> wrote in message
news:1190679385.207430.268930@r29g2000hsg.googlegroups.com...
> >From the original post:
>
> Basically, I want to use the filename of a web page
> within the <title> tags in the page <head>.
> <snip>
> So I just need PHP to look
> up the filename without the extension, capitalize the first letter,
> and then have the ability to call it within <title>.
>
>
> My function soes exactly what he asked for.

only if that file name has an extension. follow the logic...just because he
says 'without the extension', it certainly does not mean that all of his
files *have* extensions. you do not have enough information to assume
anything else correctly. also, your function doesn't account for sym-links -
a lot of which DON'T have extensions...by choice.

anyway, say what you want. i just know that if you try and throw a wrench
(an exception to the rule) at what i wrote, my example will still work.
notice that i also ucwords()...since i think about the result he wants
rather than just the details he provides. i'd hate to have to go in and
modify this thing the first time someone named a file 'free pictures.php'.
good thing i wouldn't have to.

;^)

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация