I am re-building my site with PHP/mySQL and im not sure how to 'make' it so it is search engine compatible, see below examples:

eg 1


eg 2

will eg 1 be search engine safe? or would i be better off leaving the directory sucture like eg 2?? which way would be my best option?

Thanks in advance!!