From: Shaun M. <sh...@ae...> - 2005-02-03 07:03:17
|
Over the last few days I've been working with a site with lots of html in blocks, announcements and page sections and I've been occasionally coming up against phpWebSite's insistence or not of converting breaks/linefeeds to <br /> tags. It's most annoying in forms and tables. In textsettings.php you can switch it off, but it's still handy for users so they don't have to type html so that's not an option really. Is there a middle way? Is was wondering what the effect would be of allowing a SMART setting which checked the content for tags such as the ones in $allowed_tags and then if found, switched off the conversion? It should be a fairly simple change in the core but I was wondering if it was that simple, had I overlooked something. ;-) |
From: Matthew M. <ma...@tu...> - 2005-02-03 13:29:04
|
Oh now you are just looking for stuff to complain about ;^) > Is there a middle way? > > Is was wondering what the effect would be of allowing a SMART setting which checked the > content for tags such as the ones in $allowed_tags and then if found, switched off the > conversion? So if you enter <nobreaks> none will be added? If the other devs like that I see no problem with adding it. Just decide on the tag name and format. -- Matthew McNaney Electronic Student Services Appalachian State University http://phpwebsite.appstate.edu |
From: Shaun M. <sh...@ae...> - 2005-02-03 14:42:30
|
On 3 Feb 2005, at 13:24, Matthew McNaney wrote: > Oh now you are just looking for stuff to complain about ;^) > Don't get me started on my end of year tax return... >> Is there a middle way? >> >> Is was wondering what the effect would be of allowing a SMART setting >> which checked the >> content for tags such as the ones in $allowed_tags and then if found, >> switched off the >> conversion? > > So if you enter <nobreaks> none will be added? If the other devs like > that I see no problem with adding it. Just decide on the tag name and > format. Does it need an extra tag? I was thinking more that the textsettings.php $add_breaks was a three state thing and the parseOutput function grep-ed for the allowed_tags rather than a new one but maybe it'd screw up the displays of old content already in the database. We don't store the converted output with the added <br /> in the database do we? Shaun aegis design - http://www.aegisdesign.co.uk |
From: Wendall C. <wen...@to...> - 2005-02-03 15:33:08
|
I just ran into this as well. It is really nice to have the breaks added when just adding a block of plain text in a browser. However, when adding a block of pre-formatted html it is quite annoying to have the breaks added. I would opt for some type of marker at the head like <nobreaks> or {nobreaks} on the first line to signify no breaks. Reason is that I may have a plain block of text that I want to have a word bolded or in italics. This would unexpectedly break the breaker functionality. On a similar subject. I'd like to see <strong> and <em> added to the default allowed tags list in textsettings.php. They have been the w3c recommendation for bold and italics for a good ten years now. Wendall On Thu, 2005-02-03 at 14:42 +0000, Shaun Murray wrote: > On 3 Feb 2005, at 13:24, Matthew McNaney wrote: > > > Oh now you are just looking for stuff to complain about ;^) > > > > Don't get me started on my end of year tax return... > > >> Is there a middle way? > >> > >> Is was wondering what the effect would be of allowing a SMART setting > >> which checked the > >> content for tags such as the ones in $allowed_tags and then if found, > >> switched off the > >> conversion? > > > > So if you enter <nobreaks> none will be added? If the other devs like > > that I see no problem with adding it. Just decide on the tag name and > > format. > > Does it need an extra tag? > > I was thinking more that the textsettings.php $add_breaks was a three > state thing and the parseOutput function grep-ed for the allowed_tags > rather than a new one but maybe it'd screw up the displays of old > content already in the database. We don't store the converted output > with the added <br /> in the database do we? > > > > Shaun > aegis design - http://www.aegisdesign.co.uk > > > > ------------------------------------------------------- > This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting > Tool for open source databases. Create drag-&-drop reports. Save time > by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. > Download a FREE copy at http://www.intelliview.com/go/osdn_nl > _______________________________________________ > Phpwebsite-developers mailing list > Php...@li... > https://lists.sourceforge.net/lists/listinfo/phpwebsite-developers |
From: Matthew M. <ma...@tu...> - 2005-02-03 15:34:19
|
> I was thinking more that the textsettings.php $add_breaks was a three > state thing and the parseOutput function grep-ed for the allowed_tags > rather than a new one but maybe it'd screw up the displays of old > content already in the database. We don't store the converted output > with the added <br /> in the database do we? No we don't store the <br /> but I don't understand how you propose to disable the process on an individual basis. -- Matthew McNaney Electronic Student Services Appalachian State University http://phpwebsite.appstate.edu |
From: Mike N. <mh...@us...> - 2005-02-03 17:54:33
|
On Wed, 2005-02-02 at 23:03, Shaun Murray wrote: > Over the last few days I've been working with a site with lots of html in blocks, > announcements and page sections and I've been occasionally coming up against > phpWebSite's insistence or not of converting breaks/linefeeds to <br /> tags. It's most > annoying in forms and tables. > > In textsettings.php you can switch it off, but it's still handy for users so they don't have to > type html so that's not an option really. > > Is there a middle way? Shaun, What about a wiki parse. Don and I discussed a global setting available to Deity for selecting default parse between: text, bbcode, wiki, and xhtml. If someone wanted to get fancy, multiple options could be made available on edit. This way input would be parsed properly according to the desires of the website deity and target users. The only issue I see with this is how the back-end (database) store is defined. I know bbcode is already available, but I'm not familiar with the specifics. -- Mike Noyes <mhnoyes at users.sourceforge.net> http://sourceforge.net/users/mhnoyes/ SF.net Projects: ffl, leaf, phpwebsite, phpwebsite-comm, sitedocs |
From: Shaun M. <sh...@ae...> - 2005-02-03 19:43:29
|
On 3 Feb 2005, at 18:00, Mike Noyes wrote: > Shaun, > What about a wiki parse. Don and I discussed a global setting available > to Deity for selecting default parse between: text, bbcode, wiki, and > xhtml. If someone wanted to get fancy, multiple options could be made > available on edit. > Yep. Why not. > This way input would be parsed properly according to the desires of the > website deity and target users. > Yep. That would be useful too so a deity could use full unfiltered HTML, admin users filtered HTML and users just BBcode/text or wiki. > The only issue I see with this is how the back-end (database) store is > defined. Well that's the problem. Currently, there's no way of indicating to phpWebsite what the user has intended when they input the text so it does a half conversion converting breaks to br tags. The problem is, it also converts breaks inside other bits of html adding them where they weren't needed. Hence the SMART option I was thinking about which switched off the current break handling if it found there was html in the input already. Most other CMS let you specify which it is when you write it and third party blogging tools like Ecto and MarsEdit let you specify too although can do some conversion before uploading it to your blog to store it as HTML so that even though you may write in plain text, it stores as HTML. > I know bbcode is already available, but I'm not familiar with > the specifics. > The BBCode filter coexists with the html parser as it's tags are extra so don't interfere with HTML. A wiki filter could probably also do so but you're then getting a lot of filters all trying to work at once. I'd rather it just did one and let you specify which it was. Shaun aegis design - http://www.aegisdesign.co.uk |