Jump to content

html being saved in custom module's textarea


clickstrum

Recommended Posts

I'm working on a custom module and have only one field which is a text area. I want to be able to add one entry per line. When I save changes, however, the line break html tags, i.e. "<br/>", is saved with it.

 

Here is the textarea in my modulename_config():

 

    "fields" => array(
       "mylist" => array ("FriendlyName" => "My List", "Type" => "textarea", "Rows" => "30", "Cols" => "50", "Description" => "List of items, one per line", "Default" => "", ),
   ));

 

Screenshot:

 

textareascreenshot.PNG

 

Can I have my custom module strip out html before saving? Is there a custom "save" function to use in mymodulename.php? I can't find any docs on supported functions that can be used on the admin side. I've used the addonexample module to get started, but it only shows my activate, deactivate, output, config, and upgrade. Someone point me to some docs? I see some docs for hooks, but not admin functions.

 

Thanks!

Link to comment
Share on other sites

  • 4 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated