default userpic

IfCurrentPage tag - what is this?

Vote 0 Votes

What is this new ifCurrentPage tag ? There is nothing in the description of it and I have not seen any examples of usage. At first I thought it would allow me to load a specific widget for a specific page (by page name) but I ended up with the widget on "all" pages. So I am guessing that is not what it's for...So what uses can a person use this tag for?

Reported on Movable Type 4.2

7 Replies

| Add a Reply
  • Can you post an example of how you are using it.

  • IfCurrentPage is for use within PagerBlock, which deals with the new dynamic pagination function. Which is to say it has nothing at all to do with what you're trying (Sorry.)
    (Though, the description for this tag isn't blank, as you seem to imply, and specifically says it has to be used within PagerBlock. What are you looking at?)

    For what you described, you probably want to do something like:

    <mt:If tag="PageID" eg="##">
        [Include your widget here]
    </mt:If>
    

    ...replacing the hashes with the ID number of the page you're checking for. You can optionally use PageBasename, if you want. I'd avoid the page name(title?) as that's too easily editable, which would make your test silently fail. The ID will be stable, and while the basename can be edited, you're at least given a bit of a warning when you do it.

  • Well because this was a new tag for me as well for anyone else, I thought I would try it this way (which obviously worked but not for the individual page(s) and when saving it didn't give errors.

  • hmmm I see part of my message didn't show up .... ugh... the tag I used orginally was:

  • ok this is irritating.. my code and message shows as it should in Preview but as soon as I click submit, it disappears. So scratch this... the forum system here needs some work me thinks :)

  • 
    
    

    Side note for any coders who enhances the development of this forum system, it would be really nice to have the ability to edit a post once it was submitted - like all other forum scripts so a person doesn't have to post multiple corrections as separate new posts :)

  • Ok.. this time I used the markdown coding and still my "full" post" doesn't work. So we can forget about this topic then and close it, time to move on. Sorry for the continuous posts. Thanks anyway.

Add a Reply

Forum Groups

108 362

Last Topic: Sub-Blog by qubix on Nov 12, 2008

152 411

Last Topic: CGI in multiple blog, single installation by Chas Porter on Nov 13, 2008

37 147

Last Topic: registration email not showing up by eraserhead on Nov 12, 2008

34 93

Last Topic: Creating your own Plug-in by jondauz on Nov 5, 2008

10 33

Last Topic: new licensing confusion by Neil Epstein on Aug 14, 2008

10 40

Last Topic: dynamically load a different template set by Mixhael on Nov 12, 2008

code.sixapart.com

62 226

Last Topic: Callback after blog publishing. by Tomato Interactive on Oct 27, 2008

35 100

Last Topic: List entries current month by Tomato Interactive on Nov 11, 2008