Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Entire forum
➜ Forum
➜ Test
➜ Testing templates
It is now over 60 days since the last post. This thread is closed.
Refresh page
Pages: 1
2
3
4 5
Posted by
| Twisol
USA (2,257 posts) Bio
|
Date
| Reply #45 on Fri 21 Aug 2009 05:07 AM (UTC) |
Message
| Ah yeah, good point. You're a better designer than I ;) |
'Soludra' on Achaea
Blog: http://jonathan.com/
GitHub: http://github.com/Twisol | Top |
|
Posted by
| WillFa
USA (525 posts) Bio
|
Date
| Reply #46 on Fri 21 Aug 2009 05:14 AM (UTC) |
Message
| I've just been working with stylesheets lately from trying to convert the help over to chm format... I'm not good, just newly experienced. ;) | Top |
|
Posted by
| Nick Gammon
Australia (23,120 posts) Bio
Forum Administrator |
Date
| Reply #47 on Fri 21 Aug 2009 05:41 AM (UTC) |
Message
|
Twisol said:
Scripting? I was thinking more like just a button that would open the same reply entry box, but with the selected post quoted already inside.
Hmmm - yes you are right that is possible. Handling the forum codes is a bit fiddly. You have the problem of nested forum tags if you aren't careful.
Anyway, I am experimenting a bit to see if a workable version can be done. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Nick Gammon
Australia (23,120 posts) Bio
Forum Administrator |
Date
| Reply #48 on Fri 21 Aug 2009 06:48 AM (UTC) |
Message
|
Twisol said:
Adding a 'Quote' button on each post would also be nice; I frequently find myself wanting to quote someone, but having to go back and copy it manually.
OK - I think I got the quote button working. It was quite fiddly, I didn't want to keep all the forum tags in the quoted message, for one thing that looked messy, and for another you had the problem with nested tags.
So, a quoted message basically has the forum tags stripped from it - it may not work perfectly, if you find something obviously wrong I'll try to correct it. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Nick Gammon
Australia (23,120 posts) Bio
Forum Administrator |
Date
| Reply #49 on Fri 21 Aug 2009 06:59 AM (UTC) |
Message
| |
Posted by
| Nick Gammon
Australia (23,120 posts) Bio
Forum Administrator |
Date
| Reply #50 on Fri 21 Aug 2009 07:00 AM (UTC) |
Message
| Quoting the above message:
Nick Gammon said:
Testing:
bold
italic
underline
*ordered list item 1
*ordered list item 2
*unordered list item 1
*unordered list item 2
(quote)
a quoted item
------
some code
------
monospaced stuff
horizontal rule:
-----
escaped brackets: [ ] \
(bug)
(codetag)
(copying)
(faq)
(faq=11)
(function=AddTrigger)
(pasting)
(post=9687)
(quote=Nick Gammon)
(regexp)
(saveplugin=ConsiderMobs)
(scripting)
(search)
(search=stat roller)
(smaugfuss)
(starting)
(version)
(what)
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| WillFa
USA (525 posts) Bio
|
Date
| Reply #51 on Fri 21 Aug 2009 07:00 AM (UTC) Amended on Fri 21 Aug 2009 07:01 AM (UTC) by WillFa
|
Message
|
Nick Gammon said:
(quote=Twisol)
Adding a 'Quote' button on each post would also be nice; I frequently find myself wanting to quote someone, but having to go back and copy it manually.
OK - I think I got the quote button working. It was quite fiddly, I didn't want to keep all the forum tags in the quoted message, for one thing that looked messy, and for another you had the problem with nested tags.
So, a quoted message basically has the forum tags stripped from it - it may not work perfectly, if you find something obviously wrong I'll try to correct it.
[quote=E.A.Poe]
(quote=TheRaven)
Nevermore.
But how will we quote code? :)
I broke it! :) | Top |
|
Posted by
| Twisol
USA (2,257 posts) Bio
|
Date
| Reply #52 on Fri 21 Aug 2009 07:11 AM (UTC) Amended on Fri 21 Aug 2009 07:13 AM (UTC) by Twisol
|
Message
| Maybe the forum software can process [code] and [quote] expansions before it converts to (plain tags)? |
'Soludra' on Achaea
Blog: http://jonathan.com/
GitHub: http://github.com/Twisol | Top |
|
Posted by
| Nick Gammon
Australia (23,120 posts) Bio
Forum Administrator |
Date
| Reply #53 on Fri 21 Aug 2009 07:14 AM (UTC) |
Message
| I remember now why it is hard to get quotes (or anything) going as a nested thing, using regular expressions. Basically regexp matches can be greedy or non-greedy, but neither one matches correctly on a message with both nested and non-nested quotes in it.
[quote=Nick] aaa [quote=Willfa] bbb [/quote] [/quote] [quote=Twisol] ccc [/quote]
greedy: ^-------------------------------------------------------------------------^
nongreedy: ^-----------------------------------^
correct: ^--------------------------------------------^
The greedy one goes too far, and the non-greedy one doesn't handle the nesting.
Now you could recursively descend into it (and then you have the problems of handling badly-formed messages) but this is something that has to happen on every post, on every page. (There are up to 15 posts a page).
I was worried about the overhead of doing that all the time.
The current system just blindly replaces form codes with html, eg. [b] becomes <b>.
Twisol said:
One of many solutions I can think of is counting the number of start tags versus end tags
Counting won't detect this:
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Nick Gammon
Australia (23,120 posts) Bio
Forum Administrator |
Date
| Reply #54 on Fri 21 Aug 2009 07:16 AM (UTC) |
Message
|
WillFa said:
But how will we quote code? :)
..... must ..... not ..... quote ..... code ...... |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| WillFa
USA (525 posts) Bio
|
Date
| Reply #55 on Fri 21 Aug 2009 07:18 AM (UTC) Amended on Fri 21 Aug 2009 07:19 AM (UTC) by WillFa
|
Message
|
WillFa said:
Balanced tags are easy in LPEG! Quick, Nick, rewrite the forum software in Lua!
;)
;)
What a can of worms we've opened... | Top |
|
Posted by
| Nick Gammon
Australia (23,120 posts) Bio
Forum Administrator |
Date
| Reply #56 on Fri 21 Aug 2009 07:19 AM (UTC) |
Message
|
Nick said:
<aliases>
<alias
match="target *"
enabled="y"
variable="target"
send_to="9"
sequence="100"
>
<send>%1</send>
</alias>
</aliases>
There! I quoted code. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Nick Gammon
Australia (23,120 posts) Bio
Forum Administrator |
Date
| Reply #57 on Fri 21 Aug 2009 07:20 AM (UTC) |
Message
| Er, maybe not. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Nick Gammon
Australia (23,120 posts) Bio
Forum Administrator |
Date
| Reply #58 on Fri 21 Aug 2009 07:24 AM (UTC) |
Message
| Ah, why did it do that? I didn't give it permission to render the page that way.
A <code> tag must have an implied end of paragraph. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| WillFa
USA (525 posts) Bio
|
Date
| Reply #59 on Fri 21 Aug 2009 07:37 AM (UTC) |
Message
| Yup, a code tag is a new block element.
You could make .code a css class that has white-space: pre; and font-family: monospace; then change the php so it doesn't write <pre><code> tags, but a <div class="code"> tag...
A div will not nest inside of a <P> tag, so it will behave like the rest of the forum even when not nested.
| Top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
213,403 views.
This is page 4, subject is 5 pages long:
1
2
3
4 5
It is now over 60 days since the last post. This thread is closed.
Refresh page
top