I know its a bit of a tricky question but like the information about the div tag in the html file is actually in the css file, can you do the same with php and mysql?
I know its had dot understand so heres an example!
So you have:
HTML file: <div class="box"></div>
CSS file: .box {height:20px; width: 20px;}
Then speaking of PHP and MYSQL. If I want to display mysql results on a ‘page.php’ can I have a ‘div’ like tag that shows where I want the results to be displayed but have the mysql code actually in another file?
Thanks!
James
That’s certainly a strange way of looking at it.
I think the concise answer is yes, though it is much easier to think of it without any of that html css talk.
Look into something like the smarty template system:
http://www.smarty.net/
for a way to have logic and output in separate files. Mind you I only refer you to smarty because it is a commonly used package and NOT – I repeat – NOT because I approve of the software.
Basic understanding of PHP will easily reveal any number of ways to achieve what you speak of here. It’s pretty simple.