Closed Bug 769503 Opened 12 years ago Closed 12 years ago

Kuma: KumaScript - Do what we need to get the autoPreviousNext template working

Categories

(developer.mozilla.org Graveyard :: Wiki pages, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: sheppy, Unassigned)

References

Details

This template:

https://developer-new.mozilla.org/en-US/docs/Template:autoPreviousNext

Is trying to do stuff we don't have support for. It's used in a lot of places, such as:

https://developer-new.mozilla.org/en-US/docs/JavaScript/Guide/Values,_Variables,_and_Literals

Although we would survive if this were broken at launch it would not be good, since it would make some of our most popular content (like our JS docs) not as easy to read through.
This might be partly blocked by bug 765642, in that there's not an easy way to fetch web content and parse XML at the moment.

There might be a workaround though
Depends on: 765642
The autoPreviousNext template should be working now:

https://developer-new.mozilla.org/en-US/docs/JavaScript/Guide/About

I got the template in working shape on a test page. Then, I stepped through the JS guide, and had to make this change to most pages:

https://developer.mozilla.org/Project:en/Introduction_to_KumaScript#Unconverted_inline_script_blocks

I'm not sure if any other series of pages uses autoPreviousNext, but they may need that inline script fix as well.
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
(In reply to Les Orchard [:lorchard] from comment #2)
> The autoPreviousNext template should be working now

If anyone ever asks if you're a god, you don't have to lie to say "yes." Nicely done!
I've fought against this template a bit yesterday.
It's interesting to see how it was fixed.
Well, the biggest hurdles I think were that these things didn't exist until I was done:

* Template:Dekiscript:String - string.serialize, string.deserialize
* Template:Dekiscript:Wiki - wiki.getPage

Had to fill those in the dekiscript modules before tweaking autoPreviousNext to work, but hopefully the wiki.getPage implementation shows some more detail on how to make HTTP requests out from kumascript. It's not friendly to do yet, but I'm hoping to wrap it in friendly module methods
Version: Kuma → unspecified
Component: Website → Landing pages
Product: developer.mozilla.org → developer.mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.