Question
This is bizarre.
I use a lot of INCLUDEs by pattern, e.g.
%INCLUDE{"TOPIC" pattern="^.*<\!-- BEGIN_INCLUDE -->(.*?)<\!-- END_INCLUDE -->.*"}%
Today, I hit one that isn't working. The INCLUDE looks good (see above). The pattern wrapper looks good in Raw View.
<!-- BEGIN_INCLUDE -->
* ops-announce is our primary *outbound* announcement list, used for communication *to* our supported clients
...
<!-- END_INCLUDE -->
But here's what a View Source shows in the Browser
<!-- <span class="twikiNewLink">BEGIN_INCLUDE<a title="Create this topic"
href="/edit/MyWeb/BEGIN_INCLUDE?topicparent=MyWeb.EmailManagement" rel="nofollow"><sup>?</sup></a></span> -->
<p /> <ul>
<li> ops-announce is our primary <strong>outbound</strong> announcement list,
used for communication <strong>to</strong> our supported clients.
...
<!-- <span class="twikiNewLink">END_INCLUDE<a title="Create this topic" h
ref="/edit/MyWeb/END_INCLUDE?topicparent=MyWeb.EmailManagement" rel="nofollow"><sup>?</sup></a></span> -->
TWiki seems to have decided that my HTML comment should be a link to create a new page.
Other topics render as comments (as expected) in the HTML source.
The mind boggless. Sign me perplexed.
Environment
--
VickiBrown - 14 Jul 2007
Answer
If you answer a question - or have a question you asked answered by someone - please remember to edit the page and set the status to answered. The status is in a drop-down list below the edit box.
Not sure about the actual problem, but the work-around, and probably better way, is to use STARTINCLUDE/STOPINCLUDE, or perhaps STARTSECTION/ENDSECTION. See
TWikiVariables.
--
JustinLove - 19 Jul 2007
I would argue the word choice "better" :-)
STARTINCLUDE/STOPINCLUDE only allow one inclusion from a given file; that's a non-starter.
STARTSECTION/ENDSECTION are a good suggestion; however, these didn't yet exist in our installation of TWiki when we started using the pattern= workaround.
Nevertheless, TWIki really shouldn't be converting the contents of HTML comments into anything.
Bug 4391 filed.
--
VickiBrown - 19 Jul 2007
Tracked by a bug item, so closing.
--
CrawfordCurrie - 01 Sep 2007