Page 1 of 1

Using $PHP_SELF based code

Posted: Mon Aug 29, 2005 5:49 pm
by MjK
I only started using CMSms about 4 days ago, but i need to do this:

I have a database (DVD collection) and want to integrate is into the website. At the moment it's a PHP/HTML combo page build up from to pages: a start page displaying the different options (film, docu, music, etc) and the number of DVDs in the table.
Clicking the link you go to the overview page (this makes the right overview with ?section from the start page). The overview page is using $PHP_SELF alot. For sorting, for breaking up the page in more indexes, etc.

I already wanted to start making this a complete PHP page thing, and think i realy need to do this if i want the database to work in CMSms. But how do i start and hw do i send attributes to a page and to itself. Is this the same as normal PHP pages, just a matter of making a user-defined tag and then calling it with the right attributes??

The same thing goes for a very flat but working Photo album i made, but this also uses an include, for a config.php for settings. I'm thinking of cleaning this one up to be used by others as well, after i made it completly code based.

Re: Using $PHP_SELF based code

Posted: Mon Aug 29, 2005 5:54 pm
by Ted
To be honest, I think you need to look into creating modules.  They allow you to do all kinds of navigation and other things you'd need to have it completely integrated into CMSMS.

I would start with the couple of the articles on the wiki and the Skeleton module on http://cmsmodules.com

Re: Using $PHP_SELF based code

Posted: Mon Aug 29, 2005 6:01 pm
by MjK
Making my own module, i was reading the wiki and posted to try and avoid making a module, but what the hack. Let's have a go at it.
Are there more people that want to add something like a DVD collection?
I think it could be made less specific. But than i could use some help. As i am using CMSms for just a minimum of time, i'm also just starting with PHP.

How about including stuff?? i want the connection and settings variables to be in a different file.


Want to see the current DVD collection?

http://www.lunding.nl/dvd/dvd.php

It would be handy if you speek dutch, but you can do nothing wrong for as far as i know.