| Home | Tutorials | Forums | Articles | Blogs | Movies | Library | Employment | Press | Buy templates |
|
|||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
#1 |
|
Registered User
Join Date: Jul 2004
Posts: 31
|
Hello I have an XML file that is displayed in a browser..
I want to be able to format the text (change the font color and size) as well as change the background to a color or image. I have had some luck in the past linking the xml file to a CSS using the following code at the top of the XML file: ---------------------------------------------------------- <?xml-stylesheet type="text/css" href="cssforxmlfile.css"?> ---------------------------------------------------------- But for the XML file that I am working on I can't seem to get it to work (And I cant change the layout of the XML file). I want to be able to change the font type, size and color of all the text in " " that follows str= I have bolded the first few chunks of text that I want to be able to format. Does anyone know how I can do this?? ----------------------------------------------------------------- <?xml version="1.0" encoding="unicode" ?> <?xml-stylesheet type="text/css" href="estyleb.css"?> <TerminalParams> <Images> <ImageDetails id="1" filename="DresserWayne_EK3_Banner.gif" width="640" height="120"/> </Images> <BackgroundImages> <ImageInstance imageId="1" left="0" top="0"/> </BackgroundImages> <Prompts> <Prompt id="0" str="Please insert your membership card" left="0" top="180" width="640" height="72"/> <Prompt id="1" str="Would you like to pay with this card? Please press YES or NO" left="0" top="180" width="640" height="72"/> <Prompt id="2" str="Please insert your membership card, credit card, or shopping card" left="0" top="180" width="640" height="72"/> <Prompt id="3" str="Please Lift Nozzle"/> <Prompt id="4" str="Select grade"/> <Prompt id="5" str="Begin Fueling"/> <Prompt id="6" str="Please Replace Nozzle After Fueling"/> <Prompt id="7" str="Would you like a receipt? Please press YES or NO "/> <Prompt id="8" str="Your receipt is printing..."/> <Prompt id="9" str="Please take your receipt"/> <Prompt id="10" str="Sale Completed Thank You "/> <Prompt id="11" str="One Moment Please..."/> <Prompt id="12" str="Please remove your card"/> <Prompt id="13" str="Please re-insert your card "/> <Prompt id="14" str="Card Read Error Please try again"/> <Prompt id="15" str="Your membership has expired. Would you like to renew it for % ?"/> <Prompt id="16" str="Member Inactive Please Renew"/> <Prompt id="17" str="Card is invalid"/> <Prompt id="18" str="CANCELING... Please wait..."/> <Prompt id="19" str="Are you a member? Please press YES or NO "/> <Prompt id="20" str="Press Credit, Debit or Shopping Card"/> <Prompt id="21" str="Insert Credit Card"/> <Prompt id="22" str="Insert Debit Card"/> <Prompt id="23" str="Insert Shopping Card"/> <Prompt id="24" str="Membership card is not recognized"/> <Prompt id="25" str="Card is not acceptable"/> <Prompt id="26" str="%"/> <Prompt id="27" str="Card Balance $%"/> <Prompt id="28" str="Your discount is $% Shopping Card Balance is $%"/> <Prompt id="29" str="Would you like a car wash? Please press YES or NO "/> <Prompt id="30" str="Please select carwash"/> <Prompt id="31" str="We're Sorry, We Are Presently Closed OPEN: M-S 6am-9pm SUNDAY 9am-7pm"/> <Prompt id="32" str="Sorry, carwash not available"/> <Prompt id="33" str="Your discount is $%"/> <Prompt id="34" str="Card is expired TRANSACTION CANCELED"/> <Prompt id="35" str="Replace nozzle to complete sale"/> <Prompt id="36" str="Please replace nozzle"/> <Prompt id="37" str="Dispenser is Offline"/> <Prompt id="38" str="Pump authorization failed. Sale cancelled."/> <Prompt id="39" str="Is this a Debit card? Please press YES or NO"/> <Prompt id="40" str="Credit or Debit?"/> <Prompt id="41" str="Please insert your membership card" left="0" top="180" width="640" height="72"/> <Prompt id="42" str="Please insert your payment" left="0" top="180" width="640" height="72"/> <Prompt id="43" str="Receipt Printer is out of paper. Continue?"/> </Prompts> </TerminalParams> ----------------------------------------------------------------- Here is the code that I have in my CSS file: ------------------------- Prompts { color: #ff7f00; font-size: 12pt; } ------------------------- As you can see I have tried to change the font color and size of the text for "Prompts" but it doesn't seem to work. Have I done something wrong??? Or is there another way to format the text?? either with an external file or within the XML file? Thanks, Andrew |
|
|
|
|
|
#2 |
|
done
Join Date: Jun 2001
Location: portland, or
Posts: 8,048
|
if its for a browser, and not flash, look thru w3schools xsl tutorial. here is a part of it, that just deals with templates:
http://www.w3schools.com/xsl/xsl_apply_templates.asp read thru the whole think for more info.... its very good and informative.
__________________
tg --- what the hell was i thinking? |
|
|
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|