Visual Editor > not correct xhtml

This topic is: not resolved

This topic contains 11 replies, has 7 voices, and was last updated by  sc0ttkclark 2 years, 8 months ago.

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #160859

    sc0ttkclark
    Keymaster
    Post count: 803

    Try referencing this for a fix:

    http://pods.uproot.us/forums/general-discussion/222

    #160860

    kaiiser
    Member

    hi scott,

    no. i´m not hard-coding anything into core due to the update-stuff. currently i´m trying to preg_replace the whole stuff. my only problem is, that i don´t know how to bring < and > into preg_replace… (have the same problem at the menu too). i´m no php-genius. i´m normally just doing graphic and css-stuff. so: sry for all my questions. i´m trying to solve as many as possible myself, but < and > is just too much into detail. maybe you can lend a helping hand.

    ps. i think i pushed the other thread much too far into a visual editor discussion, so i think this should stay here for doc purpose.

    #160861

    logikal16
    Member

    The <br /> fix will be released along with 1.7.9.

    #160862

    onwardonward
    Member

    I’m using version 1.8.1 and the problem still seems to be there, I’ve got <br> tags all over the place and hardly any of my content will validate as xhtml. What can be done?

    #160863

    logikal16
    Member

    Re-download nicEdit (http://nicedit.com/download.php) with the nicXHTML component compiled into it.

    #160864

    onwardonward
    Member

    Thanks, I didn’t know that was there. However since I installed that the menu bar on the editor doesn’t work. I noticed there was a link to iconPath in the js file but even when I put the gif file in the correct place the menu bar still doesn’t seem to want to work … I will investigate.

    #160858

    kaiiser
    Member

    hi,

    i just took a look at my db and found the visual editor adding <br> at the end of every text i add (without hitting [enter] at the end of the text. that´s not appreciated and maybe could be avoided through a filter, but there´s a second problem: xhtml must have closed tags: <br /> instead of <br>.

    #160865

    dennisimo
    Member

    I have tried following all of the advice in this post and in http://pods.uproot.us/forums/general-discussion/222

    Could someone please post a decent pre-save helper for removing all instances of "<br>" before the content is saved to the database?

    #160866

    WallabyKid
    Member
    Post count: 8

    I too have tried everything mentioned in all threads related to invalid xhtml generated via nicEdit, with NO LUCK AT ALL!
    As holding your breath for a pods release employing tinyMCE is likely to make you blue… I have opted for the following work around.
    1. add the following to functions.php in your theme
    <pre>
    function tidyNicEdit($html)
    { $config = array(
    ‘clean’=> true,
    ‘drop-proprietary-attributes’ => true,
    ‘output-xhtml’ => true,
    ‘show-body-only’=>true,
    ‘word-2000′ => true,
    ‘wrap’ => ’0′
    );
    $tidy = new tidy();
    $tidy->parseString($html, $config, ‘utf8′);
    $tidy->cleanRepair();
    return tidy_get_output($tidy);
    }
    </pre>
    2. call your desc fields as follows:
    <pre>
    $description = tidyNicEdit($my_pod->get_field(‘description’));
    </pre>

    …and that seems to do the trick.

    #160867

    dashaluna
    Member

    Hello everyone,

    I’m using Pods 1.9.1 and it’s still the case of broken

    tags. Seems like people recommending to switch to TinyMCE editor, but I can’t find any instructions how to do that. Would really appreciate if someone could point me to the right direction.

    Thank you

    #160868

    dashaluna
    Member

    I just came across this Input Helper "TinyMCE for Paragraph Text" by jonathandchr. It worked like a charm for me all html is clean. Hope this helps someone too.

    http://podscms.org/packages/tinymce-for-paragraph-text/

    Steps/Tutorial:

    http://mondaybynoon.com/2010/03/30/upgrading-pods-to-use-tinymce-instead-of-nicedit/

    #160869

    sc0ttkclark
    Keymaster
    Post count: 803

    Actually that package has been replaced with a more full version: http://podscms.org/packages/tinymce-for-pods/

Viewing 12 posts - 1 through 12 (of 12 total)

You must be logged in to reply to this topic.

Wordpress Cloud Hosting