Pagelet Wizard custom transformations can use special tags documented here to insert images, message catalog entries, or to format numbers and dates. This is great when trying to format currencies or ensure multilingual compliance. The problem with "Post-Transformation Processing," as it is called in PeopleBooks, is that it requires the transformation results to be valid XML. Question: How do you get Pagelet Wizard to generate valid XML when the Xalan processor used by PeopleTools sees HTML tags and automatically generates HTML? Answer: use the <xsl:output> XSL tag. Here is a sample template that produces valid XML:
<?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="2.0" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns="http://www.w3.org/1999/xhtml" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" exclude-result-prefixes="xhtml xsl"> <xsl:output method="xml" version="1.0" encoding="UTF-8" doctype-public="-//W3C//DTD XHTML 1.1//EN" doctype-system="http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" indent="yes" /> <xsl:template match="/"> <!-- your XSL goes here --> </xsl:template> <!-- identity transform templates --> <xsl:template match="*"> <xsl:apply-templates/> </xsl:template> <!-- delete unmatched text --> <xsl:template match="@*|text()|comment()|processing-instruction()"> </xsl:template> </xsl:stylesheet>
Jim, does any PeopleTools release support HTML5? We are wanting to introduce drag and drop functionality into a calendar page to move work order links from one day to another.
If so, do you have any example of using this functionality in PeopleCode or jscript?
@JB, HTML 5 is more about the browser than the application. The real question is, "Does your organization's chosen browser support HTML 5?" IE 10, Firefox, and Chrome all support this type of thing. IE 8 doesn't. IE 9 supports some of it.
If your browser supports the new HTML 5 drag and drop, you can build a calendar that uses it.
I just had a general question about the Pagelet Wizard. What do you think are the possible risks when functional users (non-developers) create pagelets using the Pagelet Wizard? Is it really safe to give Pagelet Wizard access to functional users?
I know this is a very open ended question; just wanted to get your views.
Personally, I think Pagelet Wizard is one of the most powerful development tools in PeopleSoft. I also think that it is critical that key subject matter experts have access to create pagelets in Pagelet Wizard. As far as making it available to everyone? I'm not sure that is safe.
Thanks Jim. :) This really helps with the direction we want to take regarding this.
Not sure if this is the right place to ask - but is it possible to edit the html for form fields and labels in application designer? Thanks in advance.
Facing an issue BI Publisher report. Tried posting in Oracle forums with no luck.
I have an RTF template where i have three levels of grouping and i want to reset the page number based on the lower group i.e. inner group.
We can use @section only at the higher grouping level. How can we acheive this. Please let me know.
@Ravi, I have no experience with BI/XML Publisher.
I bought both of your books, and I must say they are well written and very information. Thanks for all you do for the community.
I had a question about post processing tags and how it is used. I am have a pagelet created in 9 languages but when I switch to each to a different language, I get still getting ENG and when I make the other language default, (i.e. ESP) I now get esp for all the other language including Eng. How would I be able to use the template you provided? Could you provide a simple sample of how it would work with a phase like (Welcome - Welcome Friend) to Spanish (Bienvenido - Bienvenido Amigo)?
@David, thank you, I am glad you enjoyed the books. Credit for the "well written" part goes to my wife who worked very hard editing these books.
For the languages issue, is this in reference to the PSMSGTEXT custom tag?
Thanks so much for your response, Jim. Your wife sure did a great job with the edits. Regarding your question, yes I am referring to the PSMSGTEXT custom tag and how this is used. I created a CSS/HTML pagelet in 8 languages using the pagelet wizard but I cannot get the languages to load based on the language. I reached out to Oracle support and they said they no longer support language transalations for multi language pagelets (Doc ID 1394973.1). Any guidance as to how I can accomplish the pagelet change per language selection will be greatly appreciated.
@David, it is true that Pagelet Wizard's HTML editor no longer supports languages, but message catalog always has, and I would suspect always will (that is the point of the message catalog). I will forward this to development because I believe this is a misunderstanding.
@David, I just chatted with development. In your MyOracle support case, have the rep contact me through e-mail. The rep will be able to find my address. I will connect him/her with the appropriate development staff to resolve this.
Jim, Thanks for your prompt response. I reached out to the Oracle Support analysis already to reach out to you as requested. I assumed you confirmed what was told to me, which we have found quite strange that Oracle would do that. In the meantime, is there another approach you could recommend to resolve this issue?
@David, I confirmed exactly the opposite, that PSMSGTEXT should work.
I have a question regarding PS Query pagelets created using Pagelet Wizard. Is there a way to always have this pagelet reload/refresh, without using a Custom XSLT? Is there any content reference attribute that can be used?
I am asking this because we have a similar pagelet that sometimes reloads and sometimes doesn't and we are not able to correctly identify in what case it does and doesn't.
@Tom, good question. By reload, do you mean on a time interval or are you just trying to keep it from caching between homepage visits? I assume you already looked at the CREF attributes of the pagelet that behaves according to your requirements?
Thanks a lot for the response.
It is the second one - dont want it to cache between homepage visits.
I am trying to find some place for pagelet attributes and I came across this (http://docs.oracle.com/cd/E38689_01/pt853pbr0/eng/pt/tprt/task_UsingAttributestoEnhancePagelets-717aa0.html) but it didnt help.
I went down the path of trying to using jquery to switch load the correct language section within my HTML, rather than using the XSL transform method with the custom meta tags which just does not seem to work for me.
My issue now is that when I select a language from my language selection pagelet, my custom HTML pagelet loads/switches to the right language but then the Portal Homepage reloads/refreshes and I the default ENG language displays again. Do you know how I can prevent this pagelet from reloading/refreshing? I tried the PSCACHECONTROL attribute already but that did not work.
@David, no, I don't have any recommendations in that regard. After using the pagelet, %Language should have the correct language. If it doesn't, then I would file a bug for this as well.
I also tried the attribute PORTAL_NOBROWSERCACHE (value = Y) but no luck. Any other tricks you might know? :)
@Tom, the easiest one to administer is in Pagelet Wizard step 6. There are other CREF attributes. You might be able to find them by querying PSPRSMATTRVAL
I am pretty new to pagelet wizard, however I have been really digging in lately and I have created a couple of query based pagelets and added the documented tags to format the currency. What I have done is used the pagelet wizard configuration to create my hyperlinks and then pressed the customized link and modified the xlst to insert my custom tags. My question is, Is this post intended for writing the entire xlst from scratch or is there a way to perform a second xlst to deliver the custom tags to the xml for post processing?
@Kevin, this post is for starting from "scratch." If you customize a delivered XSL, just make sure it has the xsl:output tag. That is really all I'm highlighting here.
I was working on a Blog post on using the Pagelet Wizard for Related Content, I know it is not traditional use for Pagelet Wizard, but I wanted to to utilize the way it can take query output and format it into HTML. Take a look at my posting and let me know what you think.
@Kevin, Nice! I was thinking about the same thing, but in a different context. I wanted to pass query parameters in the pagelet wizard URL.
Using Related Content and jQuery lightbox to turn any PeopleSoft Transaction into a Dashboard.
@Kevin, Something went wrong with your link. Here is a new one Using Related Content and jQuery lightbox to turn any PeopleSoft Transaction into a Dashboard.. I think you should give a presentation on creating Pagelet Wizard Data Types and Display Formats. You can use your two blog posts as examples.
Any thoughts on why two pages would act differently?
@JCook, since PeopleSoft does not use jQuery, I assume your organization added the tags, etc to load jQuery and plugins. What method are you using to load jQuery and plugins? Are they loaded on homepages through Pagelets? Are you injecting them through createElement? Did you add them to the header? The way you add jQuery and plugins to a page determines how they are loaded. If you use pagelets, then jQuery loads according to the pagelet load order and then the plugin load order. Even though you may be using script tags, Pagelets are loaded asynchronously after the the homepage loads, so there is no guarantee that the scripts will load synchronously using the standard script tag behavior.
Thanks for your Quick response. I am loading the jQuery library on MYRECORD.MYHTMLAREA.RowInit
Listed below is sample code:
©url = GenerateScriptContentURL(%Portal, %Node, Record.WEBLIB_MYJSL, Field.ISCRIPT1, "FieldFormula", "IScript_JqCopyJs");
MYRECORD.MYHTMLAREA.Value = GetHTMLText(HTML.MYJS_LIB, &url, ©url);
Hello Jim, how can I add the custom tags
in the pagelet wizard? is there a way to do that?
@Alvin, yes. The way you do it is to clone the Custom Display Format and/or the XSL Transformer. You will see that the PeopleCode for one or the other has hard coded the strings that it will replace. Or instead of cloning, you may be able to subclass it. Then you register your app class in the pagelet wizard metadata. Look through PeopleTools > Portal > Pagelet Wizard > Display Formats and Transform Types for examples.
Thanks for confirming on using PSMSGTEXT for message catalog in pagelet. It helped resolve language issue. The key was Thanks so much !!
Jim, I was wondering if you have come across a way to add the full query rowcount to the pagelet display perhaps using the customize features in Pagelet Wizard. I am displaying a query using table format and it displays 10 results by default. I like that the user can click "full query results" to open the query but I'd like to give the user an indication of the full number of records that require cleanup without the user having to click anything. A display either above the top 10 or below that says: "Total number of records: 45" or something like that. If you have any advice, I would love to hear it.
@Rajani, I do not have a simple solution for that. If I were to create a Pagelet that displayed a subset of results and a row count, I would use an IScript rather than Pagelet Wizard. Then I could check the row count myself and render in the proper location. If the results must come from a query rather than an SQL definition, then you could use the Query API to execute the query through PeopleCode.
Post a Comment