开发者

php script needed to edit simple php pages from a website

开发者 https://www.devze.com 2023-03-28 10:01 出处:网络
I have done a simple website for my client. All pages are php even if some are static and do 开发者_开发百科not have scripts.

I have done a simple website for my client. All pages are php even if some are static and do 开发者_开发百科not have scripts.

My client will have to change the content of pages online. I need a WYSIWYG editor that will allow my client to edit pages [b]BUT without editing the php scripts[/b] that may be included.

I do not need a FULL CMS like joomla, but a simple WYSIWYG online editot that can handle PHP pages.

regards


I've had good success using WordPress. I have PHP scripts embedded on the page that pulls articles from a WordPress database. The user creates content in WordPress, uses tags and categories to control where those articles appear on the site (which page, or which frame within the page). The PHP then uses some simple SQL to pull the content and display.

Update: Here is the tutorial that taught me how: http://codex.wordpress.org/Integrating_WordPress_with_Your_Website

And here is a SO discussion, which leads to the same page: Embedding wordpress into a php page


As much as I hate to say it... depending on your cost/expense/budget thus far, your simplest solution might actually be to go the route of... Contribute (gags a little) but hey it's true.

You could "tag up" your template code relatively easily which would allow them to use Contribute to manage the static content inside your php scripts. Since Contribute is aware of PHP's presence, it should help prevent them from breaking the site by changing things in a text editor or other wysiwyg editor.

The other option I'd suggest would be to go the route of looking into something like TinyMCE editor and building a "wrapper" php script for editing. The wrapper would be given the page to edit, it would then load the page directly via the file system and allow the user to edit the "content blocks" in that page which could be specified via a delimiter/tag you use like .

Those are just a couple "quick fix" options to get you what you want with the minimum amount of rewriting/modification needed.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号