Jump to content

Dynamic Update Page


MinusMyThoughts

Recommended Posts

so this is my first post on this forum, and also my first attempt at programming with PHP, so go easy on me. :)i have a compound problem: 1) i'm looking for tips or a tutorial on building a news or blog posting code, and 2) i want to have a dynamic update page for the site that i'm building where the user will see a drop down box containing the names of all the pages (news, about, services, etc.). when the user selects news, i want to create the title and text box for the news entry with a submit button, and when they select services, i want it to create a text box, image link box, and a title box.i looked around for a while and only found tutorials on drop boxes populating drop boxes, so any help will be HUGELY appreciated...thanks!jason

Link to comment
Share on other sites

Hmmm I know what you want, but you'll have to be patient as I (and others) will need some time to come up with an adequate response. Have you looked into free content management systems?

Link to comment
Share on other sites

Have you looked into free content management systems?
i've seen them, but i work as a part-time web designer. if i use a free content management system and then charge someone for it, isn't that illegal?Jason
Link to comment
Share on other sites

It's not illegal. You can't simply take an open source product and turn around and resell it, but if you integrate an open source application into your own application, you can definately charge for your time and labor, in addition to the things you write yourself.For creating fields dynamically, you will need to use javascript. Have a container div with an ID on it, like this:<div id="container"></div>And then you can have your dropdown call a function to update the div based on what they chose. So the function would use the innerHTML property to add content to the container div.

document.getElementById("container").innerHTML = "<input type=\"text\" name=\"something\"> <br> <textarea ...></textarea> <br> <input type=\"submit\">";

etc

Link to comment
Share on other sites

i've seen them, but i work as a part-time web designer. if i use a free content management system and then charge someone for it, isn't that illegal?Jason
If you charge someone for downloading that code, yes, that's illegal. But say you're running a business that sells computers and you use say, PHP-Nuke to keep track of your users etc. Because you're selling a product, effectively the "content" and not the open-source code for PHP-Nuke, then you're in the all-clear. Just be sure your "computers" aren't illegal themselves!
Link to comment
Share on other sites

You can integrate it into your own product and charge for the whole thing. But, if you use an open source application in your work, then you too need to make your source code available, generally. It depends on which license the application you are using is licensed under.

Link to comment
Share on other sites

thanks so much for all your help, guys!any recommendations for content management systems? ultimately i'd like to build one, just so i'll understand exactly what's happening, but for my current project the smart thing is probably to get it up and running, rather than sitting on it another few weeks while i hack away at a new programming language...thanks again!jason

Link to comment
Share on other sites

thanks so much for all your help, guys!any recommendations for content management systems? ultimately i'd like to build one, just so i'll understand exactly what's happening, but for my current project the smart thing is probably to get it up and running, rather than sitting on it another few weeks while i hack away at a new programming language...thanks again!jason
PHP Nuke, maybe? It's pretty popular from my POV.
Link to comment
Share on other sites

For a content management system a decent amount of time will be needed to go into it.You will need:-Mysql, and a database for every site-A way to populate the dropdown-A way to update the site info-A bunch of other things :)That should get you started!

Link to comment
Share on other sites

For a content management system a decent amount of time will be needed to go into it.You will need:-Mysql, and a database for every site-A way to populate the dropdown-A way to update the site info-A bunch of other things :)That should get you started!
Something to consider (especially if this is only for your personal use) is designing your CMS to have multiple sites in only one database and to run on the same code. Once you start creating databases and copy and pasting hte code to a new folder for each new site it becomes hard to manage.Lets imagine you at some point to have 10 sites running off this application you create. You then have 10 databases and 10 sets of the same code. Now you find some bugs or want to add a new feature...you have to modify 10 databases and 10 sets of code.Lets say your application becomes popular and you start your own company and have 50 sites running, etc, etc....do you really want to be modifing multiple databases and sets of code???
Link to comment
Share on other sites

ohhh, I thought he meant he was going to sell it to people.If you arent, then you might want to have a "domain" or "site" column with the site url, sitename.com then you can do what aspnetguy said.

Link to comment
Share on other sites

ohhh, I thought he meant he was going to sell it to people.If you arent, then you might want to have a "domain" or "site" column with the site url, sitename.com then you can do what aspnetguy said.
He may be I haven't been following this topic but just thought it would be good to mention this.Even if you are selling it, having the ability to host multiple sites on one DB and set of code will make your application more attractive.Where I work we developed a CMS for our internal websites then decided to market it. We don't sell the source code but sell it as a service. We host it for a monthly fee. Everything runs off one SQL Server database and one set of C# code.
Link to comment
Share on other sites

He may be I haven't been following this topic but just thought it would be good to mention this.Even if you are selling it, having the ability to host multiple sites on one DB and set of code will make your application more attractive.Where I work we developed a CMS for our internal websites then decided to market it. We don't sell the source code but sell it as a service. We host it for a monthly fee. Everything runs off one SQL Server database and one set of C# code.
you guys have been a great help. i'll definitely try to run it all off one DB and set of code. when i get there, i'm just guessing i'll be back for some pointers. :)...thanks again, guys!jason
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...