Main Stories
Slash Boxes

Slash Open Source Project

Slashcode Log In

Log In

[ Create a new account ]

Article Poll

Poll I found this article to be
Very Helpful
Helpful
Not Helpful
Not Very Helpful
[ Results | Polls ]
Comments:0 | Votes:0

Formating types (html, text, etc) in Submissions

posted by Krow on 05:04 AM June 14th, 2002   Printer-friendly   Email story
I've been developing a slash site (westbloomfieldtwp.com) to discuss local politics and events, and I've been adapting it for the less technicly inclined. One thing I'd like to do is have the different formatting optinons (html, plain text, extrans, code) when one is submitting a story. There is already this option when submitting comments. This way, the default could be verbatim text so that people arn't surprised if their comment has angle brackets or they do anything important with paragraphs. Is there any way this can be easily done?
This discussion has been archived. No new comments can be posted.
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login
Loading... please wait.
  • I think what would also be cool would be a story more box so users could submit longer stories. On my site sometimes I often get user submissions like this one [ckfonline.org] that coe out a mess and require quite a bit of formatting before publishing.

    On a side note; I see that on /. the book reviews submission has some really nice additional fields to it. Are those fields stored in the db seperately or are you taking the user form data, formatting it and then publish as a normal story? Is that custom for /. or is that available in the 2.x series?

    Peace,
    Sandor
    • That feature is available (I think) in the 2.2.5 release but there is no interface to it until you get into CVS.
      It is a actually a pretty handy little feature which is slowly been exteneded to drop downs and other forms of input.
      --

      --
      You can't grep a dead tree.
  • by Anonymous Coward
    2.0.0 slash

    -take submit.pl and copy it to submit2.pl

    -then copy every template used by submit.pl and have it use submit2.pl

    -edit submit2.pl and replace both instances of strip_html with strip_plaintext (idea crtsy of Micah Yoder)

    You would have two links for story submissions - plain text and HTMLified.

    Don't forget to restart apache to allow your new templates to work.