Jump to content

php file strcture design


mavera2

Recommended Posts

I have a php file, call it "mypage.php"

it makes come calculations, create 5 different arrays,

and creates a table by using the arrays.

 

I found simpleXML to create XMLs easily.

I want to make an xml file by using the contents of mypage.php.

 

I want to do that with an argument like that "mypage?type=xml"

I'm aware that i should use "$_GET" or "$_POST"

But where should i put the php code in page,

so when i use argument "xml" it will create an xml file.

When i don't give argument it will create an html type file.

 

Or should i use another php that includes mypage.php??

And get arrays from that file?

 

Thank you.

 

 

 

 

Link to comment
https://forums.phpfreaks.com/topic/246651-php-file-strcture-design/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.