User(s) browsing this thread: 1 Guest(s)
|
[MLMJ] XSL scripting question
|
|
04-10-2010, 02:35 AM
|
|||
|
|||
|
[MLMJ] XSL scripting question
I am playing with some skin changes for MLMJ. When trying to execute the scripts from MoC (via the Export to HTML menu item) my script generates the error message:
Invalid element name: " Not being a very experienced XSL or javascript developer I am having trouble trying to find this error in the code - and this error message is not overly descriptive :-) Can anyone give me some ideas on what might be creating this kind of error message? That might help me try to locate it. One thought that came to mind was this error message may occur when " are used within another set of " (e.g. - <xsl:if test="$Show103="true" and $enable103='true'">) My thinking is that the use of " around the first "true" might cause such an error message. Is this the case? Are there other error conditions that would cause such a message? Thanks for any help. |
|||
|
04-10-2010, 02:49 AM
|
|||
|
|||
|
RE: [MLMJ] XSL scripting question
Yes, "test this="true" " (ex) will not work, try using single quotes when double quote is already used.
--> 'test this="true" ' |
|||
|
04-11-2010, 02:15 AM
|
|||
|
|||
|
RE: [MLMJ] XSL scripting question
Thanks Garp. I am starting to make some headway (albeit slowly). My latest challenge is passing a parameter value through a couple of template calls. The situation is as follows:
- Template 1 is called from the main body of the code - Template 1 makes iterative calls to Template 2 - I want to call Template 1 (and hence Template 2) twice but have Template 2 behave differently depending why I am calling it - either to generate an array or to generate an index table of movie covers. My solution was to pass it a parameter (through Template 1) that would trigger different behaviour. See the example code below: Code: <<snip>>The parameter values seem to be getting passed to Template 1 Ok, but I cannot figure out how to pass the values through to Template 2. If I replace the line Code: <xsl:with-param name="passType" select="$listtype" />Code: <xsl:with-param name="passType">test</xsl:with-param>I've tried a bunch of different combinations of variables, etc. - but am not having any luck. Any help would be greatly appreciated. Thanks. |
|||
|
04-11-2010, 03:00 AM
|
|||
|
|||
|
RE: [MLMJ] XSL scripting question
It's really hard to diagnose/debug when looking at snippets of code in a small window.
I am willing to look over your skin and compile here myself to see where things go wrong and then I can help to figure things out with you. You can PM me your real email addr or PM me a link to download your skin (zipped). Otherwise, I did a search of the existing skins I have available (most of them) and was able to find some similar code in AEon skin's index.xsl and perhaps that can provide some clues... Code: <xsl:for-each select="library/movies/movie[position() mod $nbCols = 1]"> |
|||
|
04-11-2010, 05:33 PM
(This post was last modified: 04-11-2010 05:48 PM by gsbaker.)
|
|||
|
|||
RE: [MLMJ] XSL scripting question
(04-10-2010 02:35 AM)gsbaker Wrote: I am playing with some skin changes for MLMJ. When trying to execute the scripts from MoC (via the Export to HTML menu item) my script generates the error message: While the quotes inside of quotes also caused problems, through a long process of trial and error I found another culprit. Some of the javascript code I wanted the XSL parser to include in the html output include the "&" character which caused the parser to hiccup. I solved that problem by enclosing the javascript code in CDATA tags. Now on to my next problem :-) (04-11-2010 02:15 AM)gsbaker Wrote: Thanks Garp. I am starting to make some headway (albeit slowly). My latest challenge is passing a parameter value through a couple of template calls. The situation is as follows: While I have not "solved" this problem, I have found a work-around. Basically in Template 1 I test for the parameter value and created 2 branches depending on the value (since I am only concerned about 2 scenarios - parameter="data" and parameter="table"). By creating the two branches I could feed Template 2 with a hard coded value as in the code line above - with a different value from each branch. This solved another problem as well as I needed different behaviours in Template 1 depending on the value received (in one case I need the results embedded within html tr tags and in the other case not. |
|||
|
« Next Oldest | Next Newest »
|
| Possibly Related Threads... | |||||
| Thread: | Author | Replies: | Views: | Last Post | |
| MLMJ and Movie Collector 9 | johnfromen6 | 7 | 1,133 |
Yesterday 02:03 AM Last Post: gsbaker |
|
| [MLMJ] DVD Empire Script broken | gsbaker | 3 | 616 |
05-02-2013 12:28 AM Last Post: gsbaker |
|
| [MLMJ] Script to convert from MLMJ to YAMJ | Swannpin | 9 | 2,013 |
02-16-2012 04:51 PM Last Post: Swannpin |
|
| Question about music information in Music Jukebox 8 | Zolive | 3 | 1,935 |
11-29-2011 03:39 AM Last Post: wandidj |
|
| [MLMJ] - Upgrading to Movie Collector 8??? | gsbaker | 4 | 2,887 |
11-21-2011 11:35 AM Last Post: bigkid |
|
| MLMJ and genre filters in MoC | Penge58 | 1 | 1,477 |
08-28-2011 02:50 PM Last Post: gsbaker |
|
| MLMJ Irfanview not closing when done | Penge58 | 0 | 1,129 |
08-25-2011 10:44 AM Last Post: Penge58 |
|
| MLMJ - Stops at Initializing Variables | bigkid | 16 | 4,029 |
07-22-2011 03:45 AM Last Post: bigkid |
|
| [MLMJ] Is this project still active? | charlesc | 23 | 5,713 |
06-28-2011 11:39 PM Last Post: michael1t |
|
| MLMJ stuck with MoC version 7.1.6 | Penge58 | 5 | 1,970 |
06-23-2011 05:47 PM Last Post: gsbaker |
|

Twitter
Facebook
NMT Wiki
Search
Member List
Help
[19. June 2013] Soundcloud® available now




![[+]](images/collapse_collapsed.gif)