Jump to content

boen_robot

Members
  • Posts

    8,493
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by boen_robot

  1. Hve you tryed something more of the lines <xsl:apply-templates select="parameter[name='book name']/value"/> This should output the value of a parameter which has a name element inside which value is "book name". It should work, but if it doesn't, you could try something like <xsl:apply-templates select="parameter/value[string(../name)='book name']"/>
  2. You should ask your host if he has some "support for a server side scripting language". He has to know what you mean. Then tell your IT guy that language and ask him if he can do SSIs. If not, tell us what's that language and we'll tell you the code that you must replace the Iframes with.
  3. Offtopic://Is it really necessary that you use this "Comment on [username]:" template? I like it when templates are used for presentational purposes, but for a comment it's really useless.@reportingsjr I can't believe that's paint only. Not to mention that there isn't any way to proove it. Unlike 3D models for example, multimedia such as raster graphics, markup languages, etc. can't be prooven to be created with a certain editor. I can write my HTML pages in Dreamwaver. What's stopping me from telling you I've used Notepad, excluding my concience?Besides, the robe of the monk (or whatever this guy with grey robe is) is semi transparent and that transparency is "centralized". You can't achieve that in paint alone. At least, not with the ease of more specialized programs. Other effect used are also suspicios, but not as that one.
  4. Yes. The reason is exactly the iframes. If you just try to validate your index page you'll see the critical errors it has.Iframes are NOT the latest trend. They're the old trend. The "new" ones are AJAX includes and server side includes. Those methods have existed for long, but it wasn't before the deprecation of (i)frames before they became more and more popular.The reason for search engines' reaction is that they index both the pages inside the frame and the frame itself. However, they look only at the initial page of the frame and get the rest as separate pages. Because of that, when a user searches and finds such a lonely page, he leaves, because there's no navigation => it seems there is no site, but just a page, which may even seem as a "pfishing" one.Soooo.... a solution to your problem would be for you to get some server side scripting language (PHP, ASP(.NET), Cold Fusion, JSP, etc.) and use it's option for server side includes (SSI). This means that when anyone (including a search engine) asks for a page, that script would be executed and add the proper XHTML code inside the proper places. It reloads the whole page though, but I think that's better in comparrison to not being indexed, isn't it?
  5. boen_robot

    Centering

    "Dead" center? What's that suppose to mean? Screenshot?
  6. I don't think XSLT provides dynamical functions to check if a string matches the current date. I think there was some XPath 2.0 function that formats the date so you could then check it, but that's still not supported anywhere.I see that you're using some exslt.org extensions though, so I guess that's just another one you'll need.As for how to select the date without the hour, you could use the substring() function. It would requre a lot of substring() functions if you want to reformat the date though.
  7. Excuse my ignorance, but... who cares?! "position()>=2 and position()<=4" works, right?
  8. boen_robot

    CSS in XSL

    The only wrong thing I see is that the style is in the body. Have you tryed something like this: <xsl:template match="contact"><html><head><style type="text/css">p{font-weight: bold;font-style: italic}</style></head><body><p><xsl:value-of select="name" /><xsl:value-of select="address1" /><xsl:value-of select="address2" /><xsl:value-of select="address3" /><xsl:value-of select="town" /></p></body></html></xsl:template>
  9. I have IE7 and IE6 but I'm using another method. Perhaps it's the old one, cause it's making h#ll out of my browsing experience.The whole trick is... yeah, you've guessed it. Extract the exe file with WinRAR or something. The difference in my approach however is that to run IE7 I create an empty file in the folder it's all extracted called IEXPLORE.local. Then just run iexplore.exe and it's all done.Remember NOT to set IE7 as the default browser, even if IE6 was your default one. This would disable you to view pages in IE6 comletely.I have made posts here describing what difficulties this method has, but just the most important ones: You can't browse in both IE6 and IE7. One at a time. Otherwise, they'll both crash. Drop-down menus, opening links in new windows don't work in IE7. Opening configuration dialog for IE7 crashes it. Conditional comments for IE7 don't work. Instead, it threats itself as IE6. Any window you place in front of IE7's interface would result in a "copy" of it over IE7 interface, until another application is placed on that spot. When you type an adress in IE6 or click a link from the links toolbar, it opens about 3 new widnows before it opens the content or just crashes. The only way to see a page in IE6 is to open it from a "non-browser" source. Like a file or a link from an instant messanger (I'm using ICQ for that). That's infact the reason why you mustn't set IE7 as the default browser: if it is, links from IMs would open in it. IE6 must be the default browser if you want to use it. If you have genuine copies of Windows you could possibly unistall IE7 every time you want to see a page in IE6 though. I know it's uncomfortable, but it's still a possibility which won't cause all theese inconviniences. This old method is still good if all you need is to gaze at IE7s rendering engine.
  10. You mean that moderators can say ######, but not users?!?! That would be so unfair!
  11. I think we both know that they both just $uck .
  12. Wow. I'm most impressed. Especially by what you have with XSLT for only "a few days ago" already . Not to mention that starting 4 years ago would mean that you started at the age of... 13? Where the h#ll have I been that time.
  13. Nah, you're not. If memory serves, I once saw an 11 one posting. Regular posters under 14 are a rare view though.[edit] Not exactly. I said UNDER 14. 14 and older are a more often readers/posters.[/edit]
  14. It almost works for me. The links are generated fine and the content shows but for some reason the <ul> and/or <li>s are not created, thus leaving all the links "floating". Here's the new code after your suggested alterations: <?xml version="1.0" encoding="windows-1251"?><!-- DWXMLSource="navigation.xml" --><xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:variable name="Nav" select="'navigation.xml'"/><xsl:template name="navigation"> <xsl:for-each select="document($Nav)/menu"> <xsl:call-template name="menu" /> </xsl:for-each></xsl:template><xsl:template name="menu" match="menu"> <ul> <xsl:for-each select="item"> <li> <a href="{link}"> <xsl:value-of select="title"/> </a> <xsl:if test="menu"> <xsl:apply-templates select="menu"/> </xsl:if> </li> </xsl:for-each> </ul></xsl:template></xsl:stylesheet> And my main XSLT's source could be seen here.This odd behaviour starts when call-template is first used. Manually creating links in lists gives proper results when inserted after <xsl:call-template name="navigation"/> but when inserted in the templates navigation or menu, it gives the same odd results. Cold Fusion's parser gives errors. Any clue on what I might have done wrong?
  15. The <style> element is meant for per-page data, the same way you're allowed to have JS in the head and/or body even. Before such elements are gone, there is a need for a scriptless mechanism to allow different files to be loaded for sections and per-page data. I can do such thing by using XSLT and there are other ways with JS and and server side scriptings, but there's no possible way of doing this with pure XHTML.So sleep tight. The <style> attribute has a long way to live before it's deprecated.[edit] Actually, I'm a big fat liar. There's already a mechanism for that. You can call multiple links, each containing more and more specific things, as long as they are in order of specificness. For example: <link rel="stylesheet" type="text/css" href="site.css" /><link rel="stylesheet" type="text/css" href="section.css" /><link rel="stylesheet" type="text/css" href="subsection.css" />...<link rel="stylesheet" type="text/css" href="page.css" /> So the <style> element is really the next to go. It's only a matter of time until internet and browsers are fast enough for W3C to decide this.[/edit]
  16. I suggest the JavaScript way but in a conditional comment though. IE7 is going to have full :hover support, so isolating the JavaScript to start only for it is going to be crutual to performance on browsers that do have that support.
  17. Am... yes? I mean, separating content from presentation is their goal after all. XHTML to describe the structure and CSS for the variety of presentations.
  18. I think the html extention might be the way to go for now. That is true. IE doesn't support the application/xhtml+xml MIME type which as mentioned is applyed by default on every *.xhtml file. That is infact the reason why people still use the html extension. I am talking for the future anyway. If you want to see XHTML behaviour with *.xhtml files, you'll have to use FF or other browser that supports that MIME type.And scott100, yes. The reason for the style attribute's deprecation is exactly the existance of IDs.
  19. The reason browsers "support" it is that as far as I know, you're using the text/html MIME type, which allows for all XHTML transitional features, but uses HTML rules. True XHTML like behaviour can be achieved only through the *.xhtml extension and/or the application/xhtml+xml MIME type applyed to another extension.
  20. Really? !important changes priority? I thought it's only applyed when styles are turned off, so it could provide balance between author and user stylesheets. Only an !important rule in the user stylesheet can override an !important rule in the author stylesheet.
  21. There's this topic which has our names, ages, etc.As for when did we start. Well, I started the last summer.
  22. I haven't had so much laugh scince justsomeguy said "OK. Make haste."... ahahahaha :)I'm not sure I understand what you want exactly though and I don't indend on carrying and trying your code. If I have understood correctly, you want to fix IE6s buggy box model to follow the W3C box model, correct? Then I suggest to simply use the start hack:padding: 20px;; /* Value for all browsers */*padding: 21px; /* Value for IE6 and lower. It's equal to the padding + the border itself. */border: 1px solid #000000;
  23. You need to call the script two times in each of your main pages, remove the frame and call the actual homepage instead. The result is the same as if would have been if you were writing the code in the included files directly at that spot.
  24. Class names aren't allowed to have spaces, so because of that, when you have a space, it's treated as if you have two or more classes. Commas aren't allowed, or at least I don't think so. Multiple classes are not supported by older browsers OR have problems (for example, old IEs apply only the last class). But in general, it's supported, so there aren't that many problems with it.Oh, and yoshida, did you thought about AJAX Includes maybe?
  25. I think that by using this kind of predicate, you're actually pointing to the element book, which contains an element called 2, which would be impossible (as far as I know, element names can't begin with a number). Instead I think, you should check the position(), like this: /bookstore/book[position() = 2 to 4] I don't know if that would work either though. Just a though.
×
×
  • Create New...