CVSTrac Legacy Code

Check-in [10e5c9bba7]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:(#787) append/add remarks should be hidden for users without ticket write permissions
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:10e5c9bba794193c8e67dde4ffac2231fbe64374
User & Date: cpb 2009-03-02 00:07:41
Context
2009-03-06
03:06
(#177) makes HTML entities _work_ in wiki markup and (maybe) other places

In order to allow it to work in both normal web browsing and the encoding needed for RSS (where we _need_ to encode even entities), I modified htmlize (%h) to take an "allow entities" flag, and added a new %R formatting option which disables this flag. %R is used by the RSS formatter to do the final content generation. This means anywhere wiki content is allowed someone can write é and, apparently, it works.

Keep in mind that I don't normally use anything except ASCII in my day-to-day environment, so someone who cares about this stuff should maybe test it out a bit more than myself. check-in: 14e235cdd5 user: cpb tags: trunk

2009-03-02
00:07
(#787) append/add remarks should be hidden for users without ticket write permissions check-in: 10e5c9bba7 user: cpb tags: trunk
2009-02-25
02:04
(#786) ensure local attachments links from the {quote:{image:}} tags aren't broken in the RSS feed. This requires adding an appropriate page id to the formatting calls. check-in: 4149691655 user: cpb tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to ticket.c.

781
782
783
784
785
786
787

788
789
790
791
792
793
794
795
796
797
798

799
800
801
802
803
804
805
806
807
808
809
810
811
    "SELECT tn,title FROM ticket WHERE derivedfrom=%d", tn);
  common_header("Ticket #%d", tn);
  @ <h2>Ticket #%d(tn): %h(az[11])</h2>
  @ <blockquote>
  output_formatted(az[12], zPage);
  @ </blockquote>
  @

  @ <table align="right" style="margin: 0 10px;" cellpadding=2 border=0>
  @ <tr><td bgcolor="%h(BORDER1)" class="border1">
  @ <table width="100%%" border=0 cellpadding=4 cellspacing=0>
  @ <tr bgcolor="%h(BG1)" class="bkgnd1">
  @ <td valign="top" align="left">
  if( az[13][0]==0 ){
    @ [<a href="tktappend?tn=%h(zTn)">Add remarks</a>]
  } else {
    @ [<a href="tktappend?tn=%h(zTn)">Append remarks</a>]
  }
  @ </td></tr></table></td></tr></table>

  @ <h3>Remarks:</h3>
  @ <blockquote>
  output_formatted(az[13], zPage);
  @ </blockquote>

  if( az[13][0]!=0 ){
    @ <table align="right" style="margin: 0 10px;" cellpadding=2 border=0>
    @ <tr><td bgcolor="%h(BORDER1)" class="border1">
    @ <table width="100%%" border=0 cellpadding=4 cellspacing=0>
    @ <tr bgcolor="%h(BG1)" class="bkgnd1">
    @ <td valign="top" align="left">
    @ [<a href="tktappend?tn=%h(zTn)">Append remarks</a>]
    @ </td></tr></table></td></tr></table>







>
|
|
|
|
|
|
|
|
|
|
|
>





|







781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
    "SELECT tn,title FROM ticket WHERE derivedfrom=%d", tn);
  common_header("Ticket #%d", tn);
  @ <h2>Ticket #%d(tn): %h(az[11])</h2>
  @ <blockquote>
  output_formatted(az[12], zPage);
  @ </blockquote>
  @
  if( g.okWrite ){
    @ <table align="right" style="margin: 0 10px;" cellpadding=2 border=0>
    @ <tr><td bgcolor="%h(BORDER1)" class="border1">
    @ <table width="100%%" border=0 cellpadding=4 cellspacing=0>
    @ <tr bgcolor="%h(BG1)" class="bkgnd1">
    @ <td valign="top" align="left">
    if( az[13][0]==0 ){
      @ [<a href="tktappend?tn=%h(zTn)">Add remarks</a>]
    } else {
      @ [<a href="tktappend?tn=%h(zTn)">Append remarks</a>]
    }
    @ </td></tr></table></td></tr></table>
  }
  @ <h3>Remarks:</h3>
  @ <blockquote>
  output_formatted(az[13], zPage);
  @ </blockquote>

  if( g.okWrite && (az[13][0]!=0) ){
    @ <table align="right" style="margin: 0 10px;" cellpadding=2 border=0>
    @ <tr><td bgcolor="%h(BORDER1)" class="border1">
    @ <table width="100%%" border=0 cellpadding=4 cellspacing=0>
    @ <tr bgcolor="%h(BG1)" class="bkgnd1">
    @ <td valign="top" align="left">
    @ [<a href="tktappend?tn=%h(zTn)">Append remarks</a>]
    @ </td></tr></table></td></tr></table>