Search the Community
Showing results for tags 'ampersand'.
-
I had originally posted this in the barcode section. Hello, I'm having an issue dealing with a QR Code where there are ampersands in the destination URL. I'll paste the code I have below but please note that the first part of the URL will be changed here due to security. That isn't the area I'm having trouble with however, the problem is with the last section that reads ("&DMC-DIRECTMAIL&mid=H3W&version=A") QR Code Rule: var dataforbarcode = ("http://order.com/H3W/Main-A.asp?No=" + encodeURIComponent (Left(Field("CODE"), 8) + ("&DMC-DIRECTMAIL&mid=H3W&version=A"))); var dmbarcodeobj = new QRBarcode; dmbarcodeobj.encodingmode = (Left(Field("CODE"), 8)); dmbarcodeobj.pointSize = 3.5; return dmbarcodeobj.Make(dataforbarcode); This code returns the correct page without the customer information. I need to get the customer information to show. Thank you
-
I'm working on a Table that works great except data that has the ampersand (&) returns unexpected results. Example B&A Scholarship Fund returns B Scholarship Fund The "&" is getting stripped including anything until the next word. I know I have to use the NormalizeEntities function but in this particular case don't know where or how to write the syntax. Here's the table: new FPTable; var table = new FPTable; table.AddColumns(13500,1800,5400); for (i=1;i<=12;i++) {//Loop through fields if (Field("Amount_"+i)!="") {//add a row if the Amount field is not empty var tableRow = table.AddRow(); tableRow.Cells[0].HAlign = "Left"; tableRow.Cells[1].HAlign = "Center"; tableRow.SetContents(Field("Designation_"+i),Field("GC"+i),Field("Amount_"+i)); //Add content to the columns for (c=0;c<=2;c++) {//loop through cells to apply margins & font tableRow.Cells[c].Margins = { Top:0, Bottom:68, Left:0, Right:0 }; tableRow.Cells[c].Font = "Crimson Roman"; } } } var totalRow = table.AddRow(); //Add total row totalRow.Cells[0].HAlign = "Left"; totalRow.Cells[2].HAlign = "Center"; totalRow.SetContents("TOTAL 2018 TAX-DEDUCTIBLE GIVING:","",Field("CAL18_TTL")+"*"); //Set total row content for (c=0;c<=2;c++) {//loop through cells to apply margins & font totalRow.Cells[c].Margins = { Top:0, Bottom:68, Left:0, Right:0 }; totalRow.Cells[c].Font = "Brandon Grotesque Bold"; } return table.MakeTags(); Any help would be greatly appreciated!
- 1 reply
-
- ampersand
- normalizeentities
-
(and 1 more)
Tagged with:
-
Customers are using our new business card template (uploaded and configured on WebCRD) and in one of the fields (title), many of them are adding and ampersand '&' but it changes to "amp;" instead of just "&". I've read some threads about some scripts that people have been using, but this is just an open form field for us. I've also turned off the check box limiting FusionPro to MacRoman characters, but that didn't help either. Anyone else run into this before?
-
Hi, I have a problem with a piece of code on a business card in DSF/FP9.3. We need to keep a string on one line without wrapping and use the function below. Works fine unless there is a "&" in the input field. "Me And You" works fine but "Me & You" composes to "Me & You" Anyone know how to overcome? function NoBreak(s) { return NormalizeEntities(s).replace(/ /g, " "); } return NoBreak(Field("title"));