RE: [PHP] html editor written in PHP
Has anyone seen an example of a HTML editor written in PHP (no JS)? You know the ones - for adding HTML tags to a text field, etc. Thanks! You've already received a number of responses indicating that it's not possible to have a pure PHP browser enabled HTML editor, mainly due to the fact that the editing itself takes place on the client (which requires a client-side language, such as JavaScript), while PHP is only run at the server. One lateral solution, however, would be using something like the PHP ports of either the Markdown or Textile classes to provide HTML markup using a simpler syntax. Using Markdown as an example, you would type: _This sentence will be displayed with emphasis_ When you next retrieve this content and pass it through the Markdown class, it automatically becomes: emThis sentence will be displayed with emphasis/em The differences between the two classes is that Textile is more featured, but in my personal opinion less intuitive, while Markdown is obviously less featured, but easier to use 'without thinking about it' as you go about generating content. [1] Both of these classes are used extensively to provide content markup in blogging systems such as MovableType and WordPress, etc. There may be similar classes out there (another one is BBCode, which is popular on forum applications such as Invision PowerBoard). PHP Markdown: http://www.michelf.com/projects/php-markdown/ PHP Textile: http://jimandlissa.com/project/textilephp Hope this helps, Murray [1] Note: which one you might use would depend on how comfortable you are with their applicable syntaxes and how varied your markup needs are. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] html editor written in PHP
PHP is server side. I know this is conventional wisdom, but your answer ignores the fine work being done with PHP-GTK. In this case the PHP executes on the client machine (although not imbedded in a browser), as an application. However I don't know of any Editors that work with PHP-GTK, stay tuned, however. http://gtk.php.net/ Warren Vail -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] html editor written in PHP
I have not seen any and I know that you don't have time to read the replies of everyone who hasn't seen something. So let me tell you why it's most likely that there is not one (PHP HTML editor w/o JS). PHP is server side. Every click of the mouse would have to cause a page to be refreshed (a trip to the server and a trip back to the browser.) JS is client side (it runs in your browser on your computer). all of the editing and tweaking can be done without a trip back to the server. The only time a trip is made to the server is to save the data after the editing is over. Most guys who write code ask themselves Where is the best place to run it? Usually for this type of app the answer is JS client side. Now, there may be a need for server side editors -- in the case of Mac JS not behaving the same way as windows JS. I have a couple of installations of JS CMS which work wonderfully well on windows machine and appear broken on Macs. Mark Cain - Original Message - From: Dustin Krysak [EMAIL PROTECTED] To: PHP php-general@lists.php.net Sent: Wednesday, May 18, 2005 6:02 PM Subject: [PHP] html editor written in PHP Has anyone seen an example of a HTML editor written in PHP (no JS)? You know the ones - for adding HTML tags to a text field, etc. Thanks! d -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] html editor written in PHP
snip Has anyone seen an example of a HTML editor written in PHP (no JS)? You know the ones - for adding HTML tags to a text field, etc. /snip I think what you're asking for is a logical impossibility. PHP is server side, so without javascript a browser-based wysiwyg editor would be impossible, since there would be no client-side functionality to respond to any action by the user. If I'm somehow being incredibly obtuse here and have misconstrued your question, I apologize. However I think that what you're thinking about just isn't possible. Cheers, Pablo -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php