Opened 8 years ago

Closed 6 years ago

Last modified 5 years ago

#9666 closed (fixed)

ssi tag don't works with context variables

Reported by: Andrews Medina Owned by: Eric Holscher
Component: Template system Version: master
Severity: Keywords: tag, ssi, template
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: yes Patch needs improvement: no
Easy pickings: UI/UX:

Description

if I want use this:

{% ssi url %}


and url to be a context variable, this don't works. The tag {% ssi %} works only with strings.

Attachments (5)

patche.txt (527 bytes) - added by Andrews Medina 8 years ago.
ssi-variable.diff (1.2 KB) - added by Ulrich Petri 8 years ago.
fixed ssi variable resolving
9666-with-tests.2.diff (5.3 KB) - added by Eric Holscher 8 years ago.
'"' +This makes me cry a little inside + '"'
9666-with-tests.diff (5.6 KB) - added by Eric Holscher 8 years ago.
Actually attach template this time.
future_ssi-1.diff (4.2 KB) - added by Sean Brant 6 years ago.
future ssi tag replacement

Download all attachments as: .zip

Change History (16)

Changed 8 years ago by Andrews Medina

Attachment: patche.txt added

comment:1 Changed 8 years ago by Andrews Medina

Version: 1.0SVN

comment:2 Changed 8 years ago by Jacob

milestone: 1.1
Triage Stage: UnreviewedAccepted

comment:3 Changed 8 years ago by Ulrich Petri

The above patch has a bug if the ssi tag is used with a variable inside a loop.
Since the variable is only "resolved" once subsequent .render() calls (to the same node) always return the result of the first invocation.

I'll attach a fixed patch.

Changed 8 years ago by Ulrich Petri

Attachment: ssi-variable.diff added

fixed ssi variable resolving

comment:4 Changed 8 years ago by mcroydon

Needs tests: set

comment:5 Changed 8 years ago by Eric Holscher

Owner: changed from nobody to Eric Holscher
Status: newassigned

Note that currently I don't see any tests associated with ssi. I'll work on this later, if nobody else wants to.

Changed 8 years ago by Eric Holscher

Attachment: 9666-with-tests.2.diff added

'"' +This makes me cry a little inside + '"'

Changed 8 years ago by Eric Holscher

Attachment: 9666-with-tests.diff added

Actually attach template this time.

comment:6 Changed 8 years ago by Russell Keith-Magee

milestone: 1.1

This borders on being a feature; deferring from v1.1

comment:7 Changed 6 years ago by Eric Holscher

milestone: 1.3

Changed 6 years ago by Sean Brant

Attachment: future_ssi-1.diff added

future ssi tag replacement

comment:8 Changed 6 years ago by Sean Brant

#14389 is trying to introduce a from future concept for the url tag fixes. My latest patch does the same thing for the ssi tag. See #14389 for more details.

comment:9 Changed 6 years ago by Russell Keith-Magee

The RC1 patch on #14389 includes a fix for this ticket.

comment:10 Changed 6 years ago by Russell Keith-Magee

Resolution: fixed
Status: assignedclosed

(In [14643]) Fixed #14389, #9666 -- Started the migration path to make the first argument to url and ssi template tags syntactically consistent with other tags. Thanks to Sean Brant for the draft patch.

comment:11 Changed 5 years ago by Jacob

milestone: 1.3

Milestone 1.3 deleted

Note: See TracTickets for help on using tickets.
Back to Top