Jump to content

moving page contents to PHP and vice versa


vwinstead

Recommended Posts

On my website I want to make the contents to be editable like they are on wikipedia.org.  I imagine there's about a thousand different ways to accomplish this.  I am going to use FCKeditor for user editing of the page contents. 

 

There will be two parts -

1.  the actual page in HTML

2.  the page showing the text editor with the HTML page contents in it. 

 

The visitor will arrive at the HTML page on my site then press an edit button on the page if they want to change something.  FCKeditor will display whatever text I want, so I want to pass in the contents of the html page to the editor.  So the problem is this:  How do I easily send all my relevant page contents to the PHP page for editing?  I was thinking of just assigning all the page contents to a variable and then just sending that variable to the PHP page.  But I'm not sure yet if I can do that or if it's the best way to go about it. 

 

Any suggestions?

You need to store your page contents in a database (like wikipedia). From there you can pull the data into a textarea (or FCKEditor) ,edit it and save it back to the database.

 

You can also easily display your data from the database within a html enabled template.

 

This is one of the most common tasks php is used for.

You need to store your page contents in a database (like wikipedia). From there you can pull the data into a textarea (or FCKEditor) ,edit it and save it back to the database.

 

You can also easily display your data from the database within a html enabled template.

 

This is one of the most common tasks php is used for.

 

I was thinking that a good way to accomplish this is with a database (like mySQL).  But I've never personally made changes to the mySQL database provided by my hosting site.  I've only used the Fantastico scripts supplied by the site to auto-config the database for specific applications.  Where would you suggest starting if I want to go down this road of using the database for displaying dynamic content? 

Sounds to me like you might have a bit to learn. Theres a book in my signiture (Hudzilla) that covers using forms and databases within php. That'd probably get you started.

 

Yes - I have a lot to learn, but I'm used to that.  And I'm good at it.  ;)  Thanks for the input!

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.